Authorized users approve salary changes by using the SalaryReview case type in the HRApp application. You need to ensure that only managers have access to the button that is used to approve salary changes.
Assume that these steps have already been done:
- Access groups are defined for human resources staff (HRApp:HRStaff) and managers (HRApp:Managers).
- A role is defined for salary approval processing (HRApp:SalaryApproval).
- The HRApp:SalaryApproval role is assigned to the HRApp:Managers access group.
- The user interface includes a button named pyApproveSalary, which a user clicks to approve a salary change.
- Create the CanApproveSalary privilege by doing the
- In Dev Studio, click .
- In the Label field, enter CanApproveSalary.
- In the Apply to field, enter SalaryReview, and then click Create and open.
- Click Save.
- Associate the CanApproveSalary privilege with the
pyApproveSalary button by doing the following
- In Dev Studio, open the section that contains the button pyApproveSalary, and select the pyApproveSalary button.
- Click the View Properties icon.
- In the Privilege field, enter CanApproveSalary.
- Click Submit.
- Click Save.
- In Dev Studio, go to the Privileges tab of the Access Manager landing page by clicking .
- In the Role field, enter HRApp:SalaryApproval, and in the Case type field, enter SalaryReview. The tab lists privileges that apply to this role and case type.
- Click the Add a privilege icon and in the Privilege field, enter CanApproveSalary.
- In the dialog box for this privilege, click Full Access, and then click OK.
- For other roles for the SalaryReview case type, repeat the above steps, but ensure that the CanApproveSalary privilege is not listed or that the privilege is shown with a red X icon. You can change the value by clicking the icon.