- Addition of Mike's "readme" presentation template

- Bootstrap updated & patch created
- Applied to Web Scripts folders
- Fixed Importer bug found with above import patch files

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6099 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
David Caruana
2007-06-25 15:22:22 +00:00
parent b535028380
commit ad1984d18d
5 changed files with 64 additions and 1 deletions

View File

@@ -173,6 +173,10 @@
<prop key="path">/${spaces.company_home.childname}/${spaces.dictionary.childname}/${spaces.templates.content.childname}</prop>
<prop key="location">alfresco/templates/content_template_examples.xml</prop>
</props>
<props>
<prop key="path">/${spaces.company_home.childname}/${spaces.dictionary.childname}/${spaces.templates.content.childname}</prop>
<prop key="location">alfresco/templates/readme_template.xml</prop>
</props>
<props>
<prop key="path">/${spaces.company_home.childname}/${spaces.dictionary.childname}/${spaces.templates.email.childname}</prop>
<prop key="location">alfresco/templates/email_templates.acp</prop>
@@ -193,6 +197,10 @@
<prop key="path">/${spaces.company_home.childname}/${spaces.dictionary.childname}</prop>
<prop key="location">alfresco/bootstrap/webScriptsExtensions.xml</prop>
</props>
<props>
<prop key="path">/${spaces.company_home.childname}/${spaces.dictionary.childname}</prop>
<prop key="location">alfresco/bootstrap/webScriptsReadme.xml</prop>
</props>
</list>
</property>
</bean>

View File

@@ -12,6 +12,9 @@
<property name="dictionaryService">
<ref bean="dictionaryService" />
</property>
<property name="nodeService">
<ref bean="nodeService" />
</property>
</bean>
<bean id="importerComponent" class="org.alfresco.repo.importer.ImporterComponent">

View File

@@ -160,3 +160,6 @@ patch.redeploySubmitProcess.description=Re-deploy WCM Submit Process Definition.
patch.AVMLocking.description=Adds existing web projects to locking service.
patch.AVMLocking.result=Necessary web projects added.
patch.ReadmeTemplate.description=Deployed ReadMe Template
patch.webScriptsReadme.description=Applied ReadMe template to Web Scripts folders

View File

@@ -827,4 +827,40 @@
</property>
</bean>
<bean id="patch.ReadmeTemplate" class="org.alfresco.repo.admin.patch.impl.GenericBootstrapPatch" parent="basePatch" >
<property name="id"><value>patch.ReadmeTemplate</value></property>
<property name="description"><value>patch.ReadmeTemplate.description</value></property>
<property name="fixesFromSchema"><value>0</value></property>
<property name="fixesToSchema"><value>59</value></property>
<property name="targetSchema"><value>60</value></property>
<!-- bootstrap view -->
<property name="importerBootstrap">
<ref bean="spacesBootstrap" />
</property>
<property name="bootstrapView">
<props>
<prop key="path">/${spaces.company_home.childname}/${spaces.dictionary.childname}/${spaces.templates.content.childname}</prop>
<prop key="location">alfresco/templates/readme_template.xml</prop>
</props>
</property>
</bean>
<bean id="patch.webScriptsReadme" class="org.alfresco.repo.admin.patch.impl.GenericBootstrapPatch" parent="basePatch" >
<property name="id"><value>patch.webScriptsReadme</value></property>
<property name="description"><value>patch.webScriptsReadme.description</value></property>
<property name="fixesFromSchema"><value>0</value></property>
<property name="fixesToSchema"><value>59</value></property>
<property name="targetSchema"><value>60</value></property>
<!-- bootstrap view -->
<property name="importerBootstrap">
<ref bean="spacesBootstrap" />
</property>
<property name="bootstrapView">
<props>
<prop key="path">/${spaces.company_home.childname}/${spaces.dictionary.childname}</prop>
<prop key="location">alfresco/bootstrap/webScriptsReadme.xml</prop>
</props>
</property>
</bean>
</beans>

View File

@@ -38,6 +38,7 @@ import org.alfresco.service.cmr.dictionary.DictionaryService;
import org.alfresco.service.cmr.dictionary.PropertyDefinition;
import org.alfresco.service.cmr.dictionary.TypeDefinition;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.cmr.security.AccessStatus;
import org.alfresco.service.cmr.view.ImporterException;
import org.alfresco.service.namespace.NamespaceService;
@@ -87,6 +88,7 @@ public class ViewParser implements Parser
// Supporting services
private NamespaceService namespaceService;
private NodeService nodeService;
private DictionaryService dictionaryService;
// Parser Context maintained during each parse
@@ -125,6 +127,14 @@ public class ViewParser implements Parser
this.namespaceService = namespaceService;
}
/**
* @param nodeService the node service
*/
public void setNodeService(NodeService nodeService)
{
this.nodeService = nodeService;
}
/**
* @param dictionaryService the dictionary service
*/
@@ -439,6 +449,7 @@ public class ViewParser implements Parser
{
NodeRef nodeRef = new NodeRef(nodeRefAttr);
node.setUUID(nodeRef.getId());
node.setTypeDefinition(dictionaryService.getType(nodeService.getType(nodeRef)));
}
else if (idRefAttr != null && idRefAttr.length() > 0)
{
@@ -449,6 +460,7 @@ public class ViewParser implements Parser
throw new ImporterException("Cannot find node referenced by id " + idRefAttr);
}
node.setUUID(nodeRef.getId());
node.setTypeDefinition(dictionaryService.getType(nodeService.getType(nodeRef)));
}
else if (pathRefAttr != null && pathRefAttr.length() > 0)
{
@@ -458,6 +470,7 @@ public class ViewParser implements Parser
throw new ImporterException("Cannot find node referenced by path " + pathRefAttr);
}
node.setUUID(referencedRef.getId());
node.setTypeDefinition(dictionaryService.getType(nodeService.getType(referencedRef)));
}
// Extract child name if explicitly defined