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

Protect Button saves wrong protection names if a locale is a default in a tree but not the master default

XMLWordPrintable

      Protect Button saves wrong protection names if a locale is a default in a tree but not the master default.

      Steps to reproduce

      1.  Create a master tree with en_US as default, de_CH as second and en_GB as third locale
      2.  Create a slave tree with en_US as masterDefaultLocale and en_GB as fallback for this tree.
      3. Go to the page protect button and protect the en_GB version of a property.

      Expected results

      Because en_GB is not the master default locale the en_GB should be saved as suffix

      Actual results

      It will create a <propertyName> in the protectedFields property without language suffix.

      Development notes

      The issue is in the Button:

      https://git.magnolia-cms.com/projects/ADDON/repos/live-copy/browse/src/main/java/info/magnolia/livecopy/app/ui/layout/field/ProtectFieldButton.java

      It uses an own implementation of isDefaultLocale at line 102. Instead you should use the isDefaultLocale method from https://git.magnolia-cms.com/projects/ADDON/repos/live-copy/browse/src/main/java/info/magnolia/livecopy/i18n/LiveCopyMultiSiteI18nAuthoringSupport.java 

        Acceptance criteria

              thien.quach Quach Hao Thien
              marvink2 Marvin Kerkhoff
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Bug DoR
                  Task DoD

                    Estimated:
                    Original Estimate - Not Specified
                    Not Specified
                    Remaining:
                    Remaining Estimate - Not Specified
                    Not Specified
                    Logged:
                    Time Spent - 6d 1.5h
                    6d 1.5h