Edit the slots after submission of the form action

After form action completion , How can we change the few slots . For example if form details filled by the user . After submit he wants to edit some form fields . Is there any solution.

def submit(self, dispatcher, tracker, domain):
    #  some code
    return [SlotSet("details", None), SlotSet("another_slot", "new value")]

Let the submit method return the SlotSets with new values.

The above example will clear the “details” slot and set the value of “another_slot” to “new value”

Hi @dadecoza , Thanks for the response . After submit , the user want to edit particular slots . Then how can we change it in submit method.

Hi @Chaitanya first you have to reset the slot value to “None” which you needed to edit . Say for example reset the solt value of “date” to “None”

class ResetSlot(Action):
    def name(self):
        return "action_reset_date"

 def run(self, dispatcher, tracker, domain):
        return [SlotSet("date", None)]

After resetting the requred slot value to “None” run the form again. The form will automatically ask value for the required slot.