10-01-2009 11:30 AM
public String createUser(Map<QName, Serializable> props, String userName) {
NodeRef newPerson = this.personService.createPerson(props);
this.permissionService.setPermission(newPerson, userName, this.permissionService.getAllPermission(), true);
String password = AuthenticationUtils.getUserPassword(userName);
this.authenticationService.createAuthentication(userName, password.toCharArray());
this.nodeService.setType(newPerson, DecathlonModel.TYPE_USER);
this.nodeService.setProperty(newPerson, DecathlonModel.PROP_DROITS, new ArrayList<String>());
return password;
}
J'aimerais que mes utilisateurs aient les droits administrateurs, getAllPermission ne le fais pas apparemment.javax.faces.el.EvaluationException: Exception while invoking expression #{DocumentDetailsDialog.startCorrection}
at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:156)
at javax.faces.component.UICommand.broadcast(UICommand.java:89)
at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:97)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:171)
at org.apache.myfaces.lifecycle.InvokeApplicationExecutor.execute(InvokeApplicationExecutor.java:32)
at org.apache.myfaces.lifecycle.LifecycleImpl.executePhase(LifecycleImpl.java:95)
at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:70)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:139)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.alfresco.web.app.servlet.AuthenticationFilter.doFilter(AuthenticationFilter.java:81)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
10-02-2009 03:16 AM
this.permissionService.setPermission(newPerson, userName, PermissionService.FULL_CONTROL, true);
10-02-2009 05:28 AM
10-02-2009 06:08 AM
caused by:
org.alfresco.repo.security.permissions.AccessDeniedException: Accès interdit. Vous n'avez pas la permission de réaliser cette opération.
caused by:
net.sf.acegisecurity.AccessDeniedException: Access is denied.
this.lockService.lock(nodeRef, LockType.WRITE_LOCK);
10-02-2009 08:02 AM
this.permissionService.setPermission(newPerson, userName, this.permissionService.getAllPermission(), true);
this.authorityService.addAuthority("GROUP_ALFRESCO_ADMINISTRATORS", userName);
10-02-2009 09:35 AM
En fait ça donne tous les droits sur le noeud cmerson, pas sur des espaces ou des documents.Effectivement j'ai créé un fichier de configuration pour mon espace ou les documents sont rangés (document-space.xml)
<view:acl view:inherit="false">
<view:ace view:access="ALLOWED">
<view:authority>GROUP_EVERYONE</view:authority>
<view:permission>Consumer</view:permission>
</view:ace>
</view:acl>
<view:permission>All</view:permission>
Dans mon fichier de config d'espace.Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.