Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

what is the difference between List action and Form action?

amar_427
Kilo Contributor

Hi,

Under System UI --> UI Actions, there are two different records for 'Cancel Request' UI Action under which one record has List action value as 'true'

and other has 'false'. So, I would like to understand how the List action is different from Form action and what it does?

find_real_file.png

4 REPLIES 4

Mujtaba Amin Bh
Mega Guru

The list action(is a UI Action) works on a list of records. For e.g deleting multiple records from a list. See below screen shot.



find_real_file.png



Form Action appears as a button on a form for e.g Update, Comments Dialog etc



find_real_file.png


BALAJI40
Mega Sage

rajmasurkar
Giga Guru

Hi,



With reference to the snapshot you shared,


UI Action Cancel request with List action = true allows you to cancel a service catalog request from a list view.


UI Action Cancel request with Form action = true allows you to cancel a service catalog request from a form view.




Regards,


Raj


Hi,



Thank you for the quick response, I have one more question on the same lines. I assume cancelling a service catalog request from a list view or a form view must trigger the same logic underneath, right? But when I looked at the script, the Form action and List action are having different java scripts. Here is the script snapshot of script.



Form Action Script:


current.request_state = 'closed_cancelled';


current.stage = 'closed_complete';


current.update();



List Action Script:


current.request_state = 'closed_cancelled';


current.update();



new UIActionUtils().approvalsNoLongerRequired(current.sys_id);