What is the alternative way to use gel() in service portal..?

Nithin12
Tera Expert

Hi Team,

Can any body let me the alternative way of gel() in service portal.

i have written this onSubmit script, which works fine in CMS,

Here i need to get value of sysparm_item_guid, how do I get with out using gel() method?

I am attaching the code:

var cat_id = gel('sysparm_item_guid').value;

var sp = new GlideRecord("sys_attachment");

  sp.addQuery("table_name", "sc_cart_item");

  sp.addQuery("table_sys_id", cat_id);

  sp.query(function(){

  if (!sp.next()) {

  g_form.addErrorMessage("Please attach the required SSL certificates/document");

  return false;

  }

  });

Any help or suggestion will help me lot  

Thanks,

Nithin.

PlatformDeveloper CommunityBlogs

10 REPLIES 10

Great script, work for me.

 

Thanks,