[CST-3088] Replace use of AuthorityService with new VocabularyService

This commit is contained in:
Giuseppe Digilio
2020-06-25 15:21:44 +02:00
parent 3117916d5b
commit 63cca76b49
59 changed files with 740 additions and 706 deletions

View File

@@ -31,8 +31,8 @@ export class DropdownFieldParser extends FieldParser {
const dropdownModelConfig: DynamicScrollableDropdownModelConfig = this.initModel(null, label);
let layout: DynamicFormControlLayout;
if (isNotEmpty(this.configData.selectableMetadata[0].authority)) {
this.setAuthorityOptions(dropdownModelConfig, this.parserOptions.authorityUuid);
if (isNotEmpty(this.configData.selectableMetadata[0].controlledVocabulary)) {
this.setVocabularyOptions(dropdownModelConfig, this.parserOptions.collectionUUID);
if (isNotEmpty(fieldValue)) {
dropdownModelConfig.value = fieldValue;
}
@@ -47,7 +47,7 @@ export class DropdownFieldParser extends FieldParser {
const dropdownModel = new DynamicScrollableDropdownModel(dropdownModelConfig, layout);
return dropdownModel;
} else {
throw Error(`Authority name is not available. Please check the form configuration file.`);
throw Error(`Controlled Vocabulary name is not available. Please check the form configuration file.`);
}
}
}