How to create a record from inside of workspace ?

Sanket1
Giga Contributor

I am able to add fields values using the form fields component from UI Builder, but the question is how I can submit it, I mean how to configure submit button so that record will get created 

[ No Submit Button ]

CAN ANYONE PLEASE HELP WITH THE STEPS TO CONFIGURE SUBMIT BUTTON

find_real_file.png

1 ACCEPTED SOLUTION

Kirankumar Amba
ServiceNow Employee
ServiceNow Employee

Form fields does not support the use of ui actions. It is mainly intended to be as a read only component. You have to use Form component to be able to support ui actions.

Steps to create a form:

  • Take a Form component. Add a Glide Form data broker from @servicenow/now-record-form-connected application

find_real_file.png

  • Update the details for the data broker instance:
    • Table: incident
    • SysID: -1 (for any new record)

find_real_file.png

  • Now you have form data available in @data.glide_form_1 prop
  • Update your form config:
    • Sections: @data.glide_form_1.nowRecordFormBlob.sections
    • Fields: @data.glide_form_1.nowRecordFormBlob.fields
    • Table: incident

find_real_file.png

  • By now, you should have your form ready
  • Next step: Setting up UI actions
  • Add a Action Bar component on the top of form and update the config as: 
    • Actions: @data.glide_form_1.nowRecordCommonUiactionbar.actionNodes

find_real_file.png

  • That's it! You should have your form ready with a save action. Try creating an incident. It should work as expected. 

Let me know if it works or you have any doubts. Thanks!

 

View solution in original post

11 REPLIES 11

Hi 

this is creating a new record and save how about the existing record and how to save.

what changes to need to be done in the table anybody help me

Hi, sorry for late reply. If you need to edit an existing record, give sys_id of that record instead of -1 in the Step 1 above. That should pre-fill all the data and you can edit and save the record. Thanks!