Skip to content

Commit

Permalink
inducements fix
Browse files Browse the repository at this point in the history
  • Loading branch information
KaterynaHonchar committed Mar 6, 2018
1 parent ef2e87e commit ba76277
Showing 1 changed file with 3 additions and 5 deletions.
Expand Up @@ -47,7 +47,7 @@ public AbstractRoleAssignmentDetailsPanel(String id, Form<?> form, IModel<Contai
@Override
protected IModel<ContainerWrapper> getSpecificContainerModel() {
if (ConstructionType.COMPLEX_TYPE.equals(AssignmentsUtil.getTargetType(getModelObject().getContainerValue().getValue()))) {
ContainerWrapper<ConstructionType> constructionWrapper = getModelObject().findContainerWrapper(new ItemPath(getObjectContainerPath(), AssignmentType.F_CONSTRUCTION));
ContainerWrapper<ConstructionType> constructionWrapper = getModelObject().findContainerWrapper(new ItemPath(getModelObject().getPath(), AssignmentType.F_CONSTRUCTION));
constructionWrapper.setAddContainerButtonVisible(true);
constructionWrapper.setShowEmpty(true, false);
if (constructionWrapper != null && constructionWrapper.getValues() != null) {
Expand All @@ -61,7 +61,8 @@ protected IModel<ContainerWrapper> getSpecificContainerModel() {
}

if (PersonaConstructionType.COMPLEX_TYPE.equals(AssignmentsUtil.getTargetType(getModelObject().getContainerValue().getValue()))) {
ContainerWrapper<PolicyRuleType> personasWrapper = getModelObject().findContainerWrapper(new ItemPath(getObjectContainerPath(), AssignmentType.F_PERSONA_CONSTRUCTION));
ContainerWrapper<PolicyRuleType> personasWrapper = getModelObject().findContainerWrapper(new ItemPath(getModelObject().getPath(),
AssignmentType.F_PERSONA_CONSTRUCTION));
if (personasWrapper != null && personasWrapper.getValues() != null) {
personasWrapper.getValues().forEach(vw -> vw.setShowEmpty(true, false));
}
Expand All @@ -71,7 +72,4 @@ protected IModel<ContainerWrapper> getSpecificContainerModel() {
return Model.of();
}

protected QName getObjectContainerPath(){
return FocusType.F_ASSIGNMENT;
}
}

0 comments on commit ba76277

Please sign in to comment.