HR agents in collaborators not able to edit the Cases

kumar22
Tera Contributor

Hi Team,

I am new to HRSD module, I have requirement to fix the Collaborators issue in case form.

I gone through Collaborators functionality in docs, the believe users in Collaborators filed they have full access to the respective cases. 

Now the issue is for few Services agents has read and write access but for others agents has read access only.

I tried to create new COE and write ACL as well with the below logic but it's giving only read access to Collaborators.

Collaborators => contains = javascript: gs.getUserID()

Please suggest how can I fix this, not sure where they made the changes.

 

Thanks!

1 ACCEPTED SOLUTION

Musab Rasheed
Tera Sage
Tera Sage

Hello,

Give 'sn_hr_core.collaborator' to users whom you want as Collaborators, Also in write ACL on sc_hr_core_case table write ACL like below or modify like below.

var hasRole  = gs.hasRole('sn_hr_core.case_writer');
var hrCase = new hr_Case(current, gs);
var collab =gs.hasRole('sn_hr_core.collaborator');

if (hasRole || hrCase.canEditCase() || hrCase.isApproverUserForCase(gs.getUserID()) || sn_hr_core.hr_Case.userHasSubjectPersonAccess(current) || collab)
    answer = true;

else
	answer = false;

Please hit like and mark my response as correct if that helps

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab

View solution in original post

3 REPLIES 3

Musab Rasheed
Tera Sage
Tera Sage

Hello,

Give 'sn_hr_core.collaborator' to users whom you want as Collaborators, Also in write ACL on sc_hr_core_case table write ACL like below or modify like below.

var hasRole  = gs.hasRole('sn_hr_core.case_writer');
var hrCase = new hr_Case(current, gs);
var collab =gs.hasRole('sn_hr_core.collaborator');

if (hasRole || hrCase.canEditCase() || hrCase.isApproverUserForCase(gs.getUserID()) || sn_hr_core.hr_Case.userHasSubjectPersonAccess(current) || collab)
    answer = true;

else
	answer = false;

Please hit like and mark my response as correct if that helps

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab

Hi Rasheed, thanks for your assistance.

It seems odd behavior happening for single user has sn_hr_core.case_writer role.

He can edit few HR services not all, is there any restrictions applied like only edit specific HR cases.

Thanks!

I don't think so Unless some other ACLs or some other logic is applied, if your original question is answered please mark my answer as correct and close the thread

Please hit like and mark my response as correct if that helps
Regards,
Musab