I assume you are asking how to initialize a form?
This is what I use to pre-fill a drop-down menu.
[{"id":"b5e4059e.5d7a28","type":"inject","z":"4e4657de.9b461","name":"Initial reset","topic":"","payload":"","payloadType":"str","repeat":"","crontab":"","once":true,"onceDelay":0.1,"x":190,"y":200,"wires":[["d8ec9a42.ad7708"]]},{"id":"a532c2b5.0e645","type":"ui_dropdown","z":"4e4657de.9b461","name":"Data source","label":"","tooltip":"","place":"","group":"9c66415.50bbe4","order":1,"width":"4","height":"1","passthru":false,"options":[{"label":"","value":"","type":"str"}],"payload":"","topic":"datasource","x":890,"y":200,"wires":[[]]},{"id":"d8ec9a42.ad7708","type":"function","z":"4e4657de.9b461","name":"Set-up name-value map","func":"// This mapping file uses {\"name\":\"value\"} pairs to pre-fill the drop-down widget in the dashboard\n\nmsg.payload = \n[ \n {\"[Remove all]\":\"delete\"},\n {\"Lounge temperature\":\"lounge/temperature\"},\n {\"Snug temperature\":\"snug/temperature\"}, \n {\"Studio temperature\":\"studio/temperature\"},\n {\"Study temperature\":\"study/temperature\"},\n {\"Rear bedroom temperature\":\"rear_bedroom/temperature\"},\n {\"Rear bedroom humidity\":\"rear_bedroom/humidity\"},\n {\"Rear bedroom pressure\":\"rear_bedroom/pressure\"},\n {\"Garage temperature\":\"garage/temperature\"},\n {\"Loft temperature\":\"loft/temperature\"}\n];\nreturn msg;","outputs":1,"noerr":0,"x":430,"y":200,"wires":[["cb2b51b0.8fd79"]]},{"id":"cb2b51b0.8fd79","type":"change","z":"4e4657de.9b461","name":"","rules":[{"t":"set","p":"options","pt":"msg","to":"payload","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":680,"y":200,"wires":[["a532c2b5.0e645"]]},{"id":"52feabff.97a174","type":"comment","z":"4e4657de.9b461","name":"Pre-fill the ui-dropdown widget","info":"","x":550,"y":160,"wires":[]},{"id":"9c66415.50bbe4","type":"ui_group","z":"","name":"Filters","tab":"412738d1.eb7ae","order":2,"disp":true,"width":"24","collapse":false},{"id":"412738d1.eb7ae","type":"ui_tab","z":"","name":"Data capture and charting","icon":"dashboard","order":10}]