Uploaded image for project: 'Live Copy'
  1. Live Copy
  2. LIVECOPY-267

Relink action is not relinking properties at the node page level


      Steps to reproduce (Using travel demo)

      1.  Travel Home template is using a Page Properties dialog that includes a linkfield in the Search tab (Field Search result page)
      2.  Create a livecopy of travel and rename it to mytravel
      3. Use the relink action.

      Expected results

      All links in the page and in subnodes are relinked.

      Actual results

      All is relinked except properties at the page level included by Page Property dialog. If the livecopy home page is opened it can be seen that the value of the search result page is pointing to travel instead of mytravel).



      Development notes

      info.magnolia.livecopy.actions.rewire.RewirePageLinksHelper.rewritePageLinks(Node, boolean) is in charge of rewrite links in pages, it gets childnodes of the page and rewrite all its links, but ignores the links properties in the page itself.
      It might be useful to call this also at page level and not only from child nodes:

       for (Node slaveContentNode : slaveChildContentNodes) {
                      compatibilityRewirePageLinksHelper.rewriteLinksForNode(slaveContentNode, masterSiteDefinition, protectFieldAfterRewire);
                      standardRewirePageLinksHelper.rewriteLinksForNode(slaveContentNode, masterSiteDefinition, protectFieldAfterRewire);

        Acceptance criteria

              chuong.doan Chuong Doan Huy
              miruela Mercedes Iruela
              0 Vote for this issue
              3 Start watching this issue


                  Task DoD

                    Original Estimate - Not Specified
                    Not Specified
                    Remaining Estimate - Not Specified
                    Not Specified
                    Time Spent - 3d 4.5h
                    3d 4.5h