How can I check to see who has the Timesheet approval right in Clarity PPM at either the global or instance level?
This can help in particular if some users are getting notifications to approve timesheets unexpectedly, which can happen if they have timesheet - approval rights to the resource. (See Timesheet Notifications get sent automatically without using a process definition for more details on this issue)
2. You can check who has instance level timesheet approval rights to a specific user by using the following steps from the Clarity PPM UI:
Note: If you go to the Full View link on the access to this resource tab, it may help point to who has the right through a global right, but if there is a large number this may not help as it doesn't specify what rights they have to the resource there.
3. Additionally, for On Premise customers, here are a couple of queries that can help:
Timesheet global query:
SELECT RES.UNIQUE_NAME, 'HAS INSTANCE RIGHTS TO' AS RIGHT_TYPE, PERM.OBJECT_INSTANCE_ID
FROM
CMN_SEC_ASSGND_OBJ_PERM_V PERM,
SRM_RESOURCES RES
WHERE PERM.PERMISSION_CODE = 'prApproveActuals'
AND PERM.COMPONENT_CODE = 'PRJ'
AND PERM.OBJECT_CODE = 'PRJ_RESOURCE'
AND PERM.OBJECT_TYPE = 'RECORD'
AND PERM.USER_ID = RES.ID
UNION
SELECT CMN_SEC_USERS.USER_NAME, 'GLOBAL', -9999 --- global right query
FROM CMN_SEC_USER_R_V, CMN_SEC_USERS
WHERE PERMISSION_CODE = 'APPROVE'
AND USER_ID = CMN_SEC_USERS.ID
AND OBJECT_ID IN
(
SELECT ID
FROM cmn_sec_objects
WHERE OBJECT_CODE = 'TMS_TIMESHEETS'
AND OBJECT_TYPE_ID = 6
)
Instance level query:
SELECT
P.USER_ID, P.USER_NAME TS_APPROVER, P.OBJECT_INSTANCE_ID,
srmr.unique_name TS_SUBMITTER, srmr.last_name, srmr.last_name
FROM
CMN_SEC_ASSGND_OBJ_PERM_V P,
SRM_RESOURCES srmr
WHERE 1=1
and SRMR.id = OBJECT_INSTANCE_ID
--and P.USER_NAME in ('admin')
AND P.PERMISSION_CODE = 'prApproveActuals'