Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
If use Inline Entity Form - Complex allow create new entity which with image field,the second new entity's image field will keep the first new entity's image field value,remove image value in second and the first will be remove too.
Comment | File | Size | Author |
---|---|---|---|
#7 | inline_entity_form-file_field_keep_pre_value-2886023-7.patch | 5.55 KB | agolubic |
#5 | inline_entity_form-file_field_keep_pre_value-2886023-5.patch | 5.55 KB | lykyd |
#2 | file_field_keep_pre_value-2886023-2.patch | 3.13 KB | ipumpkin |
Comments
Comment #2
ipumpkin CreditAttribution: ipumpkin at DAVYIN Internet Solutions / 戴文信息科技有限公司 commentedComment #4
lykyd CreditAttribution: lykyd commentedApplying #2 patch fixed the issue but broke the "Cancel" and "Add an existing" buttons.
Comment #5
lykyd CreditAttribution: lykyd commentedHere is the solution I came up with. Based on @ipumpkin patch, just extending it to "Add existing" button and a little fix for the "Cancel".
Comment #6
lykyd CreditAttribution: lykyd commentedComment #7
agolubic CreditAttribution: agolubic at Websolutions Agency commented@lykyd Your patch (#5) is great, but You got typo on 15 and 21 line of Your patch (You put only one + instead of ++ :)). I added 'missing' + in Your patch. After typo fix it works great, fixes the issue and cancel button works.
Thank You for Your patches @lykyd and @ipumpkin!
Comment #8
ipumpkin CreditAttribution: ipumpkin at DAVYIN Internet Solutions / 戴文信息科技有限公司 commentedComment #10
lykyd CreditAttribution: lykyd commentedI have upgraded to Drupal 8.5.3 + IEF 8.x-1.0-rc1 and the patch does not seem to be useful anymore.
On the contrary, using it create an Ajax error when trying to create an entity.
Comment #11
mbovan CreditAttribution: mbovan at MD Systems GmbH for Unic commentedThis sounds like #2653574: Unable to keep nested IEF data separate with multivalue fields.. Could you please test, @ipumpkin?
Comment #12
RoloDMonkey CreditAttribution: RoloDMonkey at Third and Grove commentedI saw this same behavior, and can confirm that this is a duplicate of #2653574: Unable to keep nested IEF data separate with multivalue fields.. Applying the patch on comment 100 resolved the issue for me.