Thanks for the useful module!

I realized that the inline entity forms are not getting saved while using 'save_edit' button. I will attach a tiny patch that fixed my problem. Looking for more optimal solution though..

Comments

Niyas created an issue. See original summary.

niyas’s picture

pguillard’s picture

Status: Needs review » Reviewed & tested by the community

This works for me, I suggest RTBC then..

pingevt’s picture

This seems to be working for me as well. Thanks @Niyas

However, this doesn't look like it should be a final solution for this problem since it creates a dependency on Inline entity forms module.

antiorario’s picture

Status: Reviewed & tested by the community » Needs work
arnaldop’s picture

Status: Needs work » Needs review
StatusFileSize
new632 bytes

Attached patch resolving the dependency on Inline Entity Forms.

q__nt_n’s picture

Assigned: Unassigned » q__nt_n

@arnaldop,
Your patch is wrong, you patched "bootstrap_site_alert" module ! :)

@Niyas Thanks for this patch, I'll review today or this week-end.

q__nt_n’s picture

I upload a new patch : I check if inline entity form is enable

arnaldop’s picture

@q__nt_n, I'm so sorry! I do not know what happened!

Quick question, though. According to this page, system_get_info requires a type and the module name is optional.
I haven't tested this patch, but to be consistent with the documentation, should we change the line to read as follows?

if (system_get_info('module', 'inline_entity_form'))

Thanks!

q__nt_n’s picture

@arnaldop
Yeah, sure ! I failed my patch :) I'll reupload in a few hours.
Thanks for your attention !

q__nt_n’s picture

I re-upload patch.

I really need your feedback on this. I dont know if it's a good pratice to fix dependance between 2 modules like that.
Thanks !

Cecilina’s picture

Issue tags: -
StatusFileSize
new1.49 KB

Add new patch to fix directly call inline_entity_form callback function, instead let this save_edit button to inherit all these callback existed for default submit button.

daveiano’s picture

Patch from #12is working as desired and is looking good to me!

slucero’s picture

Assigned: q__nt_n » Unassigned
Status: Needs review » Reviewed & tested by the community

Patch #12 looks good to me and fixed the issue perfectly in my use case.

amneh.shawish’s picture

Patch #2 is working fine with me.

mastap’s picture

Thanks for Patch #12

rviner’s picture

Patch #2 works for me but Patch #12 doesn't work as it doesn't unpublish the node when clicking on the save and edit button.

eahonet’s picture

Patch #12 let me finally save the inline_entity_form edits/adds.

I was able to swap between Draft and Published with #12 @rviner. But I think the workflow has had some tweaks and we're using other modules like content_lock with save_edit and inline_entity_form.

stefan.korn’s picture

It's true what rviner says, that the unpublish feature of save_edit is not working with patch #12. That is because the submit callbacks need to be provided in some order to work properly, especially the callback save_edit_form_submit_presave needs to be called before the ::save callback callback. Patch #12 attaches the two save_edit submit callbacks just at the end of the existing callbacks, thus to late for save_edit_form_submit_presave.

Providing a patch that should fix this. Maybe one could handle the two foreachs a bit more elegant, but should do it like this.

BTW: If you are using save_edit with Drupal 9 and want to use the unpublish feature you will need this patch first: https://www.drupal.org/project/save_edit/issues/3239440

bramdriesen’s picture

I confirm that #19 fixes the issue for me.

daletrexel’s picture

Thanks to everyone who has been working on this issue! I've also implemented patch in #19 and it's working for me.

One caveat: I'm not using the unpublish functionality, so I can't speak to that working or not.

  • caesius committed 6aa929b2 on 8.x-1.x authored by stefan.korn
    Issue #3026200 by q__nt_n, Niyas, arnaldop, stefan.korn, Cecilina:...
caesius’s picture

Status: Reviewed & tested by the community » Fixed

I happened to be experiencing this issue too and the patch fixed it.

Committed to dev.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.