Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-12735

"Actions" button don't show up in Contact summary without the edit permission

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.2.8, 4.3.3
    • Fix Version/s: 4.4.0
    • Component/s: Core CiviCRM
    • Labels:

      Description

      In templates/CRM/Contact/Page/View/Summary.tpl on line 53 :

      Current behavior:
      The user must have the edit contact permission for the "Actions" button to be displayed in the Contact Summary.

      Expected behavior :
      The "Actions" button should always show up even without the edit permission because the user could have the permission to add activities, send emails, Print PDF letters or just download the contact's vCard.

      Fix/Patch for the trunk:

      templates/CRM/Contact/Page/View/Summary.tpl on line 52-53:

      > {* Include the Actions and Edit buttons if user has 'edit' permission and contact is NOT in trash. *}
      <

      {if $permission EQ 'edit' and !$isDeleted}
      -
      > {* Include the Actions and Edit buttons if contact is NOT in trash. *}
      > {if !$isDeleted}




      Fix/Patch for 4.2LTS :

      templates/CRM/Contact/Page/View/Summary.tpl

      46,47c46,47
      < {* Include the Actions and Edit buttons if user has 'edit' permission and contact is NOT in trash. *}
      < {if $permission EQ 'edit' and !$isDeleted}


      > {* Include the Actions and Edit buttons if contact is NOT in trash. *}
      >

      {if !$isDeleted}

      51,56c51,59
      < <li>
      <

      {assign var='editParams' value=$urlParams|cat:"&action=update&cid=$contactId"}

      < <a href="

      {crmURL p='civicrm/contact/add' q=$editParams}" class="edit button" title="{ts}Edit{/ts}">
      < <span><div class="icon edit-icon"></div>{ts}Edit{/ts}</span>
      < </a>
      < </li>

      > {* Include the Edit buttons if user has 'edit' permission. *}
      > {if $permission EQ 'edit'}
      > <li>
      > {assign var='editParams' value=$urlParams|cat:"&action=update&cid=$contactId"}
      > <a href="{crmURL p='civicrm/contact/add' q=$editParams}

      " class="edit button" title="

      {ts}Edit{/ts}">
      > <span><div class="icon edit-icon"></div>{ts}

      Edit

      {/ts}

      </span>
      > </a>
      > </li>
      >

      {/if}

        Attachments

          Activity

            People

            • Assignee:
              dgg David Greenberg
              Reporter:
              julienld Julien Larocque-Dupont
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: