Hiding Field on Record Preview

Kev9
Kilo Sage

Hi,

I have a Catalog Item that can be viewed by all resolver groups but contains sensitive data in one of the variables. That data should only be able to be viewed by one particular group.

I've created a UI policy that successfully hides the field on the RITM form, but it is visible from the sys_popup on the SC_Task form.

I've looked at creating and ACL but cannot get the desired result with that.

I've searched all over for a solution to this. I would have though that it is quite a common occurrence for sensitive data be required to be hidden from all but certain groups, but have yet to find an answer.

Any help gratefully appreciated!

12 REPLIES 12

mjwhirly
Kilo Contributor

I can confirm this method works as I utilize this myself

But that also hides it in the Catalog Item in the Service Portal 😞

Chavan AP
Kilo Sage

Hi Kev,

 

Use below script in client script whenever needed:

	try{

      //Get the 'Variables' section

      var ve = $('variable_map').up('table');

      //Disable all elements within with a class of 'cat_item_option'

      ve.select('.cat_item_option', '.slushselectmtm', '.questionsetreference').each(function(elmt){

         elmt.disabled = true;// here you can user elemt.hind= true;

      });

      //Remove any reference or calendar icons

      ve.select('img[src*=reference_list.gifx]', 'img[src*=small_calendar.gifx]').each(function(img){

         img.hide();

      });

      //Hide list collector icons

      ve.select('img[src*=arrow]').each(function(img){

         img.up('table').hide();

      });

   }

   catch(e){}

 

if this resolves your query mark it helpful and correct

 

regards,

ajay

Glad I could help! If this solved your issue, please mark it as ✅ Helpful and ✅ Accept as Solution so others can benefit too.*****Chavan A.P. | Technical Architect | Certified Professional*****

Hi Ajay,

 

Seems to have had no effect unfortunately.

 

Regards,

 

Kev

why dont you change the UI policy to catalog client script and check option applies to catalog task. This should do the trick

find_real_file.png