The SelectBox in the form for adding document types to a content section did not show the name of the content type.

deploy_packages_to_gitea
Jens Pelzetter 2022-04-20 20:25:26 +02:00
parent a68d25ba61
commit 3683960f55
2 changed files with 4 additions and 6 deletions

View File

@ -180,7 +180,7 @@ public class ConfigurationDocumentTypesController {
.collect( .collect(
Collectors.toMap( Collectors.toMap(
model -> model.getContentItemClass(), model -> model.getContentItemClass(),
model -> model model -> model.getLabel()
) )
) )
); );

View File

@ -47,7 +47,7 @@ public class DocumentTypesModel {
/** /**
* The available types thare are not assigned to the content section. * The available types thare are not assigned to the content section.
*/ */
private Map<String, DocumentTypeInfoModel> availableTypes; private Map<String, String> availableTypes;
/** /**
* The available lifecycles definitions. * The available lifecycles definitions.
@ -69,13 +69,11 @@ public class DocumentTypesModel {
this.assignedTypes = new ArrayList<>(assignedTypes); this.assignedTypes = new ArrayList<>(assignedTypes);
} }
public Map<String, DocumentTypeInfoModel> getAvailableTypes() { public Map<String, String> getAvailableTypes() {
return Collections.unmodifiableMap(availableTypes); return Collections.unmodifiableMap(availableTypes);
} }
public void setAvailableTypes( public void setAvailableTypes(final Map<String, String> availableTypes) {
final Map<String, DocumentTypeInfoModel> availableTypes
) {
this.availableTypes = new HashMap<>(availableTypes); this.availableTypes = new HashMap<>(availableTypes);
} }