mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
RM-563 (Add group id and title to Capability API and definitions)
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/modules/recordsmanagement/HEAD@43933 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -6,37 +6,37 @@
|
||||
<!-- Assignable Capabilities -->
|
||||
|
||||
<bean id="rmAccessAuditCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmAuditGroup">
|
||||
<property name="name" value="AccessAudit"/>
|
||||
<property name="permission" value="AccessAudit"/>
|
||||
</bean>
|
||||
|
||||
<bean id="rmDeclareAuditAsRecordCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmAuditGroup">
|
||||
<property name="name" value="DeclareAuditAsRecord" />
|
||||
<property name="permission" value="DeclareAuditAsRecord" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmDeleteAuditCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmAuditGroup">
|
||||
<property name="name" value="DeleteAudit" />
|
||||
<property name="permission" value="DeleteAudit" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmEnableDisableAuditByTypesCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmAuditGroup">
|
||||
<property name="name" value="EnableDisableAuditByTypes" />
|
||||
<property name="permission" value="EnableDisableAuditByTypes" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmExportAuditCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmAuditGroup">
|
||||
<property name="name" value="ExportAudit" />
|
||||
<property name="permission" value="ExportAudit" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmSelectAuditMetadataCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmAuditGroup">
|
||||
<property name="name" value="SelectAuditMetadata" />
|
||||
<property name="permission" value="SelectAuditMetadata" />
|
||||
</bean>
|
||||
|
@@ -2,12 +2,11 @@
|
||||
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>
|
||||
|
||||
<beans>
|
||||
|
||||
<!-- Assignable Capabilities -->
|
||||
|
||||
<!-- Cut off -->
|
||||
<bean id="rmApproveRecordsScheduledForCutoffCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmCutoffGroup">
|
||||
<property name="name" value="ApproveRecordsScheduledForCutoff"/>
|
||||
<property name="permission" value="ApproveRecordsScheduledForCutoff"/>
|
||||
<property name="kinds">
|
||||
@@ -35,6 +34,7 @@
|
||||
<ref bean="rmCompleteAllTransfersCapability"/>
|
||||
</list>
|
||||
</property>
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
|
||||
<!-- Accession -->
|
||||
@@ -48,6 +48,7 @@
|
||||
<ref bean="rmCompleteNominatedTransfersCapability"/>
|
||||
</list>
|
||||
</property>
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
|
||||
<!-- Destroy -->
|
||||
@@ -68,6 +69,7 @@
|
||||
<entry key="capabilityCondition.destroyIsScheduled" value="true"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
|
||||
<!-- Unscheduled Destroy -->
|
||||
@@ -88,6 +90,7 @@
|
||||
<entry key="capabilityCondition.destroyMayBeScheduled" value="true"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
|
||||
<!-- Manually Change Disposition Dates -->
|
||||
@@ -109,6 +112,7 @@
|
||||
<entry key="capabilityCondition.isTransferring" value="false" />
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
|
||||
<!-- Non-assignable Capabilities -->
|
||||
|
@@ -16,6 +16,7 @@
|
||||
<ref bean="rmCreateModifyDestroyUnfiledRecordContainerCapability"/>
|
||||
</list>
|
||||
</property>
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<!-- Unassignable Capabilities -->
|
||||
|
@@ -6,7 +6,7 @@
|
||||
<!-- Public Capabilities -->
|
||||
|
||||
<bean id="rmExtendRetentionPeriodOrFreezeCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmHoldControlsGroup">
|
||||
<property name="name" value="ExtendRetentionPeriodOrFreeze"/>
|
||||
<property name="permission" value="ExtendRetentionPeriodOrFreeze"/>
|
||||
<property name="kinds">
|
||||
@@ -24,7 +24,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="rmUnfreezeCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmHoldControlsGroup">
|
||||
<property name="name" value="Unfreeze"/>
|
||||
<property name="permission" value="Unfreeze"/>
|
||||
<property name="conditions">
|
||||
@@ -36,7 +36,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="rmViewUpdateReasonsForFreezeCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmHoldControlsGroup">
|
||||
<property name="name" value="ViewUpdateReasonsForFreeze"/>
|
||||
<property name="permission" value="ViewUpdateReasonsForFreeze"/>
|
||||
<property name="conditions">
|
||||
|
@@ -9,12 +9,14 @@
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="CreateAndAssociateSelectionLists"/>
|
||||
<property name="permission" value="CreateAndAssociateSelectionLists"/>
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmEditSelectionListsCapability"
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="EditSelectionLists" />
|
||||
<property name="permission" value="EditSelectionLists" />
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<!-- Non-Assignable Capabilities -->
|
||||
|
@@ -7,6 +7,7 @@
|
||||
parent="rmBaseCapability"
|
||||
class="org.alfresco.module.org_alfresco_module_rm.capability.impl.ViewRecordsCapability">
|
||||
<property name="name" value="ViewRecords" />
|
||||
<property name="groupId" value="records" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmUndeclareRecordsCapability"
|
||||
@@ -26,10 +27,11 @@
|
||||
<entry key="capabilityCondition.cutoff" value="false"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="records" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyRecordsInCuttoffFoldersCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmCutoffGroup">
|
||||
<property name="name" value="CreateModifyRecordsInCutoffFolders"/>
|
||||
<property name="permission" value="CreateModifyRecordsInCutoffFolders"/>
|
||||
<property name="kinds">
|
||||
@@ -103,26 +105,7 @@
|
||||
<entry key="capabilityCondition.declared" value="false"/>
|
||||
</map>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="rmDeclareRecordsInClosedFoldersCapability"
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="DeclareRecordsInClosedFolders"/>
|
||||
<property name="permission" value="DeclareRecordsInClosedFolders"/>
|
||||
<property name="kinds">
|
||||
<list>
|
||||
<value>RECORD</value>
|
||||
</list>
|
||||
</property>
|
||||
<property name="conditions">
|
||||
<map>
|
||||
<entry key="capabilityCondition.filling" value="true"/>
|
||||
<entry key="capabilityCondition.cutoff" value="false"/>
|
||||
<entry key="capabilityCondition.frozen" value="false"/>
|
||||
<entry key="capabilityCondition.closed" value="true"/>
|
||||
<entry key="capabilityCondition.declared" value="false"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="records"/>
|
||||
</bean>
|
||||
|
||||
<bean id="rmDeleteRecordsCapability"
|
||||
@@ -139,6 +122,7 @@
|
||||
<entry key="capabilityCondition.frozen" value="false"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmEditDeclaredRecordMetadataCapability"
|
||||
@@ -158,6 +142,7 @@
|
||||
<entry key="capabilityCondition.declared" value="true"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="metadataControl"/>
|
||||
</bean>
|
||||
|
||||
<!-- TODO .. this is being used for the wrong thing! ... should indicate that the use can edit the non-record meta-data of a record -->
|
||||
@@ -173,6 +158,7 @@
|
||||
<entry key="capabilityCondition.frozen" value="false"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="metadataControl"/>
|
||||
</bean>
|
||||
|
||||
<bean id="rmEditRecordMetadataCapability"
|
||||
@@ -194,6 +180,7 @@
|
||||
<entry key="capabilityCondition.declared" value="false"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="metadataControl"/>
|
||||
</bean>
|
||||
|
||||
<bean id="rmMoveRecordsCapability"
|
||||
@@ -209,10 +196,11 @@
|
||||
</map>
|
||||
</property>
|
||||
<property name="targetCapability" ref="rmFileRecordsCapability"/>
|
||||
<property name="groupId" value="metadataControl"/>
|
||||
</bean>
|
||||
|
||||
<bean id="rmUpgradeDowngradeAndDeclassifyRecordsCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmClassifiedRecordsGroup">
|
||||
<property name="name" value="UpgradeDowngradeAndDeclassifyRecords"/>
|
||||
<property name="permission" value="UpgradeDowngradeAndDeclassifyRecords"/>
|
||||
<property name="conditions">
|
||||
@@ -222,23 +210,4 @@
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="rmReOpenFoldersCapability"
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="ReOpenFolders"/>
|
||||
<property name="permission" value="ReOpenFolders"/>
|
||||
<property name="kinds">
|
||||
<list>
|
||||
<value>RECORD_FOLDER</value>
|
||||
</list>
|
||||
</property>
|
||||
<property name="conditions">
|
||||
<map>
|
||||
<entry key="capabilityCondition.filling" value="true"/>
|
||||
<entry key="capabilityCondition.cutoff" value="false"/>
|
||||
<entry key="capabilityCondition.frozenOrFrozenChildren" value="false"/>
|
||||
<entry key="capabilityCondition.closed" value="true"/>
|
||||
</map>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
</beans>
|
@@ -4,7 +4,7 @@
|
||||
<beans>
|
||||
|
||||
<bean id="rmCloseFoldersCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmFolderControlGroup">
|
||||
<property name="name" value="CloseFolders"/>
|
||||
<property name="permission" value="CloseFolders"/>
|
||||
<property name="kinds">
|
||||
@@ -23,7 +23,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyDestroyFoldersCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmFolderControlGroup">
|
||||
<property name="name" value="CreateModifyDestroyFolders"/>
|
||||
<property name="permission" value="CreateModifyDestroyFolders"/>
|
||||
<property name="kinds">
|
||||
@@ -55,4 +55,42 @@
|
||||
<property name="targetCapability" ref="rmCreateModifyDestroyFoldersCapability"/>
|
||||
</bean>
|
||||
|
||||
<bean id="rmReOpenFoldersCapability"
|
||||
parent="rmFolderControlGroup">
|
||||
<property name="name" value="ReOpenFolders"/>
|
||||
<property name="permission" value="ReOpenFolders"/>
|
||||
<property name="kinds">
|
||||
<list>
|
||||
<value>RECORD_FOLDER</value>
|
||||
</list>
|
||||
</property>
|
||||
<property name="conditions">
|
||||
<map>
|
||||
<entry key="capabilityCondition.filling" value="true"/>
|
||||
<entry key="capabilityCondition.cutoff" value="false"/>
|
||||
<entry key="capabilityCondition.frozenOrFrozenChildren" value="false"/>
|
||||
<entry key="capabilityCondition.closed" value="true"/>
|
||||
</map>
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="rmDeclareRecordsInClosedFoldersCapability"
|
||||
parent="rmFolderControlGroup">
|
||||
<property name="name" value="DeclareRecordsInClosedFolders"/>
|
||||
<property name="permission" value="DeclareRecordsInClosedFolders"/>
|
||||
<property name="kinds">
|
||||
<list>
|
||||
<value>RECORD</value>
|
||||
</list>
|
||||
</property>
|
||||
<property name="conditions">
|
||||
<map>
|
||||
<entry key="capabilityCondition.filling" value="true"/>
|
||||
<entry key="capabilityCondition.cutoff" value="false"/>
|
||||
<entry key="capabilityCondition.frozen" value="false"/>
|
||||
<entry key="capabilityCondition.closed" value="true"/>
|
||||
<entry key="capabilityCondition.declared" value="false"/>
|
||||
</map>
|
||||
</property>
|
||||
</bean>
|
||||
</beans>
|
@@ -0,0 +1,96 @@
|
||||
# Records
|
||||
capability.group.records.title=Records
|
||||
capability.DeclareRecords.title=Declare Records
|
||||
capability.ViewRecords.title=View Records
|
||||
capability.UndeclareRecords.title=Undeclare Records
|
||||
|
||||
# Metadata Control
|
||||
capability.group.metadataControl.title=Metadata Control
|
||||
capability.EditRecordMetadata.title=Edit Record Metadata
|
||||
capability.EditDeclaredRecordMetadata.title=Edit Declared Record Metadata
|
||||
capability.EditNonRecordMetadata.title=Edit Non Record Metadata
|
||||
capability.MoveRecords.title=Move Records
|
||||
|
||||
# Folder Control
|
||||
capability.group.folderControl.title=Folder Control
|
||||
capability.CreateModifyDestroyFolders.title=Create Modify Destroy Folders
|
||||
capability.CloseFolders.title=Close Folders
|
||||
capability.ReOpenFolders.title=Re-Open Folders
|
||||
capability.DeclareRecordsInClosedFolders.title=Declare Records In Closed Folders
|
||||
|
||||
# Vital Records
|
||||
capability.group.vitalRecords.title=Vital Records
|
||||
capability.UpdateVitalRecordCycleInformation.title=Update Vital Record Cycle Information
|
||||
capability.CycleVitalRecords.title=Cycle Vital Records
|
||||
capability.PlanningReviewCycles.title=Planning Review Cycles
|
||||
|
||||
# References and Links
|
||||
capability.group.referencesAndLinks.title=References and Links
|
||||
capability.ChangeOrDeleteReferences.title=Change Or Delete References
|
||||
capability.DeleteLinks.title=Delete Links
|
||||
|
||||
# Events
|
||||
capability.group.events.title=Events
|
||||
capability.CreateModifyDestroyEvents.title=Create Modify Destroy Events
|
||||
capability.AddModifyEventDates.title=Add Modify Event Dates
|
||||
|
||||
# Cutoff
|
||||
capability.group.cutoff.title=Cutoff
|
||||
capability.ApproveRecordsScheduledForCutoff.title=Approve Records Scheduled For Cutoff
|
||||
capability.CreateModifyRecordsInCutoffFolders.title=Create Modify Records In Cutoff Folders
|
||||
|
||||
# Disposition and Transfers
|
||||
capability.group.dispositionAndTransfers.title=Disposition and Transfers
|
||||
capability.UpdateTriggerDates.title=Update Trigger Dates
|
||||
capability.ManuallyChangeDispositionDates.title=Manually Change Disposition Dates
|
||||
capability.AuthorizeNominatedTransfers.title=Authorize Nominated Transfers
|
||||
capability.AuthorizeAllTransfers.title=Authorize All Transfers
|
||||
capability.DestroyRecordsScheduledForDestruction.title=Destroy Records Scheduled For Destruction
|
||||
capability.DestroyRecords.title=Destroy Records
|
||||
capability.DeleteRecords.title=Delete Records
|
||||
capability.TriggerAnEvent.title=Trigger An Event
|
||||
|
||||
# Hold Controls
|
||||
capability.group.holdControls.title=Hold Controls
|
||||
capability.ExtendRetentionPeriodOrFreeze.title=Extend Retention Period Or Freeze
|
||||
capability.Unfreeze.title=Unfreeze
|
||||
capability.ViewUpdateReasonsForFreeze.title=View Update Reasons For Freeze
|
||||
|
||||
# Audit
|
||||
capability.group.audit.title=Audit
|
||||
capability.DeclareAuditAsRecord.title=Declare Audit As Record
|
||||
capability.EnableDisableAuditByTypes.title=Enable Disable Audit By Types
|
||||
capability.DeleteAudit.title=Delete Audit
|
||||
capability.SelectAuditMetadata.title=Select Audit Metadata
|
||||
capability.AccessAudit.title=Access Audit
|
||||
capability.ExportAudit.title=Export Audit
|
||||
|
||||
# Roles and Access Rights
|
||||
capability.group.rolesAndAccessRights.title=Roles and Access Rights
|
||||
capability.CreateModifyDestroyRoles.title=Create Modify Destroy Roles
|
||||
capability.CreateModifyDestroyUsersAndGroups.title=Create Modify Destroy Users And Groups
|
||||
capability.PasswordControl.title=Password Control
|
||||
capability.DisplayRightsReport.title=Display Rights Report
|
||||
capability.ManageAccessControls.title=Manage Access Controls
|
||||
capability.ManageAccessRights.title=Manage Access Rights
|
||||
|
||||
# File Plan Metadata, Lists and Email
|
||||
capability.group.filePlanMetadataListsAndEmail.title=File Plan Metadata, Lists and Email
|
||||
capability.CreateModifyDestroyFileplanMetadata.title=Create Modify Destroy File Plan Metadata
|
||||
capability.CreateModifyDestroyFileplanTypes.title=Create Modify Destroy File Plan Types
|
||||
capability.CreateModifyDestroyRecordTypes.title=Create Modify Destroy Record Types
|
||||
capability.CreateAndAssociateSelectionLists.title=Create And Associate Selection Lists
|
||||
capability.EditSelectionLists.title=Edit Selection Lists
|
||||
capability.CreateModifyDestroyReferenceTypes.title=Create Modify Destroy Reference Types
|
||||
capability.AttachRulesToMetadataProperties.title=Attach Rules To Metadata Properties
|
||||
capability.MakeOptionalParametersMandatory.title=Make Optional Parameters Mandatory
|
||||
capability.MapEmailMetadata.title=Map Email Metadata
|
||||
|
||||
# Classified Records
|
||||
capability.group.classifiedRecords.title=Classified Records
|
||||
capability.UpdateClassificationDates.title=Update Classification Dates
|
||||
capability.CreateModifyDestroyClassificationGuides.title=Create Modify Destroy Classification Guides
|
||||
capability.UpgradeDowngradeAndDeclassifyRecords.title=Upgrade Downgrade And Declassify Records
|
||||
capability.UpdateExemptionCategories.title=Update Exemption Categories
|
||||
capability.MapClassificationGuideMetadata.title=Map Classification Guide Metadata
|
||||
capability.CreateModifyDestroyTimeframes.title=Create Modify Destroy Time frames
|
@@ -80,6 +80,7 @@
|
||||
<value>alfresco.module.org_alfresco_module_rm.messages.records-management-service</value>
|
||||
<value>alfresco.module.org_alfresco_module_rm.messages.action-service</value>
|
||||
<value>alfresco.module.org_alfresco_module_rm.messages.audit-service</value>
|
||||
<value>alfresco.module.org_alfresco_module_rm.messages.capability-service</value>
|
||||
</list>
|
||||
</property>
|
||||
</bean>
|
||||
|
@@ -28,8 +28,80 @@
|
||||
parent="rmBaseCapability"
|
||||
class="org.alfresco.module.org_alfresco_module_rm.capability.declarative.CompositeCapability" />
|
||||
|
||||
<bean id="rmAddModifyEventDatesCapability"
|
||||
<!--
|
||||
<bean id="rmRecordsGroup"
|
||||
abstract="true"
|
||||
parent="FIXME???">
|
||||
<property name="groupId" value="records" />
|
||||
</bean>
|
||||
<bean id="rmMetadataControlGroup"
|
||||
abstract="true"
|
||||
parent="FIXME???">
|
||||
<property name="groupId" value="metadataControl" />
|
||||
</bean>
|
||||
-->
|
||||
<bean id="rmFolderControlGroup"
|
||||
abstract="true"
|
||||
parent="declarativeCapability">
|
||||
<property name="groupId" value="folderControl" />
|
||||
</bean>
|
||||
<bean id="rmVitalRecordsGroup"
|
||||
abstract="true"
|
||||
parent="declarativeCapability">
|
||||
<property name="groupId" value="vitalRecords" />
|
||||
</bean>
|
||||
<bean id="rmReferencesAndLinksGroup"
|
||||
abstract="true"
|
||||
parent="rmBaseCapability">
|
||||
<property name="groupId" value="referencesAndLinks" />
|
||||
</bean>
|
||||
<bean id="rmEventsGroup"
|
||||
abstract="true"
|
||||
parent="declarativeCapability">
|
||||
<property name="groupId" value="events" />
|
||||
</bean>
|
||||
<bean id="rmCutoffGroup"
|
||||
abstract="true"
|
||||
parent="declarativeCapability">
|
||||
<property name="groupId" value="cutoff" />
|
||||
</bean>
|
||||
<!--
|
||||
<bean id="rmDispositionAndTransfersGroup"
|
||||
abstract="true"
|
||||
parent="FIXME???">
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
-->
|
||||
<bean id="rmHoldControlsGroup"
|
||||
abstract="true"
|
||||
parent="declarativeCapability">
|
||||
<property name="groupId" value="holdControls" />
|
||||
</bean>
|
||||
<bean id="rmAuditGroup"
|
||||
abstract="true"
|
||||
parent="declarativeCapability">
|
||||
<property name="groupId" value="audit" />
|
||||
</bean>
|
||||
<bean id="rmRolesAndAccessRightsGroup"
|
||||
abstract="true"
|
||||
parent="declarativeCapability">
|
||||
<property name="groupId" value="rolesAndAccessRights" />
|
||||
</bean>
|
||||
<!--
|
||||
<bean id="rmFilePlanMetadataListsAndEmailGroup"
|
||||
abstract="true"
|
||||
parent="FIXME???">
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
-->
|
||||
<bean id="rmClassifiedRecordsGroup"
|
||||
abstract="true"
|
||||
parent="declarativeCapability">
|
||||
<property name="groupId" value="classifiedRecords" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmAddModifyEventDatesCapability"
|
||||
parent="rmEventsGroup">
|
||||
<property name="name" value="AddModifyEventDates"/>
|
||||
<property name="permission" value="AddModifyEventDates"/>
|
||||
<property name="kinds">
|
||||
@@ -51,10 +123,11 @@
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="AttachRulesToMetadataProperties"/>
|
||||
<property name="permission" value="AttachRulesToMetadataProperties"/>
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmChangeOrDeleteReferencesCapability"
|
||||
parent="rmBaseCapability"
|
||||
parent="rmReferencesAndLinksGroup"
|
||||
class="org.alfresco.module.org_alfresco_module_rm.capability.impl.ChangeOrDeleteReferencesCapability">
|
||||
<property name="name" value="ChangeOrDeleteReferences"/>
|
||||
<property name="permission" value="ChangeOrDeleteReferences"/>
|
||||
@@ -67,56 +140,58 @@
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyDestroyClassificationGuidesCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmClassifiedRecordsGroup">
|
||||
<property name="name" value="CreateModifyDestroyClassificationGuides"/>
|
||||
<property name="permission" value="CreateModifyDestroyClassificationGuides"/>
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyDestroyEventsCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmEventsGroup">
|
||||
<property name="name" value="CreateModifyDestroyEvents" />
|
||||
<property name="permission" value="CreateModifyDestroyEvents" />
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="rmCreateModifyDestroyFileplanTypesCapability"
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="CreateModifyDestroyFileplanTypes" />
|
||||
<property name="permission" value="CreateModifyDestroyFileplanTypes" />
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyDestroyRecordTypesCapability"
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="CreateModifyDestroyRecordTypes" />
|
||||
<property name="permission" value="CreateModifyDestroyRecordTypes" />
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyDestroyReferenceTypesCapability"
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="CreateModifyDestroyReferenceTypes" />
|
||||
<property name="permission" value="CreateModifyDestroyReferenceTypes" />
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyDestroyRolesCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmRolesAndAccessRightsGroup">
|
||||
<property name="name" value="CreateModifyDestroyRoles" />
|
||||
<property name="permission" value="CreateModifyDestroyRoles" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyDestroyTimeframesCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmClassifiedRecordsGroup">
|
||||
<property name="name" value="CreateModifyDestroyTimeframes" />
|
||||
<property name="permission" value="CreateModifyDestroyTimeframes" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmCreateModifyDestroyUsersAndGroupsCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmRolesAndAccessRightsGroup">
|
||||
<property name="name" value="CreateModifyDestroyUsersAndGroups" />
|
||||
<property name="permission" value="CreateModifyDestroyUsersAndGroups" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmCycleVitalRecordsCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmVitalRecordsGroup">
|
||||
<property name="name" value="CycleVitalRecords"/>
|
||||
<property name="permission" value="CycleVitalRecords"/>
|
||||
<property name="kinds">
|
||||
@@ -138,7 +213,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="rmDeleteLinksCapability"
|
||||
parent="rmBaseCapability"
|
||||
parent="rmReferencesAndLinksGroup"
|
||||
class="org.alfresco.module.org_alfresco_module_rm.capability.impl.DeleteLinksCapability">
|
||||
<property name="name" value="DeleteLinks"/>
|
||||
<property name="permission" value="DeleteLinks"/>
|
||||
@@ -152,7 +227,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="rmDisplayRightsReportCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmRolesAndAccessRightsGroup">
|
||||
<property name="name" value="DisplayRightsReport" />
|
||||
<property name="permission" value="DisplayRightsReport" />
|
||||
</bean>
|
||||
@@ -161,16 +236,17 @@
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="MakeOptionalParametersMandatory" />
|
||||
<property name="permission" value="MakeOptionalParametersMandatory" />
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmManageAccessControlsCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmRolesAndAccessRightsGroup">
|
||||
<property name="name" value="ManageAccessControls" />
|
||||
<property name="permission" value="ManageAccessControls" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmManageAccessRightsCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmRolesAndAccessRightsGroup">
|
||||
<property name="name" value="ManageAccessRights"/>
|
||||
<property name="permission" value="ManageAccessRights"/>
|
||||
<property name="conditions">
|
||||
@@ -182,7 +258,7 @@
|
||||
</bean>
|
||||
|
||||
<bean id="rmMapClassificationGuideMetadataCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmClassifiedRecordsGroup">
|
||||
<property name="name" value="MapClassificationGuideMetadata" />
|
||||
<property name="permission" value="MapClassificationGuideMetadata" />
|
||||
</bean>
|
||||
@@ -191,16 +267,17 @@
|
||||
parent="declarativeCapability">
|
||||
<property name="name" value="MapEmailMetadata" />
|
||||
<property name="permission" value="MapEmailMetadata" />
|
||||
<property name="groupId" value="filePlanMetadataListsAndEmail" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmPasswordControlCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmRolesAndAccessRightsGroup">
|
||||
<property name="name" value="PasswordControl" />
|
||||
<property name="permission" value="PasswordControl" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmPlanningReviewCyclesCapability"
|
||||
parent="declarativeCapability" >
|
||||
parent="rmVitalRecordsGroup" >
|
||||
<property name="name" value="PlanningReviewCycles"/>
|
||||
<property name="permission" value="PlanningReviewCycles"/>
|
||||
<property name="conditions">
|
||||
@@ -230,16 +307,17 @@
|
||||
<entry key="capabilityCondition.hasEvents" value="true"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmUpdateClassificationDatesCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmClassifiedRecordsGroup">
|
||||
<property name="name" value="UpdateClassificationDates" />
|
||||
<property name="permission" value="UpdateClassificationDates" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmUpdateExemptionCategoriesCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmClassifiedRecordsGroup">
|
||||
<property name="name" value="UpdateExemptionCategories" />
|
||||
<property name="permission" value="UpdateExemptionCategories" />
|
||||
</bean>
|
||||
@@ -253,10 +331,11 @@
|
||||
<entry key="capabilityCondition.frozen" value="false"/>
|
||||
</map>
|
||||
</property>
|
||||
<property name="groupId" value="dispositionAndTransfers" />
|
||||
</bean>
|
||||
|
||||
<bean id="rmUpdateVitalRecordCycleInformationCapability"
|
||||
parent="declarativeCapability">
|
||||
parent="rmVitalRecordsGroup">
|
||||
<property name="name" value="UpdateVitalRecordCycleInformation"/>
|
||||
<property name="permission" value="UpdateVitalRecordCycleInformation"/>
|
||||
<property name="conditions">
|
||||
|
@@ -2,7 +2,7 @@
|
||||
<shortname>Records Management Capabilities</shortname>
|
||||
<description>Get the list of capabilities available to the current user on the given node.</description>
|
||||
<url>/api/node/{store_type}/{store_id}/{id}/capabilities?includeAll={includeAll?}</url>
|
||||
<url>/api/capabilities?includeAll={includeAll?}</url>
|
||||
<url>/api/capabilities?includeAll={includeAll?}&grouped={grouped?}</url>
|
||||
<format default="json">argument</format>
|
||||
<authentication>user</authentication>
|
||||
<transaction allow="readonly">required</transaction>
|
||||
|
@@ -1,11 +1,31 @@
|
||||
{
|
||||
"data" :
|
||||
"data":
|
||||
{
|
||||
"capabilities" :
|
||||
<#if groupedCapabilities??>
|
||||
"groupedCapabilities":
|
||||
[
|
||||
<#assign keys = groupedCapabilities?keys>
|
||||
<#list keys as key>
|
||||
{
|
||||
"${key}":
|
||||
<#assign capabilitiesMap = groupedCapabilities[key]>
|
||||
<#assign capabilitiesKeys = capabilitiesMap?keys>
|
||||
{
|
||||
<#list capabilitiesKeys as capabilitiesKey>
|
||||
"${capabilitiesKey}": "${capabilitiesMap[capabilitiesKey]}"
|
||||
<#if capabilitiesKey_has_next>,</#if>
|
||||
</#list>
|
||||
}
|
||||
}<#if key_has_next>,</#if>
|
||||
</#list>
|
||||
]
|
||||
<#else>
|
||||
"capabilities":
|
||||
[
|
||||
<#list capabilities as capability>
|
||||
"${capability}"<#if capability_has_next>,</#if>
|
||||
</#list>
|
||||
]
|
||||
</#if>
|
||||
}
|
||||
}
|
@@ -27,6 +27,7 @@ import org.alfresco.module.org_alfresco_module_rm.action.RecordsManagementAction
|
||||
import org.alfresco.module.org_alfresco_module_rm.model.RecordsManagementModel;
|
||||
import org.alfresco.service.cmr.repository.NodeRef;
|
||||
import org.alfresco.service.cmr.security.AccessStatus;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.apache.commons.logging.Log;
|
||||
import org.apache.commons.logging.LogFactory;
|
||||
import org.springframework.extensions.surf.util.I18NUtil;
|
||||
@@ -57,6 +58,10 @@ public abstract class AbstractCapability extends RMSecurityCommon
|
||||
protected String title;
|
||||
protected String description;
|
||||
|
||||
/** Capability group id and title*/
|
||||
protected String groupId;
|
||||
protected String groupTitle;
|
||||
|
||||
/** Indicates whether this is a private capability or not */
|
||||
protected boolean isPrivate = false;
|
||||
|
||||
@@ -128,20 +133,17 @@ public abstract class AbstractCapability extends RMSecurityCommon
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param titleId message id
|
||||
*/
|
||||
public void setTitleId(String titleId)
|
||||
{
|
||||
this.title = I18NUtil.getMessage(titleId);
|
||||
}
|
||||
|
||||
/**
|
||||
* @see org.alfresco.module.org_alfresco_module_rm.capability.Capability#getTitle()
|
||||
*/
|
||||
@Override
|
||||
public String getTitle()
|
||||
{
|
||||
String title = this.title;
|
||||
if (StringUtils.isBlank(title))
|
||||
{
|
||||
title = I18NUtil.getMessage("capability." + getName() + ".title");
|
||||
}
|
||||
return title;
|
||||
}
|
||||
|
||||
@@ -314,6 +316,37 @@ public abstract class AbstractCapability extends RMSecurityCommon
|
||||
return actions;
|
||||
}
|
||||
|
||||
/**
|
||||
* @see org.alfresco.module.org_alfresco_module_rm.capability.Capability#getGroupId()
|
||||
*/
|
||||
public String getGroupId()
|
||||
{
|
||||
return this.groupId;
|
||||
}
|
||||
|
||||
public void setGroupId(String groupId)
|
||||
{
|
||||
this.groupId = groupId;
|
||||
}
|
||||
|
||||
/**
|
||||
* @see org.alfresco.module.org_alfresco_module_rm.capability.Capability#getGroupTitle()
|
||||
*/
|
||||
public String getGroupTitle()
|
||||
{
|
||||
String groupTitle = this.groupTitle;
|
||||
if (StringUtils.isBlank(groupTitle))
|
||||
{
|
||||
groupTitle = I18NUtil.getMessage("capability.group." + getGroupId() + ".title");
|
||||
}
|
||||
return groupTitle;
|
||||
}
|
||||
|
||||
public void setGroupTitle(String groupTitle)
|
||||
{
|
||||
this.groupTitle = groupTitle;
|
||||
}
|
||||
|
||||
/**
|
||||
* @see java.lang.Object#hashCode()
|
||||
*/
|
||||
|
@@ -103,4 +103,18 @@ public interface Capability
|
||||
* @return
|
||||
*/
|
||||
List<RecordsManagementAction> getActions();
|
||||
|
||||
/**
|
||||
* Gets the group id of a capability
|
||||
*
|
||||
* @return String capability group id
|
||||
*/
|
||||
String getGroupId();
|
||||
|
||||
/**
|
||||
* Gets the group title of a capability
|
||||
*
|
||||
* @return String capability group title
|
||||
*/
|
||||
String getGroupTitle();
|
||||
}
|
||||
|
@@ -95,4 +95,12 @@ public interface CapabilityService
|
||||
* @return
|
||||
*/
|
||||
AccessStatus getCapabilityAccessState(NodeRef nodeRef, String capabilityName);
|
||||
|
||||
/**
|
||||
* Gets all the capabilities grouped by their ids. The map key is the group id of a capability and the
|
||||
* value is another map with the key being the capability name and the value being the capability title
|
||||
*
|
||||
* @return Map of capabilities grouped by their ids
|
||||
*/
|
||||
Map<String, Map<String, String>> getGroupedCapabilities();
|
||||
}
|
||||
|
@@ -27,6 +27,8 @@ import java.util.Set;
|
||||
|
||||
import org.alfresco.service.cmr.repository.NodeRef;
|
||||
import org.alfresco.service.cmr.security.AccessStatus;
|
||||
import org.alfresco.util.ParameterCheck;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
|
||||
/**
|
||||
* @author Roy Wetherall
|
||||
@@ -43,6 +45,8 @@ public class CapabilityServiceImpl implements CapabilityService
|
||||
@Override
|
||||
public Capability getCapability(String name)
|
||||
{
|
||||
ParameterCheck.mandatoryString("name", name);
|
||||
|
||||
return capabilities.get(name);
|
||||
}
|
||||
|
||||
@@ -52,6 +56,8 @@ public class CapabilityServiceImpl implements CapabilityService
|
||||
@Override
|
||||
public void registerCapability(Capability capability)
|
||||
{
|
||||
ParameterCheck.mandatory("capability", capability);
|
||||
|
||||
capabilities.put(capability.getName(), capability);
|
||||
}
|
||||
|
||||
@@ -95,6 +101,8 @@ public class CapabilityServiceImpl implements CapabilityService
|
||||
*/
|
||||
public Map<Capability, AccessStatus> getCapabilitiesAccessState(NodeRef nodeRef)
|
||||
{
|
||||
ParameterCheck.mandatory("nodeRef", nodeRef);
|
||||
|
||||
return getCapabilitiesAccessState(nodeRef, false);
|
||||
}
|
||||
|
||||
@@ -104,6 +112,8 @@ public class CapabilityServiceImpl implements CapabilityService
|
||||
@Override
|
||||
public Map<Capability, AccessStatus> getCapabilitiesAccessState(NodeRef nodeRef, boolean includePrivate)
|
||||
{
|
||||
ParameterCheck.mandatory("nodeRef", nodeRef);
|
||||
|
||||
Set<Capability> listOfCapabilites = getCapabilities(includePrivate);
|
||||
HashMap<Capability, AccessStatus> answer = new HashMap<Capability, AccessStatus>();
|
||||
for (Capability capability : listOfCapabilites)
|
||||
@@ -122,6 +132,9 @@ public class CapabilityServiceImpl implements CapabilityService
|
||||
*/
|
||||
public Map<Capability, AccessStatus> getCapabilitiesAccessState(NodeRef nodeRef, List<String> capabilityNames)
|
||||
{
|
||||
ParameterCheck.mandatory("nodeRef", nodeRef);
|
||||
ParameterCheck.mandatory("capabilityNames", capabilityNames);
|
||||
|
||||
HashMap<Capability, AccessStatus> answer = new HashMap<Capability, AccessStatus>();
|
||||
for (String capabilityName : capabilityNames)
|
||||
{
|
||||
@@ -144,6 +157,9 @@ public class CapabilityServiceImpl implements CapabilityService
|
||||
@Override
|
||||
public AccessStatus getCapabilityAccessState(NodeRef nodeRef, String capabilityName)
|
||||
{
|
||||
ParameterCheck.mandatory("nodeRef", nodeRef);
|
||||
ParameterCheck.mandatory("capabilityName", capabilityName);
|
||||
|
||||
AccessStatus result = AccessStatus.UNDETERMINED;
|
||||
Capability capability = getCapability(capabilityName);
|
||||
if (capability != null)
|
||||
@@ -155,4 +171,34 @@ public class CapabilityServiceImpl implements CapabilityService
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* @see org.alfresco.module.org_alfresco_module_rm.capability.CapabilityService#getGroupedCapabilities()
|
||||
*/
|
||||
@Override
|
||||
public Map<String, Map<String, String>> getGroupedCapabilities()
|
||||
{
|
||||
Map<String, Map<String, String>> groupedCapabilities = new HashMap<String, Map<String, String>>(capabilities.size());
|
||||
for (Capability capability : getCapabilities(true))
|
||||
{
|
||||
String groupTitle = capability.getGroupTitle();
|
||||
if (StringUtils.isNotBlank(groupTitle))
|
||||
{
|
||||
String capabilityName = capability.getName();
|
||||
String capabilityTitle = capability.getTitle();
|
||||
|
||||
if (groupedCapabilities.containsKey(groupTitle))
|
||||
{
|
||||
groupedCapabilities.get(groupTitle).put(capabilityName, capabilityTitle);
|
||||
}
|
||||
else
|
||||
{
|
||||
Map<String, String> capabilityList = new HashMap<String, String>(13);
|
||||
capabilityList.put(capabilityName, capabilityTitle);
|
||||
groupedCapabilities.put(groupTitle, capabilityList);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return groupedCapabilities;
|
||||
}
|
||||
}
|
||||
|
@@ -31,6 +31,7 @@ import org.alfresco.module.org_alfresco_module_rm.capability.CapabilityService;
|
||||
import org.alfresco.service.cmr.repository.NodeRef;
|
||||
import org.alfresco.service.cmr.repository.StoreRef;
|
||||
import org.alfresco.service.cmr.security.AccessStatus;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.springframework.extensions.webscripts.Cache;
|
||||
import org.springframework.extensions.webscripts.DeclarativeWebScript;
|
||||
import org.springframework.extensions.webscripts.Status;
|
||||
@@ -64,15 +65,8 @@ public class CapabilitiesGet extends DeclarativeWebScript
|
||||
String storeId = templateVars.get("store_id");
|
||||
String nodeId = templateVars.get("id");
|
||||
|
||||
boolean includePrivate = false;
|
||||
String includePrivateString = req.getParameter("includeAll");
|
||||
if (includePrivateString != null)
|
||||
{
|
||||
includePrivate = Boolean.parseBoolean(includePrivateString);
|
||||
}
|
||||
|
||||
NodeRef nodeRef = null;
|
||||
if (storeType != null && storeId != null && nodeId != null)
|
||||
if (StringUtils.isNotBlank(storeType) && StringUtils.isNotBlank(storeId) && StringUtils.isNotBlank(nodeId))
|
||||
{
|
||||
nodeRef = new NodeRef(new StoreRef(storeType, storeId), nodeId);
|
||||
}
|
||||
@@ -92,6 +86,27 @@ public class CapabilitiesGet extends DeclarativeWebScript
|
||||
nodeRef = filePlans.get(0);
|
||||
}
|
||||
|
||||
boolean grouped = false;
|
||||
String groupedString = req.getParameter("grouped");
|
||||
if (StringUtils.isNotBlank(groupedString))
|
||||
{
|
||||
grouped = Boolean.parseBoolean(groupedString);
|
||||
}
|
||||
|
||||
Map<String, Object> model = new HashMap<String, Object>(1);
|
||||
if (grouped == true)
|
||||
{
|
||||
model.put("groupedCapabilities", capabilityService.getGroupedCapabilities());
|
||||
}
|
||||
else
|
||||
{
|
||||
boolean includePrivate = false;
|
||||
String includePrivateString = req.getParameter("includeAll");
|
||||
if (StringUtils.isNotBlank(includePrivateString))
|
||||
{
|
||||
includePrivate = Boolean.parseBoolean(includePrivateString);
|
||||
}
|
||||
|
||||
Map<Capability, AccessStatus> map = capabilityService.getCapabilitiesAccessState(nodeRef, includePrivate);
|
||||
List<String> list = new ArrayList<String>(map.size());
|
||||
for (Map.Entry<Capability, AccessStatus> entry : map.entrySet())
|
||||
@@ -103,9 +118,9 @@ public class CapabilitiesGet extends DeclarativeWebScript
|
||||
list.add(capability.getName());
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, Object> model = new HashMap<String, Object>(1);
|
||||
model.put("capabilities", list);
|
||||
}
|
||||
|
||||
return model;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user