Clear Input Text after saving information


I have UI_Text_input on my form to get the user to enter information to be saved in MYSQL. When I click on the button SAVE, data are saved, but I want to clear all the text_input after all by blank data.

What I did to clear them up :

  1. With Change Node, I assign an empty string to msg.payload and send it to the UI_Text_input. That is working and removing the old date but it displayed change in the UI_Text_input once applied.

  2. I tried the same thing, but instead, sending an empty string, I send ' or ''. That's also clean the field but displayed the characters into the Text_input.

I am trying to find a way to clean the text_input once the data is saved and so far, can figure it out a good way to do it.

Hope I have been clear



Try after you save the data, set msg.payload to "" (blank) and send that to the input of the ui_text node.
You might want to add a switch on the output of the ui_text node to ignore msgs with a blank payload

Very good idea, I'll give a try and post the result.

Thanks a lot ,



The solution works well by sending and empty msg.payload once the data are saved.

thanks a lot