Answers.Body: <p>I'd say this is coming from CRM_Case_BAO_Case::checkPermission(), around line 2659 where it says</p>
  
  <pre><code>//user has only access to my cases and activity. [sic]
  //here object specific permmions come in picture.
  </code></pre>
  
  <p>It seems like this is part of the definition of "my cases and activities", where you have to be either the reporter, with contact/target, or assignee of the activity to be able to view it.</p>
  
  <p>So to get the arrangement you're looking for you either have to give them access to all cases and activities, or something more complicated involving code is needed.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2018-03-06T20:03:13.267Z
Answers.Text: Yes that sounds right and yes I expect we will need to do this via an Extension
Answers.UserDisplayName: petednz - fuzion
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2018-03-06T18:52:47.643Z
Answers.LastActivityDate: 2018-03-06T18:52:47.643Z
Answers.UserDisplayName: Demerit
Body: <p>We want to add a secondary case role that is similar to Case Manager with slightly less permissions (eg cannot change/add case roles, can't delete case etc).
  We have a relationship that can be added as a case role in the case settings.
  People that have this new case role also have a drupal role. Their permissions are currently "access my cases and activities" , "view all activities.
  However when they look at a case they are the new Case Role for they can see all the activities listed for the case, but don't have the option to go and 'view' the activity's details (unless they are a contact listed on the activity).
  We want them to be able to view the activity details for the case.</p>
  
  <p>When we find the relevant url that would give a Case Manager access to the activity, and test that url as this other user then we get "do not have permission to access this page" - eg url of type /civicrm/case/activity/view?cid=XXXX&amp;aid=YYY</p>
  
  <p>Thoughts?</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2018-02-19T23:11:13.323Z
Comments.Text: Sounds like it might be a bug/oversight. I can't think of a reason it wouldn't behave as expected. I assume you mean if you click on the activity subject it gives access denied.
Comments.UserDisplayName: Demerit
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2018-02-20T00:55:22.800Z
Comments.Text: will test and confirm
Comments.UserDisplayName: petednz - fuzion
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2018-03-06T05:14:21.227Z
Comments.Text: if we find the relevant url that would be what a Case Manager would use, and then test that url as this other user then we get "do not have permission to access this page - eg url of type /civicrm/case/activity/view?cid=XXXX&aid=YYY
Comments.UserDisplayName: petednz - fuzion
Tags: <civicase><activities><permissions><roles>
Title: How to add a secondary Case Role that has access to Activities they are not 'on', eg ones that existed before they were added
ThreadText: # How to add a secondary Case Role that has access to Activities they are not 'on', eg ones that existed before they were added
  
  (Asked by: username_0 on 2018-02-18)
  
  We want to add a secondary case role that is similar to Case Manager with slightly less permissions (eg cannot change/add case roles, can't delete case etc).
  We have a relationship that can be added as a case role in the case settings.
  People that have this new case role also have a drupal role. Their permissions are currently "access my cases and activities" , "view all activities.
  However when they look at a case they are the new Case Role for they can see all the activities listed for the case, but don't have the option to go and 'view' the activity's details (unless they are a contact listed on the activity).
  We want them to be able to view the activity details for the case.
  
  When we find the relevant url that would give a Case Manager access to the activity, and test that url as this other user then we get "do not have permission to access this page" - eg url of type /civicrm/case/activity/view?cid=XXXX&aid=YYY
  
  Thoughts?
  
  **Tags:** civicase, activities, permissions, roles
  
  > **Comments:**
  > **username_1**: Sounds like it might be a bug/oversight. I can't think of a reason it wouldn't behave as expected. I assume you mean if you click on the activity subject it gives access denied.  
  > **username_0**: will test and confirm  
  > **username_0**: if we find the relevant url that would be what a Case Manager would use, and then test that url as this other user then we get "do not have permission to access this page - eg url of type /civicrm/case/activity/view?cid=XXXX&aid=YYY  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2018-03-06. Score: 1
  
  I'd say this is coming from CRM\_Case\_BAO\_Case::checkPermission(), around line 2659 where it says
  
  ```
  //user has only access to my cases and activity. [sic]
  //here object specific permmions come in picture.
  
  ```
  
  It seems like this is part of the definition of "my cases and activities", where you have to be either the reporter, with contact/target, or assignee of the activity to be able to view it.
  
  So to get the arrangement you're looking for you either have to give them access to all cases and activities, or something more complicated involving code is needed.
  
  > **Comments:**
  > **username_0**: Yes that sounds right and yes I expect we will need to do this via an Extension  
  
  ---
  
  