Move event ical icons to iCalLinks.tpl and supply URLs centrally
[civicrm-core.git] / templates / CRM / Event / Page / ManageEvent.tpl
1 {*
2 +--------------------------------------------------------------------+
3 | Copyright CiviCRM LLC. All rights reserved. |
4 | |
5 | This work is published under the GNU AGPLv3 license with some |
6 | permitted exceptions and without any warranty. For full license |
7 | and copyright information, see https://civicrm.org/licensing |
8 +--------------------------------------------------------------------+
9 *}
10 {capture assign=newEventURL}{crmURL p='civicrm/event/add' q="action=add&reset=1"}{/capture}
11 {capture assign=icalFile}{crmURL p='civicrm/event/ical' q="reset=1" fe=1}{/capture}
12 {capture assign=icalFeed}{crmURL p='civicrm/event/ical' q="reset=1&list=1" fe=1}{/capture}
13 {capture assign=rssFeed}{crmURL p='civicrm/event/ical' q="reset=1&list=1&rss=1" fe=1}{/capture}
14 {capture assign=htmlFeed}{crmURL p='civicrm/event/ical' q="reset=1&list=1&html=1" fe=1}{/capture}
15
16 <div class="crm-block crm-content-block">
17 <div class="float-right">
18 {include file="CRM/Event/Page/iCalLinks.tpl"}
19 </div>
20
21 <div class="action-link">
22 <a accesskey="N" href="{$newEventURL}" id="newManageEvent" class="button crm-popup">
23 <span><i class="crm-i fa-calendar-plus-o"></i> {ts}Add Event{/ts}</span>
24 </a>
25 <div class="clear"></div>
26 </div>
27
28 {include file="CRM/Event/Form/SearchEvent.tpl"}
29
30 {if $rows}
31 <div id="event_status_id" class="crm-block crm-manage-events">
32 {strip}
33 {include file="CRM/common/pager.tpl" location="top"}
34 {include file="CRM/common/pagerAToZ.tpl"}
35 {* handle enable/disable actions*}
36 {include file="CRM/common/enableDisableApi.tpl"}
37 {include file="CRM/common/jsortable.tpl"}
38 <table id="options" class="display">
39 <thead>
40 <tr>
41 <th>{ts}Event{/ts}</th>
42 <th>{ts}City{/ts}</th>
43 <th>{ts}State/Province{/ts}</th>
44 <th>{ts}Type{/ts}</th>
45 <th>{ts}Public?{/ts}</th>
46 <th>{ts}Starts{/ts}</th>
47 <th>{ts}Ends{/ts}</th>
48 {if call_user_func(array('CRM_Campaign_BAO_Campaign','isCampaignEnable'))}
49 <th>{ts}Campaign{/ts}</th>
50 {/if}
51 <th>{ts}Active?{/ts}</th>
52 <th></th>
53 <th class="hiddenElement"></th>
54 <th class="hiddenElement"></th>
55 </tr>
56 </thead>
57 {foreach from=$rows key=keys item=row}
58 {if $keys neq 'tab'}
59 <tr id="event-{$row.id}" class="crm-entity {if NOT $row.is_active} disabled{/if}">
60 <td class="crm-event_{$row.id}">
61 <a href="{crmURL p='civicrm/event/info' q="id=`$row.id`&reset=1"}"
62 title="{ts}View event info page{/ts}" class="bold">{$row.title}</a>&nbsp;&nbsp;({ts}ID:{/ts} {$row.id})<br/>
63 <span><b>{$row.repeat}</b></span>
64 </td>
65 <td class="crm-event-city">{$row.city}</td>
66 <td class="crm-event-state_province">{$row.state_province}</td>
67 <td class="crm-event-event_type">{$row.event_type}</td>
68 <td class="crm-event-is_public">{if $row.is_public eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}</td>
69 <td class="crm-event-start_date" data-order="{$row.start_date|crmDate:'%Y-%m-%d'}">{$row.start_date|crmDate:"%b %d, %Y %l:%M %P"}</td>
70 <td class="crm-event-end_date" data-order="{$row.end_date|crmDate:'%Y-%m-%d'}">{$row.end_date|crmDate:"%b %d, %Y %l:%M %P"}</td>
71 {if call_user_func(array('CRM_Campaign_BAO_Campaign','isCampaignEnable'))}
72 <td class="crm-event-campaign">{$row.campaign}</td>
73 {/if}
74 <td class="crm-event_status" id="row_{$row.id}_status">
75 {if $row.is_active eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}
76 </td>
77 <td class="crm-event-actions right nowrap">
78 <div class="crm-configure-actions">
79 <span id="event-configure-{$row.id}" class="btn-slide crm-hover-button">{ts}Configure{/ts}
80 <ul class="panel" id="panel_info_{$row.id}">
81 {foreach from=$rows.tab key=k item=v}
82 {assign var="fld" value=$v.field}
83 {if NOT $row.$fld}{assign var="status" value="disabled"}{else}{assign var="status" value="enabled"}{/if}
84 {if $k eq 'reminder'}
85 <li><a title="{$v.title|escape:'html'}" class="action-item crm-hover-button {$status}"
86 href="{crmURL p="`$v.url`" q="reset=1&action=browse&setTab=1&id=`$row.id`"}">{$v.title}</a>
87 {else}
88 <li><a title="{$v.title|escape:'html'}" class="action-item crm-hover-button {$status}"
89 href="{crmURL p="`$v.url`" q="reset=1&action=update&id=`$row.id`"}">{$v.title}</a></li>
90 {/if}
91 {/foreach}
92 </ul>
93 </span>
94 </div>
95
96 <div class=crm-event-participants>
97 <span id="event-participants-{$row.id}" class="btn-slide crm-hover-button">{ts}Participants{/ts}
98 <ul class="panel" id="panel_participants_{$row.id}">
99 {if $findParticipants.statusCounted}
100 <li>
101 <a title="Counted" class="action-item crm-hover-button" href="{crmURL p='civicrm/event/search'
102 q="reset=1&force=1&status=true&event=`$row.id`"}">{$findParticipants.statusCounted}
103 </a>
104 </li>
105 {/if}
106 {if $findParticipants.statusNotCounted}
107 <li>
108 <a title="Not Counted" class="action-item crm-hover-button"
109 href="{crmURL p='civicrm/event/search'
110 q="reset=1&force=1&status=false&event=`$row.id`"}">{$findParticipants.statusNotCounted}
111 </a>
112 </li>
113 {/if}
114 {if $row.participant_listing_id}
115 <li>
116 <a title="Public Participant Listing" class="action-item crm-hover-button"
117 href="{crmURL p='civicrm/event/participant' q="reset=1&id=`$row.id`"
118 fe='true'}">{ts}Public Participant Listing{/ts}
119 </a>
120 </li>
121 {/if}
122 </ul>
123 </span>
124 </div>
125 <div class="crm-event-links">
126 {$row.eventlinks|replace:'xx':$row.id}
127 </div>
128 <div class="crm-event-more">
129 {$row.action|replace:'xx':$row.id}
130 </div>
131 </td>
132 <td class="crm-event-start_date hiddenElement">{$row.start_date|crmDate}</td>
133 <td class="crm-event-end_date hiddenElement">{$row.end_date|crmDate}</td>
134 </tr>
135 {/if}
136 {/foreach}
137 </table>
138 {include file="CRM/common/pager.tpl" location="bottom"}
139 {/strip}
140 </div>
141 {else}
142 {if $isSearch eq 1}
143 <div class="status messages">
144 <div class="icon inform-icon"></div>
145 {capture assign=browseURL}{crmURL p='civicrm/event/manage' q="reset=1"}{/capture}
146 {ts}No available Events match your search criteria. Suggestions:{/ts}
147 <div class="spacer"></div>
148 <ul>
149 <li>{ts}Check your spelling.{/ts}</li>
150 <li>{ts}Try "Search All or by Date Range".{/ts}</li>
151 <li>{ts}Try a different spelling or use fewer letters.{/ts}</li>
152 <li>{ts}Make sure you have enough privileges in the access control system.{/ts}</li>
153 </ul>
154 {ts 1=$browseURL}Or you can <a href='%1'>browse all available Current Events</a>.{/ts}
155 </div>
156 {else}
157 <div class="messages status no-popup">
158 <div class="icon inform-icon"></div>
159 {ts 1=$newEventURL}There are no events scheduled for the date range. You can <a href='%1'>add one</a>.{/ts}
160 </div>
161 {/if}
162 {/if}
163 </div>