Project

General

Profile

Actions

Defect #1449

closed

Form attribute is searched in all definition

Added by Ondřej Kopr over 5 years ago. Updated over 4 years ago.

Status:
Closed
Priority:
High
Assignee:
Peter Štrunc
Target version:
-
Start date:
01/15/2019
Due date:
% Done:

100%

Estimated time:
Affected versions:
Owner:

Description

This is probably big problem because method IdmFormAttributeDto getIdmFormAttributeDto(String code) search by code attribute but not by definition type. So if I have form attribute with code 'organization' for tree nodes is founded this attribute and in self registration is used for example default value from this wrong attribute.

private IdmFormAttributeDto getIdmFormAttributeDto(String code) {
    IdmFormAttributeFilter filter = new IdmFormAttributeFilter();
    filter.setCode(code);
    return formAttributeService.find(filter, null).getContent().stream()
        .findFirst().orElseThrow(() -> new ResultCodeException(RegResultCode.WRONG_CONFIGURATION_DATA,
            "No IdMFormAttribute found for code " + code + ". Please check your configuration."));
}

Affected version: 2.1.0


Files

missing.gif (1.28 MB) missing.gif Ondřej Kopr, 01/16/2019 01:29 PM
Actions

Also available in: Atom PDF