From: Coleman Watts Date: Fri, 15 Jun 2018 03:20:17 +0000 (-0400) Subject: Disable inline-edit of multi-record custom fields in profiles X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=13f7c8449ba3659b0bf9afead93418427af6a3ea;p=civicrm-core.git Disable inline-edit of multi-record custom fields in profiles --- diff --git a/CRM/Profile/Page/MultipleRecordFieldsListing.php b/CRM/Profile/Page/MultipleRecordFieldsListing.php index 9bff1a8a15..e8ab497e07 100644 --- a/CRM/Profile/Page/MultipleRecordFieldsListing.php +++ b/CRM/Profile/Page/MultipleRecordFieldsListing.php @@ -341,7 +341,7 @@ class CRM_Profile_Page_MultipleRecordFieldsListing extends CRM_Core_Page_Basic { // TODO: Not all widget types and validation rules are supported by crmEditable so some fields will not be in-place editable $fieldAttributes = array('class' => "crmf-custom_{$fieldId}_$recId"); $editable = FALSE; - if (!$options[$fieldId]['attributes']['is_view'] && $linkAction & CRM_Core_Action::UPDATE) { + if (!$options[$fieldId]['attributes']['is_view'] && $this->_pageViewType == 'customDataView' && $linkAction & CRM_Core_Action::UPDATE) { $spec = $options[$fieldId]['attributes']; switch ($spec['html_type']) { case 'Text': diff --git a/templates/CRM/Profile/Page/MultipleRecordFieldsListing.tpl b/templates/CRM/Profile/Page/MultipleRecordFieldsListing.tpl index 3091780ba8..bef10e07b2 100644 --- a/templates/CRM/Profile/Page/MultipleRecordFieldsListing.tpl +++ b/templates/CRM/Profile/Page/MultipleRecordFieldsListing.tpl @@ -72,7 +72,7 @@ } } }); - }, + } }) })(CRM.$);