{"_id":"6347278dab991932afb02fdf","type":"form","tags":[],"owner":"5bf5a5aa46322444b9f121bd","components":[{"title":"Conditional Properties","theme":"primary","collapsible":false,"key":"panel","type":"panel","label":"Panel","input":false,"tableView":false,"components":[{"label":"HTML","attrs":[{"attr":"","value":""}],"content":"Change the conditional field settings by selecting a value...","refreshOnChange":false,"key":"html2","type":"htmlelement","input":false,"tableView":false},{"label":"Select a Property (Trigger)","optionsLabelPosition":"right","inline":false,"tableView":false,"values":[{"label":"Set Required Flag","value":"setRequiredFlag","shortcut":""},{"label":"Change Label","value":"changeLabel","shortcut":""},{"label":"Disable Field","value":"disableField","shortcut":""}],"key":"conditionTrigger","type":"radio","input":true},{"label":"Conditional Property Field","tableView":true,"key":"conditionalField","logic":[{"name":"Logic - Required","trigger":{"type":"simple","simple":{"show":true,"when":"conditionTrigger","eq":"setRequiredFlag"}},"actions":[{"name":"Required","type":"property","property":{"label":"Required","value":"validate.required","type":"boolean"},"state":true}]},{"name":"Logic - Label","trigger":{"type":"simple","simple":{"show":true,"when":"conditionTrigger","eq":"changeLabel"}},"actions":[{"name":"Label Update","type":"property","property":{"label":"Label","value":"label","type":"string"},"text":"Update Label"}]},{"name":"Logic - Disable","trigger":{"type":"simple","simple":{"show":true,"when":"conditionTrigger","eq":"disableField"}},"actions":[{"name":"Disable","type":"property","property":{"label":"Disabled","value":"disabled","type":"boolean"},"state":true}]}],"type":"textfield","input":true}]},{"title":"Conditional Values","theme":"primary","collapsible":false,"key":"conditionalValue1","type":"panel","label":"Panel","input":false,"tableView":false,"components":[{"label":"HTML","attrs":[{"attr":"","value":""}],"content":"Fill out the First Name and Last Name fields","refreshOnChange":false,"key":"html1","type":"htmlelement","input":false,"tableView":false},{"label":"Columns","columns":[{"components":[{"label":"First Name","tableView":true,"key":"firstName","type":"textfield","input":true}],"width":6,"offset":0,"push":0,"pull":0,"size":"md","currentWidth":6},{"components":[{"label":"Last Name","tableView":true,"key":"lastName","type":"textfield","input":true}],"width":6,"offset":0,"push":0,"pull":0,"size":"md","currentWidth":6}],"key":"columns","type":"columns","input":false,"tableView":false},{"label":"Populate Values (trigger)","tableView":false,"defaultValue":false,"key":"conditionalTriggerValue","type":"checkbox","input":true},{"label":"HTML","attrs":[{"attr":"","value":""}],"content":"Tick the Checkbox to populate First Name and Last Name data to the conditional field","refreshOnChange":false,"key":"html","type":"htmlelement","input":false,"tableView":false},{"label":"Conditional Value Field","tableView":true,"key":"conditionalValue","logic":[{"name":"Logic - Value","trigger":{"type":"simple","simple":{"show":true,"when":"conditionalTriggerValue","eq":"true"}},"actions":[{"name":"Action Value","type":"value","value":"value = data.firstName + data.lastName;"}]}],"type":"textfield","input":true}]},{"title":"Conditional Schema Updates ","theme":"primary","collapsible":false,"key":"conditionalMergeSchema","type":"panel","label":"Panel","input":false,"tableView":false,"components":[{"label":"HTML","attrs":[{"attr":"","value":""}],"content":"Select an update option to change the schema values of question 2...","refreshOnChange":false,"key":"html3","type":"htmlelement","input":false,"tableView":false},{"label":"Update Question 2 Values","optionsLabelPosition":"right","inline":false,"tableView":false,"values":[{"label":"Animals","value":"a","shortcut":""},{"label":"Fruit","value":"b","shortcut":""}],"key":"age","type":"radio","input":true},{"label":"Question 2","optionsLabelPosition":"right","inline":false,"tableView":false,"values":[{"label":"Default Value A","value":"a","shortcut":""},{"label":"Default Value B","value":"b","shortcut":""}],"key":"q2","logic":[{"name":"Update Values: Animals","trigger":{"type":"simple","simple":{"show":true,"when":"age","eq":"a"}},"actions":[{"name":"Schema Update","type":"mergeComponentSchema","schemaDefinition":"schema = {values:[{label: 'Cat', value: 'cat'}, {label:'Dog', value: 'dog'}]};"}]},{"name":"Update Values: Fruits","trigger":{"type":"simple","simple":{"show":true,"when":"age","eq":"b"}},"actions":[{"name":"Update fruit","type":"mergeComponentSchema","schemaDefinition":"schema = {values:[{label: 'Apple', value: 'apple'}, {label:'Banana', value: 'banana'}]};"}]}],"type":"radio","input":true}]},{"label":"<b>Reset Form</b>","action":"reset","showValidations":false,"theme":"secondary","block":true,"disableOnInvalid":true,"tableView":false,"key":"submit","type":"button","input":true}],"revisions":"current","_vid":1,"title":"Logic","display":"form","access":[{"type":"create_own","roles":[]},{"type":"create_all","roles":[]},{"type":"read_own","roles":[]},{"type":"read_all","roles":["6347275deaed4f8b8792666b","6347275deaed4fe4ab926673","6347275deaed4f8316926678"]},{"type":"update_own","roles":[]},{"type":"update_all","roles":[]},{"type":"delete_own","roles":[]},{"type":"delete_all","roles":[]},{"type":"team_read","roles":[]},{"type":"team_write","roles":[]},{"type":"team_admin","roles":[]}],"submissionAccess":[{"type":"create_own","roles":["6347275deaed4f8316926678"]},{"type":"create_all","roles":[]},{"type":"read_own","roles":[]},{"type":"read_all","roles":[]},{"type":"update_own","roles":[]},{"type":"update_all","roles":[]},{"type":"delete_own","roles":[]},{"type":"delete_all","roles":[]},{"type":"team_read","roles":[]},{"type":"team_write","roles":[]},{"type":"team_admin","roles":[]}],"controller":"","properties":{},"settings":{},"name":"logic","path":"logic","project":"6347275deaed4fff5592665f","created":"2022-10-12T20:46:05.147Z","modified":"2023-09-01T16:27:10.882Z","machineName":"kiajjsgmjcrqziu:exampleLogic","submissionRevisions":"","plan":"commercial"}