-
Type: Bug
-
Status: Open
-
Priority: Major
-
Resolution: Unresolved
-
Affects Version/s: 2.4.2
-
Fix Version/s: QualifiedToSchedule
-
Component/s: Mail & Document Templates
-
Backlog priority:200
Steps to reproduce:
- add a structure template for the "root" doc type, adding a child domain, and add ACLs to the domain
- add another structure template for the "domain" doc type
=> the generated extensions contain:
<factoryBinding name="RootFactory" factoryName="SimpleTemplateRootFactory" targetType="Root"> <acl> <ace principal="Administrator" permission="Everything" granted="true"/> <ace principal="administrators" permission="Everything" granted="true"/> <ace principal="members" permission="Read" granted="true"/> <ace principal="members" permission="Version" granted="true"/> </acl> <template> <templateItem typeName="Domain" id="default-domain" title="Default Domain" description="Nuxeo 5 Default Domain"/> <templateItem typeName="test" id="yo3" title="" description=""/> <templateItem typeName="Contract" id="Unnamed" title="" description=""/> </template> </factoryBinding> <factoryBinding name="DomainFactory" factoryName="SimpleTemplateFactory" targetType="Domain"> <acl> <ace principal="bidule" permission="Read" granted="true"/> </acl> </factoryBinding> <factoryBinding name="DomainFactory" factoryName="SimpleTemplateFactory" targetType="Domain"> <template> <templateItem typeName="WorkspaceRoot" id="workspaces" title="Workspaces" description="Workspace Root"/> <templateItem typeName="SectionRoot" id="sections" title="Sections" description="Sections Root"/> <templateItem typeName="TemplateRoot" id="templates" title="Templates" description="Workspace Templates Root"/> </template> </factoryBinding>
=> the duplicate DomainFactory contribution makes the initialization fail (root has not content).
Note that problem was repoduced when ordering of contributions was not derterministic, Vlad had a use case with the acl contribution at the end.
Removing ACLs on the root factory for the domain fixes the issue.