Events: Good idea to edit & save a custom field in afterSubmission event? #1575
-
Hi, I'm currently learning more about the My use case is the following:
My first idea:
But I don't know if this is a good idea to use Thanks very much in advance for any advice! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
This might be a better task for a custom integration with Formie. But if you want to keep the quick-and-dirty path, that's okay! That will be fine, no issue with that. You won't cause a recursion because |
Beta Was this translation helpful? Give feedback.
-
HI @engram-design, just a quick follow up question about this: Is it possible / a good idea to set the I inject my script like this now:
Goal would be that user could have a second try submitting the form... (maybe API server had connection error) (I'll check out how to develop a https://verbb.io/craft-plugins/formie/docs/developers/custom-integration in future, thanks very much for your advice along the way! Much appreciated! ) |
Beta Was this translation helpful? Give feedback.
This might be a better task for a custom integration with Formie. But if you want to keep the quick-and-dirty path, that's okay!
That will be fine, no issue with that. You won't cause a recursion because
EVENT_AFTER_SUBMISSION
is only triggered viaformie/submissions/submit
action endpoint and not when saving the element at any given time. Otherwise, you'd end up in an infinite saving loop.