Uploaded image for project: 'Ibexa IBX'
  1. Ibexa IBX
  2. IBX-661

ibexa:migrations:migrate script does not take into account metadata section for update mode

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Medium Medium
    • None
    • 3.3.12
    • None
    • None

    Description

      steps to reproduce

      1. install clean Ibexa DXP 3.3
      2. create migration file like above:
      -
          type: content
          mode: update
          match:
              field: content_remote_id
              value: 6ceafd2f11d7f69df64d6ce075e67b37
          metadata:
              initialLanguageCode: eng-GB
              creatorId: 14
              remoteId: 6ceafd2f11d7f69df64d6ce075e67b37
              alwaysAvailable: true
              mainLanguageCode: eng-GB
              mainLocationId: 59
              section: 3
              modificationDate: '2021-06-25T08:35:35+00:00'
              publishedDate: '2021-06-25T08:35:35+00:00'
              name: Article
              ownerId: 14
          fields:
              -
                  fieldDefIdentifier: title
                  languageCode: eng-GB
                  value: Article
              -
                  fieldDefIdentifier: short_title
                  languageCode: eng-GB
                  value: null
              -
                  fieldDefIdentifier: author
                  languageCode: eng-GB
                  value: {  }
              -
                  fieldDefIdentifier: intro
                  languageCode: eng-GB
                  value:
                      xml: |
                          <?xml version="1.0"?>
                          <section xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:ezxhtml="http://ez.no/xmlns/ezpublish/docbook/xhtml" xmlns:ezcustom="http://ez.no/xmlns/ezpublish/docbook/custom" version="5.0-variant ezpublish-1.0">
                                  <para>Data &amp; privacy regulations</para>
                          </section>
              -
                  fieldDefIdentifier: body
                  languageCode: eng-GB
                  value:
                      xml: |
                          <?xml version="1.0" encoding="UTF-8"?>
                          <section xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" version="5.0-variant ezpublish-1.0"/>
              -
                  fieldDefIdentifier: enable_comments
                  languageCode: eng-GB
                  value: false
              -
                  fieldDefIdentifier: image
                  languageCode: eng-GB
                  value:
                      destinationContentId: null
      
      
      1. Run php bin/console ibexa:migrations:migrate

       

      Result
      An article was updated without an update section

       

      Expected result

      An article should be updated with a section from metadata
       

      Designs

        Attachments

          Activity

            People

              Unassigned Unassigned
              mateusz.debinski@ibexa.co Mateusz Dębiński
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: