Skip to content

Commit

Permalink
moved all panels for object collection details page
Browse files Browse the repository at this point in the history
  • Loading branch information
KaterynaHonchar committed Sep 14, 2021
1 parent 3df31e8 commit 33fbcfb
Show file tree
Hide file tree
Showing 6 changed files with 214 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright (c) 2021 Evolveum
~
~ This work is dual-licensed under the Apache License 2.0
~ and European Union Public License. See LICENSE file for details.
-->

<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:wicket="http://wicket.apache.org">
<body>
<wicket:panel>
<div class="row">
<div class="col-md-12">
<div wicket:id="panel" />
</div>
</div>
</wicket:panel>
</body>
</html>
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
/*
* Copyright (c) 2021 Evolveum and contributors
*
* This work is dual-licensed under the Apache License 2.0
* and European Union Public License. See LICENSE file for details.
*/
package com.evolveum.midpoint.gui.impl.page.admin.objectcollection.component;

import com.evolveum.midpoint.gui.api.prism.ItemStatus;
import com.evolveum.midpoint.gui.api.prism.wrapper.PrismObjectWrapper;
import com.evolveum.midpoint.gui.impl.page.admin.AbstractObjectMainPanel;
import com.evolveum.midpoint.gui.impl.page.admin.ObjectDetailsModels;
import com.evolveum.midpoint.gui.impl.page.admin.assignmentholder.AssignmentHolderDetailsModel;
import com.evolveum.midpoint.gui.impl.prism.panel.SingleContainerPanel;
import com.evolveum.midpoint.prism.Containerable;
import com.evolveum.midpoint.prism.path.ItemName;
import com.evolveum.midpoint.util.logging.Trace;
import com.evolveum.midpoint.util.logging.TraceManager;
import com.evolveum.midpoint.web.application.PanelDisplay;
import com.evolveum.midpoint.web.application.PanelInstance;
import com.evolveum.midpoint.web.application.PanelType;
import com.evolveum.midpoint.web.model.PrismContainerWrapperModel;
import com.evolveum.midpoint.xml.ns._public.common.common_3.ContainerPanelConfigurationType;
import com.evolveum.midpoint.xml.ns._public.common.common_3.GuiObjectListViewType;
import com.evolveum.midpoint.xml.ns._public.common.common_3.ObjectCollectionType;

import org.apache.wicket.model.IModel;

@PanelType(name = "defaultView")
@PanelInstance(identifier = "defaultView",
applicableFor = ObjectCollectionType.class,
status = ItemStatus.NOT_CHANGED,
display = @PanelDisplay(label = "pageObjectCollection.defaultView.title", order = 50))
public class ObjectCollectionDefaultViewPanel extends AbstractObjectMainPanel<ObjectCollectionType, ObjectDetailsModels<ObjectCollectionType>> {
private static final long serialVersionUID = 1L;

private static final Trace LOGGER = TraceManager.getTrace(ObjectCollectionDefaultViewPanel.class);
private static final String ID_PANEL = "panel";

private static final String DOT_CLASS = ObjectCollectionDefaultViewPanel.class.getName() + ".";

public ObjectCollectionDefaultViewPanel(String id, AssignmentHolderDetailsModel<ObjectCollectionType> model, ContainerPanelConfigurationType config) {
super(id, model, config);
}

@Override
protected void initLayout() {
SingleContainerPanel panel =
new SingleContainerPanel<>(ID_PANEL,
PrismContainerWrapperModel.fromContainerWrapper(getObjectWrapperModel(), ObjectCollectionType.F_DEFAULT_VIEW),
GuiObjectListViewType.COMPLEX_TYPE);
add(panel);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright (c) 2021 Evolveum
~
~ This work is dual-licensed under the Apache License 2.0
~ and European Union Public License. See LICENSE file for details.
-->

<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:wicket="http://wicket.apache.org">
<body>
<wicket:panel>
<div class="row">
<div class="col-md-12">
<div wicket:id="panel" />
</div>
</div>
</wicket:panel>
</body>
</html>
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
/*
* Copyright (c) 2021 Evolveum and contributors
*
* This work is dual-licensed under the Apache License 2.0
* and European Union Public License. See LICENSE file for details.
*/
package com.evolveum.midpoint.gui.impl.page.admin.objectcollection.component;

import com.evolveum.midpoint.gui.api.prism.ItemStatus;
import com.evolveum.midpoint.gui.impl.page.admin.AbstractObjectMainPanel;
import com.evolveum.midpoint.gui.impl.page.admin.ObjectDetailsModels;
import com.evolveum.midpoint.gui.impl.page.admin.assignmentholder.AssignmentHolderDetailsModel;
import com.evolveum.midpoint.gui.impl.prism.panel.SingleContainerPanel;
import com.evolveum.midpoint.util.logging.Trace;
import com.evolveum.midpoint.util.logging.TraceManager;
import com.evolveum.midpoint.web.application.PanelDisplay;
import com.evolveum.midpoint.web.application.PanelInstance;
import com.evolveum.midpoint.web.application.PanelType;
import com.evolveum.midpoint.web.model.PrismContainerWrapperModel;
import com.evolveum.midpoint.xml.ns._public.common.common_3.CollectionRefSpecificationType;
import com.evolveum.midpoint.xml.ns._public.common.common_3.ContainerPanelConfigurationType;
import com.evolveum.midpoint.xml.ns._public.common.common_3.ObjectCollectionType;

@PanelType(name = "domain")
@PanelInstance(identifier = "domain",
applicableFor = ObjectCollectionType.class,
status = ItemStatus.NOT_CHANGED,
display = @PanelDisplay(label = "pageObjectCollection.domain.title", order = 60))
public class ObjectCollectionDomainPanel extends AbstractObjectMainPanel<ObjectCollectionType, ObjectDetailsModels<ObjectCollectionType>> {
private static final long serialVersionUID = 1L;

private static final Trace LOGGER = TraceManager.getTrace(ObjectCollectionDomainPanel.class);
private static final String ID_PANEL = "panel";

private static final String DOT_CLASS = ObjectCollectionDomainPanel.class.getName() + ".";

public ObjectCollectionDomainPanel(String id, AssignmentHolderDetailsModel<ObjectCollectionType> model, ContainerPanelConfigurationType config) {
super(id, model, config);
}

@Override
protected void initLayout() {
SingleContainerPanel panel =
new SingleContainerPanel<>(ID_PANEL,
PrismContainerWrapperModel.fromContainerWrapper(getObjectWrapperModel(), ObjectCollectionType.F_DOMAIN),
CollectionRefSpecificationType.COMPLEX_TYPE);
add(panel);
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ Copyright (c) 2021 Evolveum
~
~ This work is dual-licensed under the Apache License 2.0
~ and European Union Public License. See LICENSE file for details.
-->

<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:wicket="http://wicket.apache.org">
<body>
<wicket:panel>
<div class="row">
<div class="col-md-12">
<div wicket:id="panel" />
</div>
</div>
</wicket:panel>
</body>
</html>
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
/*
* Copyright (c) 2021 Evolveum and contributors
*
* This work is dual-licensed under the Apache License 2.0
* and European Union Public License. See LICENSE file for details.
*/
package com.evolveum.midpoint.gui.impl.page.admin.objectcollection.component;

import com.evolveum.midpoint.gui.api.prism.ItemStatus;
import com.evolveum.midpoint.gui.impl.page.admin.AbstractObjectMainPanel;
import com.evolveum.midpoint.gui.impl.page.admin.ObjectDetailsModels;
import com.evolveum.midpoint.gui.impl.page.admin.assignmentholder.AssignmentHolderDetailsModel;
import com.evolveum.midpoint.gui.impl.prism.panel.SingleContainerPanel;
import com.evolveum.midpoint.util.logging.Trace;
import com.evolveum.midpoint.util.logging.TraceManager;
import com.evolveum.midpoint.web.application.PanelDisplay;
import com.evolveum.midpoint.web.application.PanelInstance;
import com.evolveum.midpoint.web.application.PanelType;
import com.evolveum.midpoint.web.model.PrismContainerWrapperModel;
import com.evolveum.midpoint.xml.ns._public.common.common_3.ContainerPanelConfigurationType;
import com.evolveum.midpoint.xml.ns._public.common.common_3.ObjectCollectionType;
import com.evolveum.midpoint.xml.ns._public.common.common_3.SelectorQualifiedGetOptionsType;

@PanelType(name = "objectCollectionOption")
@PanelInstance(identifier = "objectCollectionOption",
applicableFor = ObjectCollectionType.class,
status = ItemStatus.NOT_CHANGED,
display = @PanelDisplay(label = "pageObjectCollection.option.title", order = 70))
public class ObjectCollectionOptionPanel extends AbstractObjectMainPanel<ObjectCollectionType, ObjectDetailsModels<ObjectCollectionType>> {
private static final long serialVersionUID = 1L;

private static final Trace LOGGER = TraceManager.getTrace(ObjectCollectionOptionPanel.class);
private static final String ID_PANEL = "panel";

private static final String DOT_CLASS = ObjectCollectionOptionPanel.class.getName() + ".";

public ObjectCollectionOptionPanel(String id, AssignmentHolderDetailsModel<ObjectCollectionType> model, ContainerPanelConfigurationType config) {
super(id, model, config);
}

@Override
protected void initLayout() {
SingleContainerPanel panel =
new SingleContainerPanel<>(ID_PANEL,
PrismContainerWrapperModel.fromContainerWrapper(getObjectWrapperModel(), ObjectCollectionType.F_GET_OPTIONS),
SelectorQualifiedGetOptionsType.COMPLEX_TYPE);
add(panel);
}

}

0 comments on commit 33fbcfb

Please sign in to comment.