| 1 | {* |
| 2 | +--------------------------------------------------------------------+ |
| 3 | | CiviCRM version 4.7 | |
| 4 | +--------------------------------------------------------------------+ |
| 5 | | Copyright CiviCRM LLC (c) 2004-2015 | |
| 6 | +--------------------------------------------------------------------+ |
| 7 | | This file is a part of CiviCRM. | |
| 8 | | | |
| 9 | | CiviCRM is free software; you can copy, modify, and distribute it | |
| 10 | | under the terms of the GNU Affero General Public License | |
| 11 | | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. | |
| 12 | | | |
| 13 | | CiviCRM is distributed in the hope that it will be useful, but | |
| 14 | | WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 15 | | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | |
| 16 | | See the GNU Affero General Public License for more details. | |
| 17 | | | |
| 18 | | You should have received a copy of the GNU Affero General Public | |
| 19 | | License and the CiviCRM Licensing Exception along | |
| 20 | | with this program; if not, contact CiviCRM LLC | |
| 21 | | at info[AT]civicrm[DOT]org. If you have questions about the | |
| 22 | | GNU Affero General Public License or the licensing of CiviCRM, | |
| 23 | | see the CiviCRM license FAQ at http://civicrm.org/licensing | |
| 24 | +--------------------------------------------------------------------+ |
| 25 | *} |
| 26 | {capture assign=erURL}{crmURL p='civicrm/acl/entityrole' q='reset=1'}{/capture} |
| 27 | {capture assign=rolesURL}{crmURL p='civicrm/admin/options/acl_role' q='reset=1'}{/capture} |
| 28 | {capture assign=docLink}{docURL page='user/current/initial-set-up/permissions-and-access-control/' text='Access Control Documentation'}{/capture} |
| 29 | |
| 30 | <div id="help"> |
| 31 | <p>{ts 1=$docLink}ACLs allow you control access to CiviCRM data. An ACL consists of an <strong>Operation</strong> (e.g. 'View' or 'Edit'), a <strong>set of data</strong> that the operation can be performed on (e.g. a group of contacts, a profile or a set of custom fields), and a <strong>Role</strong> that has permission to do this operation. Refer to the %1 for more info.{/ts}</p> |
| 32 | <p>{ts 1=$erURL 2=$rolesURL}You can add or modify your ACLs below. You can create additional ACL Roles <a href='%2'>here</a>... and you can assign Roles to CiviCRM contacts who are users of your site <a href='%1'>here</a>.{/ts}</p> |
| 33 | </div> |
| 34 | |
| 35 | |
| 36 | {if $action eq 1 or $action eq 2 or $action eq 8} |
| 37 | <div class="crm-block crm-form-block"> |
| 38 | {include file="CRM/ACL/Form/ACLBasic.tpl"} |
| 39 | </div> |
| 40 | {/if} |
| 41 | |
| 42 | <div class="crm-block crm-content-block"> |
| 43 | {if $rows} |
| 44 | <div id="ltype"> |
| 45 | <p></p> |
| 46 | <div class="form-item"> |
| 47 | {strip} |
| 48 | <table> |
| 49 | <tr class="columnheader"> |
| 50 | <th>{ts}Role{/ts}</th> |
| 51 | <th>{ts}ACL Type(s){/ts}</th> |
| 52 | <th></th> |
| 53 | </tr> |
| 54 | {foreach from=$rows item=row} |
| 55 | <tr class="{cycle values="odd-row,even-row"} {$row.class}{if NOT $row.is_active} disabled{/if}"> |
| 56 | <td>{$row.entity}</td> |
| 57 | <td>{$row.object_table}</td> |
| 58 | <td>{$row.action}</td> |
| 59 | </tr> |
| 60 | {/foreach} |
| 61 | </table> |
| 62 | {/strip} |
| 63 | |
| 64 | {if $action ne 1 and $action ne 2} |
| 65 | <div class="action-link"> |
| 66 | <a href="{crmURL q="action=add&reset=1"}" id="newACL"><div class="icon ui-icon-circle-plus"></div>{ts}Add ACL{/ts}</a> |
| 67 | </div> |
| 68 | {/if} |
| 69 | </div> |
| 70 | </div> |
| 71 | {elseif $action ne 1 and $action ne 2 and $action ne 8} |
| 72 | <div class="messages status no-popup"> |
| 73 | <dl> |
| 74 | <dt><img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/></dt> |
| 75 | {capture assign=crmURL}{crmURL q="action=add&reset=1"}{/capture} |
| 76 | <dd>{ts 1=$crmURL}There are no ACLs entered. You can <a href='%1'>add one</a>.{/ts}</dd> |
| 77 | </dl> |
| 78 | </div> |
| 79 | {/if} |
| 80 | </div> |