Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into feature/plugin-support
Browse files Browse the repository at this point in the history
  • Loading branch information
1azyman committed Sep 6, 2019
2 parents 5dcd706 + 503bcb1 commit a7d40bb
Show file tree
Hide file tree
Showing 86 changed files with 1,767 additions and 865 deletions.
21 changes: 18 additions & 3 deletions build-system/pom.xml
Expand Up @@ -104,6 +104,7 @@
<geronimo-ws-metadata_2.0_spec.version>1.1.3</geronimo-ws-metadata_2.0_spec.version>
<activation.version>1.1.1</activation.version>
<javax.activation.version>1.2.0</javax.activation.version>
<jetty.version>9.4.20.v20190813</jetty.version>
</properties>
<dependencyManagement>
<dependencies>
Expand Down Expand Up @@ -1321,7 +1322,22 @@
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-server</artifactId>
<version>9.4.17.v20190418</version>
<version>${jetty.version}</version>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-http</artifactId>
<version>${jetty.version}</version>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-io</artifactId>
<version>${jetty.version}</version>
</dependency>
<dependency>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-util</artifactId>
<version>${jetty.version}</version>
</dependency>
<dependency>
<groupId>org.apache.qpid</groupId>
Expand Down Expand Up @@ -1506,7 +1522,7 @@
<plugin>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-maven-plugin</artifactId>
<version>9.4.19.v20190610</version>
<version>${jetty.version}</version>
<configuration>
<systemProperties>
<systemProperty>
Expand All @@ -1525,7 +1541,6 @@
</configuration>
</plugin>


<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion config/sql/_all/oracle-4.0-all.sql
Expand Up @@ -876,7 +876,7 @@ CREATE UNIQUE INDEX iPrimaryIdentifierValueWithOC
ON m_shadow (
CASE WHEN primaryIdentifierValue IS NOT NULL AND objectClass IS NOT NULL AND resourceRef_targetOid IS NOT NULL THEN primaryIdentifierValue END,
CASE WHEN primaryIdentifierValue IS NOT NULL AND objectClass IS NOT NULL AND resourceRef_targetOid IS NOT NULL THEN objectClass END,
CASE WHEN primaryIdentifierValue IS NOT NULL AND objectClass IS NOT NULL AND resourceRef_targetOid IS NOT NULL THEN resourceRef_targetOid END)
CASE WHEN primaryIdentifierValue IS NOT NULL AND objectClass IS NOT NULL AND resourceRef_targetOid IS NOT NULL THEN resourceRef_targetOid END);
CREATE INDEX iParent
ON m_task (parent) INITRANS 30;
CREATE INDEX iTaskObjectOid ON m_task(objectRef_targetOid) INITRANS 30;
Expand Down
11 changes: 11 additions & 0 deletions gui/admin-gui/pom.xml
Expand Up @@ -174,6 +174,17 @@
<artifactId>spring-boot-actuator-autoconfigure</artifactId>
</dependency>

<dependency>
<groupId>javax.ws.rs</groupId>
<artifactId>javax.ws.rs-api</artifactId>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-rt-rs-client</artifactId>
<scope>compile</scope>
</dependency>

<!-- webjars -->
<dependency>
<groupId>org.webjars</groupId>
Expand Down
Expand Up @@ -23,6 +23,7 @@
import com.evolveum.midpoint.schema.constants.ObjectTypes;
import com.evolveum.midpoint.web.component.data.column.ColumnUtils;
import com.evolveum.midpoint.web.component.util.SelectableBean;
import com.evolveum.midpoint.web.component.util.TreeSelectableBean;
import com.evolveum.midpoint.web.component.util.VisibleEnableBehaviour;
import com.evolveum.midpoint.xml.ns._public.common.common_3.AbstractRoleType;
import com.evolveum.midpoint.xml.ns._public.common.common_3.AssignmentHolderType;
Expand Down
Expand Up @@ -18,6 +18,7 @@
import com.evolveum.midpoint.prism.query.ObjectFilter;
import com.evolveum.midpoint.schema.constants.ObjectTypes;
import com.evolveum.midpoint.web.component.util.SelectableBean;
import com.evolveum.midpoint.web.component.util.TreeSelectableBean;
import com.evolveum.midpoint.web.component.util.VisibleEnableBehaviour;
import com.evolveum.midpoint.web.page.admin.orgs.OrgTreeAssignablePanel;
import com.evolveum.midpoint.xml.ns._public.common.common_3.AssignmentType;
Expand Down Expand Up @@ -51,8 +52,8 @@ protected void onInitialize() {
private static final long serialVersionUID = 1L;

@Override
protected void onOrgTreeCheckBoxSelectionPerformed(AjaxRequestTarget target, IModel<SelectableBean<OrgType>> rowModel) {
onSelectionPerformed(target, rowModel);
protected void onOrgTreeCheckBoxSelectionPerformed(AjaxRequestTarget target, IModel<TreeSelectableBean<OrgType>> rowModel) {
onSelectionPerformed(target, (IModel) rowModel);
}

@Override
Expand Down
Expand Up @@ -18,6 +18,7 @@
import com.evolveum.midpoint.schema.constants.ObjectTypes;
import com.evolveum.midpoint.schema.constants.RelationTypes;
import com.evolveum.midpoint.web.component.util.SelectableBean;
import com.evolveum.midpoint.web.component.util.TreeSelectableBean;
import com.evolveum.midpoint.web.page.admin.orgs.OrgTreeAssignablePanel;
import com.evolveum.midpoint.xml.ns._public.common.common_3.OrgType;
import org.apache.wicket.ajax.AjaxRequestTarget;
Expand Down Expand Up @@ -49,8 +50,8 @@ protected void onInitialize() {
private static final long serialVersionUID = 1L;

@Override
protected void onOrgTreeCheckBoxSelectionPerformed(AjaxRequestTarget target, IModel<SelectableBean<OrgType>> rowModel) {
onSelectionPerformed(target, rowModel);
protected void onOrgTreeCheckBoxSelectionPerformed(AjaxRequestTarget target, IModel<TreeSelectableBean<OrgType>> rowModel) {
onSelectionPerformed(target, (IModel) rowModel);
}

@Override
Expand Down
Expand Up @@ -16,6 +16,7 @@

package com.evolveum.midpoint.gui.api.component.form;

import com.evolveum.midpoint.web.component.util.VisibleBehaviour;
import com.evolveum.midpoint.web.component.util.VisibleEnableBehaviour;

import org.apache.wicket.AttributeModifier;
Expand All @@ -40,6 +41,10 @@ public class CheckBoxPanel extends Panel {
private static final String ID_CHECK = "check";
private static final String ID_LABEL = "label";

public CheckBoxPanel(String id, IModel<Boolean> checkboxModel) {
this(id, checkboxModel, null, null, null);
}

public CheckBoxPanel(String id, IModel<Boolean> checkboxModel, final IModel<Boolean> visibilityModel,
IModel<String> labelModel, IModel<String> tooltipModel) {
super(id);
Expand All @@ -61,6 +66,7 @@ protected void updateAjaxAttributes(AjaxRequestAttributes attributes) {
}
};
check.setOutputMarkupId(true);

if (visibilityModel != null) {
check.add(new VisibleEnableBehaviour() {
private static final long serialVersionUID = 1L;
Expand All @@ -74,6 +80,7 @@ public boolean isEnabled() {
container.add(check);

Label label = new Label(ID_LABEL, labelModel);
label.add(new VisibleBehaviour(() -> labelModel != null));
label.setRenderBodyOnly(true);
container.add(label);

Expand Down
Expand Up @@ -76,6 +76,7 @@
import com.evolveum.midpoint.security.api.SecurityContextManager;
import com.evolveum.midpoint.security.enforcer.api.AuthorizationParameters;
import com.evolveum.midpoint.security.enforcer.api.SecurityEnforcer;
import com.evolveum.midpoint.task.api.ClusterExecutionHelper;
import com.evolveum.midpoint.task.api.Task;
import com.evolveum.midpoint.task.api.TaskCategory;
import com.evolveum.midpoint.task.api.TaskManager;
Expand Down Expand Up @@ -334,6 +335,8 @@ public abstract class PageBase extends WebPage implements ModelServiceLocator {

@SpringBean private CounterManager counterManager;

@SpringBean private ClusterExecutionHelper clusterExecutionHelper;

private List<Breadcrumb> breadcrumbs;

private boolean initialized = false;
Expand Down Expand Up @@ -564,6 +567,9 @@ public AuditService getAuditService() {
return auditService;
}

public ClusterExecutionHelper getClusterExecutionHelper() {
return clusterExecutionHelper;
}

public AccessCertificationService getCertificationService() {
return certficationService;
Expand Down
Expand Up @@ -48,6 +48,7 @@ public class SelectableBean<T extends Serializable> extends Selectable<T> implem

//TODO probably this should not be here. find better place if needed, e.g. subclass with specific behaviour and attributes.
private int activeSessions;
private List<String> nodes;

/**
* Result of object retrieval (or attempt of object retrieval). It case that it is not error the result is optional.
Expand Down Expand Up @@ -91,6 +92,14 @@ public int getActiveSessions() {
return activeSessions;
}

public List<String> getNodes() {
return nodes;
}

public void setNodes(List<String> nodes) {
this.nodes = nodes;
}

public List<InlineMenuItem> getMenuItems() {
if (menuItems == null) {
menuItems = new ArrayList<>();
Expand Down
@@ -0,0 +1,84 @@
/*
* Copyright (c) 2010-2017 Evolveum
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

package com.evolveum.midpoint.web.component.util;

import com.evolveum.midpoint.schema.result.OperationResult;
import com.evolveum.midpoint.schema.util.MiscSchemaUtil;
import com.evolveum.midpoint.util.DebugDumpable;
import com.evolveum.midpoint.util.DebugUtil;
import com.evolveum.midpoint.util.exception.SchemaException;
import com.evolveum.midpoint.util.logging.Trace;
import com.evolveum.midpoint.util.logging.TraceManager;
import com.evolveum.midpoint.web.component.data.column.InlineMenuable;
import com.evolveum.midpoint.web.component.menu.cog.InlineMenuItem;
import com.evolveum.midpoint.xml.ns._public.common.common_3.OperationResultType;
import org.apache.wicket.markup.html.navigation.paging.IPageable;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
* @author lazyman
*/
public class TreeSelectableBean<T extends Serializable> extends SelectableBean<T> implements IPageable {

private static final Trace LOGGER = TraceManager.getTrace(TreeSelectableBean.class);

public TreeSelectableBean() {
super();
}

public TreeSelectableBean(T value) {
super(value);
}


private long offset=0;
private long count=20;

public long getOffset() {
return offset;
}

public void setOffset(long offset) {
this.offset = offset;
}

public long getCount() {
return count;
}

public void setCount(long count) {
this.count = count;
}

@Override
public long getCurrentPage() {
return 0;
}

@Override
public void setCurrentPage(long page) {

}

@Override
public long getPageCount() {
return 10;
}
}

0 comments on commit a7d40bb

Please sign in to comment.