Fixed AWC-487: Added patch to grant required permissions to 'Saved Searches' folder

Fixed I18N of SavedSearchFolderPatch
Neatened up patch logging


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2276 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2006-02-01 15:36:03 +00:00
parent 2bdace676d
commit 9be5d15ad1
6 changed files with 219 additions and 49 deletions

View File

@@ -1,14 +1,20 @@
# PatchService messages
patch.service.not_relevant=Not relevant to schema {0}
patch.executer.not_executed=Applied patch (not executed): \nID: {0}\nRESULT: \n{1}
patch.executer.executed=Applied patch: \nID: {0}\nRESULT: \n{1}
patch.executer.failed=Failed to apply patch: \nID: {0}\nRESULT: \n{1}
patch.executer.checking=Checking for patches to apply ...
patch.executer.no_patches_required=No patches were required.
patch.executer.not_executed =\n=== Recorded patch (not executed) === \nID: {0}\nRESULT: \n{1}\n=====================================
patch.executer.executed =\n=== Applied patch === \nID: {0}\nRESULT: \n{1}\n=====================================
patch.executer.failed =\n=== Failed to apply patch === \nID: {0}\nRESULT: \n{1}\n=====================================
# Individual patch messages
patch.savedSearchesFolder.description=Ensures the existence of the 'Saved Searches' folder.
patch.savedSearchesFolder.result.exists=The saved searches folder already exists: {0}
patch.savedSearchesFolder.result.created=The saved searches folder successfully created: {0}
patch.savedSearchesFolder.result.created=The saved searches folder was successfully created: {0}
patch.savedSearchesPermission.description=Sets required permissions on 'Saved Searches' folder.
patch.savedSearchesPermission.result.applied=Granted CONTRIBUTOR role to EVERYONE on 'Saved Searches' folder: {0}.
patch.savedSearchesPermission.err.not_found='Saved Searches' folder could not be found.
patch.updatePermissionData.description=Update permission entries from 'folder' to 'cmobject'.
patch.updatePermissionData.result=Created the following permission reference names: {0}. \nUpdated {1} permission entries.

View File

@@ -72,14 +72,12 @@
</list>
</property>
</bean>
<!-- -->
<!-- Helper beans -->
<!-- -->
<!-- patch definitions -->
<bean id="patch.savedSearchesFolder" class="org.alfresco.repo.admin.patch.impl.SavedSearchFolderPatch" parent="basePatch" >
<property name="id"><value>patch.savedSearchesFolder</value></property>
<property name="description"><value>patch.savedSearchesFolder.description</value></property>
<property name="fixesFromSchema"><value>0</value></property>
<property name="fixesToSchema"><value>1</value></property>
<property name="targetSchema"><value>2</value></property>
<bean id="patch.savedSearches.Base" abstract="true" parent="basePatch" >
<!-- helper beans for execution -->
<property name="importerBootstrap">
<ref bean="importerBootstrap" />
@@ -95,6 +93,46 @@
</property>
</bean>
<bean id="bootstrapSpacesMessageSource" class="org.springframework.context.support.ResourceBundleMessageSource">
<property name="basenames">
<list>
<value>alfresco/messages/bootstrap-spaces</value>
</list>
</property>
</bean>
<!-- -->
<!-- Patch definitions -->
<!-- -->
<bean id="patch.savedSearchesFolder" class="org.alfresco.repo.admin.patch.impl.SavedSearchFolderPatch" parent="patch.savedSearches.Base" >
<property name="id"><value>patch.savedSearchesFolder</value></property>
<property name="description"><value>patch.savedSearchesFolder.description</value></property>
<property name="fixesFromSchema"><value>0</value></property>
<property name="fixesToSchema"><value>1</value></property>
<property name="targetSchema"><value>2</value></property>
<!-- helper beans for execution -->
<property name="messageSource">
<ref bean="bootstrapSpacesMessageSource" />
</property>
</bean>
<bean id="patch.savedSearchesPermission" class="org.alfresco.repo.admin.patch.impl.SavedSearchPermissionPatch" parent="patch.savedSearches.Base" >
<property name="id"><value>patch.savedSearchesPermission</value></property>
<property name="description"><value>patch.savedSearchesPermission.description</value></property>
<property name="fixesFromSchema"><value>0</value></property>
<property name="fixesToSchema"><value>4</value></property>
<property name="targetSchema"><value>5</value></property>
<!-- helper beans for execution -->
<property name="permissionService">
<ref bean="permissionService"/>
</property>
<!-- dependent on presence of saved searches folder -->
<property name="dependsOn" >
<list>
<ref bean="patch.savedSearchesFolder" />
</list>
</property>
</bean>
<bean id="patch.updatePermissionData" class="org.alfresco.repo.admin.patch.impl.PermissionDataPatch" parent="basePatch" >
<property name="id"><value>patch.updatePermissionData</value></property>
<property name="description"><value>patch.updatePermissionData.description</value></property>
@@ -132,7 +170,7 @@
<ref bean="namespaceService" />
</property>
<property name="messageSource">
<ref bean="guestMessageSource" />
<ref bean="bootstrapSpacesMessageSource" />
</property>
</bean>
<bean id="patch.fixNodeSerializableValues" class="org.alfresco.repo.admin.patch.impl.NodePropertySerializablePatch" parent="basePatch" >
@@ -147,14 +185,6 @@
</property>
</bean>
<bean id="guestMessageSource" class="org.springframework.context.support.ResourceBundleMessageSource">
<property name="basenames">
<list>
<value>alfresco/messages/bootstrap-spaces</value>
</list>
</property>
</bean>
<!-- This component ensures that patches get applied on startup -->
<!-- The order is important here. All the self-registering patches must be defined before this bean -->
<bean id="patchExecuter"