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

Attribute cannot be deleted from a block

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Medium Medium
    • None
    • 2.5.15
    • Page Builder
    • None

    Description

      Previous Info

      There was already a ticket with a similar error:
      https://issues.ibexa.co/browse/EZEE-3000
      The solution was: install version 2.5.9 and remove the fields from block.
      We did it, but now there is another error:
      Pages cannot be published.

      Description

      An attribute of a block (here called testField) is never used anymore.
      Therefore we removed this attribute (testField) from a module in blocks.yml and from the .twig-file.
      The result is:

      • all pages including such a module cannot be published anymore.

      Reproduce Error

      • 1.) Use an already existing block "test_module"
        --> find an instance with filled testField
      • 2.) blocks.yml: Remove testfield
      • 3.) Try to publish page
        --> page cannot be published
        --> Error-Message:
        Notice: Undefined index: testField

      Source-example

      .yml origin

      ezplatform_page_fieldtype:
          blocks:
              test_module:
                  name: 'Test-Module'
                  thumbnail: '/bundles/ezplatformadminui/img/ez-icons.svg#paragraph'
                  category: 'snh'
                  views:
                      default:
                          template: '/themes/snh_website/blocks/testModule/testModule.html.twig'
                          name: 'Default view'
                  attributes:
                      testfield:
                          type: 'string'
                          name: 'Test field'
      

      testModule.twig

      <section class="text-module">
          <div class="container">
              <div class="row">
                  {{ testfield }}
              </div>
          </div>
      </section>
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            153dcf0c-f946-4cdf-8633-924f1d36e1e6@accounts.ibexa.co Jens Stapelfeldt
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: