Uploaded image for project: 'eZ Platform Enterprise Edition'
  1. eZ Platform Enterprise Edition
  2. EZEE-2250

Overriding default layout for Page FieldType results in duplicated layout in choose layout dialog.

    XMLWordPrintable

Details

    Description

      Overriding default layout for Page FieldType results in duplicated default layout in layout choose dialog. Clicking one of the "default layouts" will result in selecting both of them.

      Steps to reproduce
      1. Create 2 template files in app/Resources/views/landinglayout: default.html.twig, second.html.twig - they can be empty.
      2. Put below configuration in ezplatform.yml:

      ezplatform_page_fieldtype:
          layouts:
              default:
                  identifier: 'default'
                  name: 'Default layout'
                  description: 'Default layout for Page'
                  thumbnail: '/bundles/ezplatformpagefieldtype/images/layouts/default.png'
                  template: '/landinglayout/default.html.twig'
                  zones:
                      default_id:
                          name: 'default'
      
              second:
                  identifier: 'second'
                  name: 'Second layout'
                  description: 'Second layout for Page'
                  thumbnail: '/bundles/ezplatformpagefieldtype/images/layouts/default.png'
                  template: '/landinglayout/second.html.twig'
                  zones:
                      top_id:
                          name: 'top'
                      bottom_id:
                          name: 'bottom'
      

      3. Go to Content > Content Structure, click on "Create" and choose "Landing page".

      Result
      The choose layout dialog will show containing 3 layouts to choose from: default layout, a layout that overrides default layout and "second layout". After choosing one of the "default" layouts, both get checked (refer to attached screencast).

      Attachments

        Activity

          People

            Unassigned Unassigned
            mateusz.bieniek@ibexa.co Mateusz Bieniek
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: