X-Git-Url: https://git.argeo.org/?a=blobdiff_plain;f=org.argeo.cms.e4%2Fsrc%2Forg%2Fargeo%2Fcms%2Fe4%2Fusers%2FGroupEditor.java;h=9ba7af72f32b698af229430d333881f500c091e3;hb=5986e55820cba0821f0c16627c4ab144863c82ab;hp=a4d8317b2f4d6d4b669df2a2c363406101f38937;hpb=e7dc62c485696931a3e048d9102a7c86f9323b92;p=lgpl%2Fargeo-commons.git diff --git a/org.argeo.cms.e4/src/org/argeo/cms/e4/users/GroupEditor.java b/org.argeo.cms.e4/src/org/argeo/cms/e4/users/GroupEditor.java index a4d8317b2..9ba7af72f 100644 --- a/org.argeo.cms.e4/src/org/argeo/cms/e4/users/GroupEditor.java +++ b/org.argeo.cms.e4/src/org/argeo/cms/e4/users/GroupEditor.java @@ -1,18 +1,3 @@ -/* - * Copyright (C) 2007-2012 Argeo GmbH - * - * 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 org.argeo.cms.e4.users; import static org.argeo.api.NodeInstance.WORKGROUP; @@ -32,7 +17,6 @@ import javax.jcr.RepositoryException; import javax.jcr.Session; import javax.naming.InvalidNameException; import javax.naming.ldap.LdapName; -import javax.transaction.UserTransaction; import org.argeo.api.NodeConstants; import org.argeo.api.NodeInstance; @@ -51,6 +35,7 @@ import org.argeo.eclipse.ui.EclipseUiUtils; import org.argeo.eclipse.ui.parts.LdifUsersTable; import org.argeo.jcr.JcrUtils; import org.argeo.naming.LdapAttrs; +import org.argeo.osgi.transaction.WorkTransaction; import org.eclipse.e4.ui.workbench.modeling.EPartService; import org.eclipse.jface.action.Action; import org.eclipse.jface.action.ToolBarManager; @@ -529,7 +514,7 @@ public class GroupEditor extends AbstractRoleEditor { userAdminWrapper.notifyListeners(new UserAdminEvent(null, UserAdminEvent.ROLE_CHANGED, myGroup)); } else if (role.getType() == Role.USER) { // TODO check if the group is already member of this group - UserTransaction transaction = userAdminWrapper.beginTransactionIfNeeded(); + WorkTransaction transaction = userAdminWrapper.beginTransactionIfNeeded(); User user = (User) role; myGroup.addMember(user); if (UserAdminWrapper.COMMIT_ON_SAVE)