SEBSERV-449 fixed name query
This commit is contained in:
parent
2c7f4b8e09
commit
90d403c2b3
3 changed files with 6 additions and 4 deletions
|
@ -438,8 +438,10 @@ public class MoodlePluginCourseAccess extends AbstractCachedCourseAccess impleme
|
||||||
|
|
||||||
// TODO clarify with Amr and Luca if this is OK
|
// TODO clarify with Amr and Luca if this is OK
|
||||||
// and if it is possible to apply the nameCondition also the the course name (shortname)
|
// and if it is possible to apply the nameCondition also the the course name (shortname)
|
||||||
if (this.applyNameCriteria && StringUtils.isNotBlank(nameCondition)) {
|
if (StringUtils.isNotBlank(nameCondition)) {
|
||||||
sqlCondition = sqlCondition + " AND (m.name LIKE '" +
|
sqlCondition = sqlCondition + " AND (name LIKE '" +
|
||||||
|
Utils.toSQLWildcard(nameCondition) +
|
||||||
|
"' OR shortname LIKE '" +
|
||||||
Utils.toSQLWildcard(nameCondition) +
|
Utils.toSQLWildcard(nameCondition) +
|
||||||
"')";
|
"')";
|
||||||
}
|
}
|
||||||
|
|
|
@ -57,7 +57,7 @@ public class MooldePluginLmsAPITemplateFactory implements LmsAPITemplateFactory
|
||||||
final ExamConfigurationValueService examConfigurationValueService,
|
final ExamConfigurationValueService examConfigurationValueService,
|
||||||
final ClientHttpRequestFactoryService clientHttpRequestFactoryService,
|
final ClientHttpRequestFactoryService clientHttpRequestFactoryService,
|
||||||
@Value("${sebserver.webservice.lms.moodle.api.token.request.paths:}") final String alternativeTokenRequestPaths,
|
@Value("${sebserver.webservice.lms.moodle.api.token.request.paths:}") final String alternativeTokenRequestPaths,
|
||||||
@Value("${sebserver.webservice.lms.moodle.fetch.applyNameCriteria:false}") final boolean applyNameCriteria) {
|
@Value("${sebserver.webservice.lms.moodle.fetch.applyNameCriteria:true}") final boolean applyNameCriteria) {
|
||||||
|
|
||||||
this.jsonMapper = jsonMapper;
|
this.jsonMapper = jsonMapper;
|
||||||
this.cacheManager = cacheManager;
|
this.cacheManager = cacheManager;
|
||||||
|
|
|
@ -81,7 +81,7 @@ sebserver.webservice.lms.openedx.api.token.request.paths=/oauth2/access_token
|
||||||
sebserver.webservice.lms.moodle.api.token.request.paths=/login/token.php
|
sebserver.webservice.lms.moodle.api.token.request.paths=/login/token.php
|
||||||
sebserver.webservice.lms.moodle.prependShortCourseName=true
|
sebserver.webservice.lms.moodle.prependShortCourseName=true
|
||||||
sebserver.webservice.lms.moodle.fetch.cutoffdate.yearsBeforeNow=2
|
sebserver.webservice.lms.moodle.fetch.cutoffdate.yearsBeforeNow=2
|
||||||
sebserver.webservice.lms.moodle.fetch.applyNameCriteria=false
|
sebserver.webservice.lms.moodle.fetch.applyNameCriteria=true
|
||||||
sebserver.webservice.lms.olat.sendAdditionalAttributesWithRestriction=false
|
sebserver.webservice.lms.olat.sendAdditionalAttributesWithRestriction=false
|
||||||
sebserver.webservice.lms.address.alias=
|
sebserver.webservice.lms.address.alias=
|
||||||
sebserver.webservice.lms.datafetch.validity.seconds=600
|
sebserver.webservice.lms.datafetch.validity.seconds=600
|
||||||
|
|
Loading…
Reference in a new issue