I am trying to copy pages on the sites page using the copy option on the action bar - But whenever i try to copy the page it creates a new page if the page is existing - I am trying to come up with an ability to overwrite the file if it is existing and create a new one if the file is missing more.
Solved! Go to Solution.
Views
Replies
Total Likes
Please check below community article for your usecase.
HI @AEMnewbie
AEM does not check for content while copying/moving the page. It just considers the name i.e. node name/page name.
Existing functionality itself checks if the node you are trying to copy already exists it will add 1,2,3, so on with the existing node name and add the copy.
If the page does not exist then it will copy the page as is. This is the OOTB functionality.
Thanks!
@Asutosh_Jena_ Yes ! I get that i am trying to override that OOTB functionality such that it overrides the existing node ( Like update the existing node or delete and create a new one ) - When the copy already exists
/wcm/core/content/sites/jcr:content/actions/selection/copypage - I was referring to this path and see if any property addition here would prevent it from creating new nodes with number 1,2,3 - Then i tried looking at /libs/granite/ui/components/coral/foundation/collection/action - I noticed some actions in there like ignoreRel (Boolean) - tried adding this property in here /wcm/core/content/sites/jcr:content/actions/selection/copypage to see if that would make any difference it didnt -- I do see action and actionConfigName property in there but i wasnt sure where exactly i could find and code/reference related to those ..
or If you could point me to the location where i could find that OOTB code that could be helpful too
Views
Replies
Total Likes
Please check below community article for your usecase.
Views
Replies
Total Likes
Glad to hear that. Thanks !
Views
Replies
Total Likes
Views
Replies
Total Likes
Views
Like
Replies