cancel
Showing results for 
Search instead for 
Did you mean: 

ACL registration not visible on nuxeo SDK when defined in ContentTemplateService factoryBinding extension

joannadark_
Confirmed Champ
Confirmed Champ

I can prove that these registered ACLs are set in my unit test but I am unable to view through the GUI using the Nuxeo SDK. Below is my content-template-contrib.xml file and my unit test. I was able to see my ACL customizations when I installed my marketplace package in a normal nuxeo instance.

<require>org.nuxeo.ecm.platform.content.template.service.ContentTemplateService.defaultContrib</require>
<extension target="org.nuxeo.ecm.platform.content.template.service.TemplateService" point="factoryBinding">
  <factoryBinding name="RootFactory" factoryName="SimpleTemplateRootFactory" targetType="Root" append="true">
  <acl>
    <ace granted="true" permission="Everything" principal="administrators" />
    <ace granted="true" permission="Read" principal="members" />
  </acl>
  <template>
    <templateItem id="default-domain" title="Default Domain" typeName="Domain">
      <acl>
        <ace granted="true" permission="Everything" principal="administrators" />
        <ace granted="false" permission="Everything" principal="Everyone" /> <!--blocks permissions inheritance -->
      </acl>
    </templateItem>
  </template>
</factoryBinding>
</extension>

My test:

@Test
public void testACLs() throws ClientException {
  DocumentRef defaultDomainRef = new PathRef("/default-domain");
  DocumentModel defaultDomain = session.getDocument(defaultDomainRef);
  assertNotnull(defaultDomain);
  assertTrue(defaultDomain.getACP().getAccess("administrators","Everything").toBoolean();
  assertFalse(defaultDomain.getACP().getAccess("Everyone","Everything").toBoolean();
}

Am I missing something?

0 REPLIES 0
Getting started

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.