Problem - State visible only for particular group

nameisnani
Mega Sage

Hi Team ,

 

We have a requirement on Problem table 

 

Ptask - " complete " Ui Action should be only visible to certain group .

Problem - " Resolve" Button should be only visible to certain group . 

 

Example group - ' Sbc_prb_grp'

 

nameisnani_0-1712043519904.pngnameisnani_1-1712043573960.png

 

 

Can anyone please help me with steps and Please provide screenshots .

 

Please provide configure steps and screenshots.

 

Thanks in Advance .....

 

 

16 REPLIES 16

HI @nameisnani replace the below script to your UI action condition

gs.getUser().isMemberOf('group Name') && current.canWrite() && (current.state != ProblemState.STATES.RESOLVED) && (current.state == ProblemState.STATES.FIX_IN_PROGRESS) && new ProblemStateUtils().validateStateTransition(current, ProblemState.STATES.RESOLVED)

Regards
Harish

Hi @Harish KM 

 

I was trying to paste your code 

But I was unable to paste , not allowing complete condition

 

upto this only it is pasting .

 

Please tell what should i do .

 

gs.getUser().isMemberOf('Problem Solving') && current.canWrite() && (current.state != ProblemState.STATES.RESOLVED) && (current.state ==ProblemState.STATES.FIX_IN_PROGRESS) && new ProblemStateUtils().validateStateTransition(current, ProblemState.STATES.R

 

nameisnani_0-1712117323431.png

 

Hi @nameisnani you need to increase the max lenght value of condition field

HarishKM_0-1712122144165.png

 

Regards
Harish

Hi @Harish KM 

 

I have updated the condtion

 

nameisnani_0-1712124228193.png

 

nameisnani_1-1712124239527.png

 

And I have impersonated with the user who part of problm sloving group .

But still not able to see resolve button.

 

Hi @nameisnani the user needs to satisfy other conditions as well, which is existing

Regards
Harish