The Zurich release has arrived! Interested in new features and functionalities? Click here for more

Removing the "insert new row" from an Embedded List

alecturner
Kilo Explorer

I have a list inside a list and I'm trying to hide the "insert new row" option as I don't want users to add new rows, but under list controls I don't see the check box to remove that option. Any thoughts??

12 REPLIES 12

JusCuz
Tera Guru

So your list control form does not look like this for the list in question? Can you tell us which list you are having issues with?



Capture.PNG


Capture.PNG



This is the list control I am looking at. This is brought up by right clicking on a column within the list that I am trying to remove the "insert new row" and going to Personalize > List Controls.


Looks like do have to use ACL...


http://wiki.servicenow.com/index.php?title=Embedded_Lists#gsc.tab=0


3 Securing Records in an Embedded List

To apply security to the records in embedded lists, limit editing and deleting records in embedded lists to specific roles.


  1. Navigate to System Security > Access Control.
  2. Open the Write or Delete record for the appropriate table.
  3. In the Requires Role section of the form add the roles that have write or delete permission for that table.
  4. Save the changes.
    When records from the associated table appear in an embedded list, the edit and delete options will be available only to users with the specified roles.

I was able to selectively remove the "insert new row" from these Embedded Lists by adding this script to the write/create ACLs:



if ((typeof(parent) != "undefined") && parent.sys_class_name.substring('cmdb_ci') != -1){


  answer = false;


} else {


  answer = true;


}



Where in our case, we wanted to hide "insert new row" on incident, problem and change_request embedded lists specifically on CMDB form views.


JusCuz
Tera Guru

Ok, I see, I have not used the functionality like that before. Using it that way I think your easiest option are ACL's. I'm not sure if you can add that in as a related list instead, by clicking configure\related lists in the context menu.