{* +--------------------------------------------------------------------+ | CiviCRM version 4.7 | +--------------------------------------------------------------------+ | Copyright CiviCRM LLC (c) 2004-2017 | +--------------------------------------------------------------------+ | This file is a part of CiviCRM. | | | | CiviCRM is free software; you can copy, modify, and distribute it | | under the terms of the GNU Affero General Public License | | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. | | | | CiviCRM is distributed in the hope that it will be useful, but | | WITHOUT ANY WARRANTY; without even the implied warranty of | | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | | See the GNU Affero General Public License for more details. | | | | You should have received a copy of the GNU Affero General Public | | License and the CiviCRM Licensing Exception along | | with this program; if not, contact CiviCRM LLC | | at info[AT]civicrm[DOT]org. If you have questions about the | | GNU Affero General Public License or the licensing of CiviCRM, | | see the CiviCRM license FAQ at http://civicrm.org/licensing | +--------------------------------------------------------------------+ *} {* CiviCase DashBoard (launch page) *}
{if $notConfigured} {* Case types not present. Component is not configured for use. *} {include file="CRM/Case/Page/ConfigureError.tpl"} {else} {capture assign=newCaseURL}{crmURL p="civicrm/case/add" q="action=add&context=standalone&reset=1"}{/capture}
{if $newClient and $allowToAddNewCase} {ts}Add Case{/ts} {/if} {ts}Find My Cases{/ts}
{if $myCases} {* check for access all cases and activities *} {if call_user_func(array('CRM_Core_Permission','check'), 'access all cases and activities')}
{ts}All Cases with Upcoming Activities{/ts}
{ts}My Cases with Upcoming Activities{/ts}
{/if} {else}
{ts}All Cases with Upcoming Activities{/ts}
{ts}My Cases with Upcoming Activities{/ts}
{/if}

{if $myCases} {ts}Summary of Involvement{/ts} {else} {ts}Summary of All Cases{/ts} {/if}

{foreach from=$casesSummary.headers item=header} {/foreach} {foreach from=$casesSummary.rows item=row key=caseType} {foreach from=$casesSummary.headers item=header} {assign var="caseStatus" value=$header.status} {/foreach} {/foreach}
 {$header.status}
{$caseType} {if $row.$caseStatus} {$row.$caseStatus.count} {else} 0 {/if}
{capture assign=findCasesURL}{ts}Find Cases{/ts}{/capture}

{if $myCases}{ts}My Cases With Upcoming Activities{/ts}{else}{ts}All Cases With Upcoming Activities{/ts}{/if}

{if $upcomingCases}
{include file="CRM/Case/Page/DashboardSelector.tpl" context="dashboard" list="upcoming" rows=$upcomingCases}
{else}
{ts 1=$findCasesURL}There are no open cases with activities scheduled in the next two weeks. Use %1 to expand your search.{/ts}
{/if}

{if $myCases}{ts}My Cases With Recently Performed Activities{/ts}{else}{ts}All Cases With Recently Performed Activities{/ts}{/if}

{if $recentCases}
{include file="CRM/Case/Page/DashboardSelector.tpl" context="dashboard" list="recent" rows=$recentCases}
{else}
{ts 1=$findCasesURL}There are no cases with activities scheduled in the past two weeks. Use %1 to expand your search.{/ts}
{/if} {/if}