Details
-
Type: Sub-task
-
Status: Done/Fixed
-
Priority: Major
-
Resolution: Fixed/Completed
-
Affects Version/s: 3.4.1
-
Fix Version/s: 3.4.3
-
Component/s: Core CiviCRM
-
Labels:None
Description
This issue is related to CRM-8148
We currently only allow Contact Profiles to be created/edited/viewed by the end user (with the right permission). This feature will extend the edit/view functionality to activities also. (Note that we are not handling create). A few things to handle:
1. The Profile View/Edit code should allow this if
- The contact has permission to edit/view their own record
- The contact has the profile edit/view permissions
- There is an activity ID associated with the GET request
2. Survey has a lot of the same code (definitely for editing) in the batch update widget. Please use the API created by this issue: CRM-8148 and centralize the two code bases
3. Check and ensure that create profile (profile/create) returns an error if a profile with both contact and activity fields is requested:
"Profiles which contain activity fields can only be used to edit existing records."
4. We should be able to handle
- All Contact fields in profile including custom fields
- All Activity fields in profile including custom fields
5. We will need to validate the profile fields as they're added to the profile to ensure that they don't contain a mix of custom fields used for different activity types (e.g. profile can't contain a field bound to a custom field used for Activities::Surveys AND a field bound to custom field used for Activities::Meetings). An API will be created for this (CRM-8148).