"action_deactivate_form" vs "form{name:null}"

What’s the difference between “action_deactivate_form” and “form{name:null}” ? From my point of view they do the same thing, like deactivating the form, but the point is if they do exactly same thing why do we need to use both of them in the code below:

## loans_types_form + cards_debit_cards_form
* loans.types
   - loans_types_form
   - form{"name": "loans_types_form"}
* cards.debit_cards
   - action_deactivate_form
   - cards_debit_cards_form
   - form{"name": "cards_debit_cards_form"}
   - form{"name": null}   
   - action_feedback

form{"name": null} is not an action it is the event that is returned by action action_deactivate_form or by a form action if all slots are filled. Since during core training we don’t actually run actions, you need to put this event in your stories as a notification that a form got deactivated.

In your story, action_deactivate_form shouldn’t be present at all

## loans_types_form + cards_debit_cards_form
* loans.types
   - loans_types_form
   - form{"name": "loans_types_form"}
* cards.debit_cards
   - cards_debit_cards_form
   - form{"name": "cards_debit_cards_form"}
   - form{"name": null}   
   - action_feedback
1 Like