RED-8762: do not update addToDictionaryAction for dossier dictionaries when... #449

Merged
ali.oezyetimoglu1 merged 1 commits from RED-8762-bp2 into release/2.349.x 2024-04-15 12:01:01 +02:00

View File

@ -158,7 +158,22 @@ public class DictionaryService {
public void updateDossierType(String type, String dossierTemplateId, UpdateTypeValue typeValue, String dossierId) {
accessControlService.verifyUserIsDossierOwner(dossierId);
updateType(dossierTemplateId, toTypeId(type, dossierTemplateId, dossierId), typeValue);
// we do not set the flag addToDictionaryAction when updating the global type
dictionaryManagementService.updateTypeValue(toTypeId(type, dossierTemplateId, dossierId),
Type.builder()
.dossierTemplateId(dossierTemplateId)
.hexColor(typeValue.getHexColor())
.recommendationHexColor(typeValue.getRecommendationHexColor())
.skippedHexColor(typeValue.getSkippedHexColor())
.rank(typeValue.getRank())
.isHint(typeValue.isHint())
.isCaseInsensitive(typeValue.isCaseInsensitive())
.isRecommendation(typeValue.isRecommendation())
.description(typeValue.getDescription())
.label(typeValue.getLabel())
.hasDictionary(typeValue.isHasDictionary())
.autoHideSkipped(typeValue.isAutoHideSkipped())
.build());
}