When a versioned folder is merged into a target versioned folder, currently an overall commit message is recorded on the target VF to represent the change history.
This should be extended to add a history record to each individual item that was changed in the target VF too. This will highlight at a more granular level how the merge affected the VF.
Merge operation
The VersionedFolderService.mergeObjectPatchDataIntoVersionedFolder() method has three top level operations to take care of for every patched item/field change:
Created items in the target
Deleted items from the target
Modified items in the target
For each one, a new history record should be added as each catalogue item is changed/created using the EditHistoryAware trait. The EditTitle.MERGE enum should be used along with a suitable description referencing the source versioned folder that caused the change, e.g.
"Item created in branch 'my-test-branch'"
"Item modified in branch 'my-test-branch'"
etc
Created and updated items
As items are created (copied) or modified in the target versioned folder, the history should be added directly to that new/updated item in question.
Deleted items
Where items have been deleted from the target versioned folder, the history item should be added to the parent item that used to own the child deleted item.
Description
When a versioned folder is merged into a target versioned folder, currently an overall commit message is recorded on the target VF to represent the change history.
This should be extended to add a history record to each individual item that was changed in the target VF too. This will highlight at a more granular level how the merge affected the VF.
Merge operation
The
VersionedFolderService.mergeObjectPatchDataIntoVersionedFolder()
method has three top level operations to take care of for every patched item/field change:For each one, a new history record should be added as each catalogue item is changed/created using the
EditHistoryAware
trait. TheEditTitle.MERGE
enum should be used along with a suitable description referencing the source versioned folder that caused the change, e.g.Created and updated items
As items are created (copied) or modified in the target versioned folder, the history should be added directly to that new/updated item in question.
Deleted items
Where items have been deleted from the target versioned folder, the history item should be added to the parent item that used to own the child deleted item.