source: trunk/admin/themes/default/template/configuration.tpl @ 11588

Last change on this file since 11588 was 11588, checked in by mistic100, 13 years ago

feature:2317 move order config to Admin->Config->Options
each drop-down menu is on a new line

  • Property svn:eol-style set to LF
File size: 15.2 KB
Line 
1
2{include file='include/autosize.inc.tpl'}
3
4<div class="titrePage">
5  <h2>{'Piwigo configuration'|@translate} {$TABSHEET_TITLE}</h2>
6</div>
7
8{if !isset($default)}
9<form method="post" action="{$F_ACTION}" class="properties">
10{/if}
11<div id="configContent">
12{if isset($main)}
13<fieldset id="mainConf">
14  <legend></legend>
15  <ul>
16    <li>
17      <span class="property">
18        <label for="gallery_title">{'Gallery title'|@translate}</label>
19      </span>
20      <input type="text" maxlength="255" size="50" name="gallery_title" id="gallery_title" value="{$main.CONF_GALLERY_TITLE}">
21    </li>
22
23    <li>
24      <span class="property">
25        <label for="page_banner">{'Page banner'|@translate}</label>
26      </span>
27      <textarea rows="5" cols="50" class="description" name="page_banner" id="page_banner">{$main.CONF_PAGE_BANNER}</textarea>
28    </li>
29
30    <li>
31      <span class="property">
32        <label for="gallery_url">{'Gallery URL'|@translate}</label>
33      </span>
34      <input type="text" maxlength="255" size="50" name="gallery_url" id="gallery_url" value="{$main.CONF_GALLERY_URL}">
35    </li>
36  </ul>
37</fieldset>
38
39<fieldset id="mainConfCheck">
40  <legend></legend>
41  <ul>
42    <li>
43      <label>
44        <span class="property">{'Lock gallery'|@translate}</span>
45        <input type="checkbox" name="gallery_locked" {if ($main.gallery_locked)}checked="checked"{/if}>
46      </label>
47    </li>
48
49    <li>
50      <label>
51        <span class="property">{'Allow rating'|@translate}</span>
52        <input type="checkbox" name="rate" {if ($main.rate)}checked="checked"{/if}>
53      </label>
54    </li>
55
56    <li>
57      <label>
58        <span class="property">{'Rating by guests'|@translate}</span>
59        <input type="checkbox" name="rate_anonymous" {if ($main.rate_anonymous)}checked="checked"{/if}>
60      </label>
61    </li>
62
63    <li>
64      <label>
65        <span class="property">{'Allow user registration'|@translate}</span>
66        <input type="checkbox" name="allow_user_registration" {if ($main.allow_user_registration)}checked="checked"{/if}>
67      </label>
68    </li>
69
70    <li>
71      <label>
72        <span class="property">{'Allow user customization'|@translate}</span>
73        <input type="checkbox" name="allow_user_customization" {if ($main.allow_user_customization)}checked="checked"{/if}>
74      </label>
75    </li>
76
77    <li>
78      <label>
79        <span class="property">{'Mail address is obligatory for all users'|@translate}</span>
80        <input type="checkbox" name="obligatory_user_mail_address" {if ($main.obligatory_user_mail_address)}checked="checked"{/if}>
81      </label>
82    </li>
83
84    <li>
85      <label>
86        <span class="property">{'Email admins when a new user registers'|@translate}</span>
87        <input type="checkbox" name="email_admin_on_new_user" {if ($main.email_admin_on_new_user)}checked="checked"{/if}>
88      </label>
89    </li>
90
91    <li>
92      &nbsp;
93      <span class="property">
94        {'Week starts on'|@translate}
95        {html_options name="week_starts_on" options=$main.week_starts_on_options selected=$main.week_starts_on_options_selected}
96      </span>
97    </li>
98   
99    <li style="margin-top:20px;">
100      &nbsp;
101      <span class="property">
102        {'Default photos order'|@translate}
103       
104        {foreach from=$main.order_by item=order}
105        <span class="filter {if $ORDER_BY_IS_CUSTOM}transparent{/if}">         
106          <select name="order_by_field[]" {if $ORDER_BY_IS_CUSTOM}disabled{/if}>
107            {html_options options=$main.order_field_options selected=$order.FIELD }
108          </select>
109          <select name="order_by_direction[]" {if $ORDER_BY_IS_CUSTOM}disabled{/if}>
110            {html_options options=$main.order_direction_options selected=$order.DIRECTION }
111          </select> 
112          <a class="removeFilter">{'delete'|@translate}</a>
113        </span>
114        {/foreach}
115       
116        {if !$ORDER_BY_IS_CUSTOM}
117          <a class="addFilter">{'Add a criteria'|@translate}</a>
118        {else}
119          <span class="order_by_is_custom">{'You can\'t define a default photo order because you have a custom setting in your local configuration.'|@translate}</span>
120        {/if}
121      </span>
122    </li>
123   
124{if !$ORDER_BY_IS_CUSTOM}
125{footer_script require='jquery'}{literal}
126jQuery(document).ready(function () {
127  $('.addFilter').click(function() {
128    rel = $(this).attr('rel');
129    $(this).prev('span.filter').clone().insertBefore($(this));
130    $(this).prev('span.filter').children('select[name="order_by_field[]"]').val('');
131    $(this).prev('span.filter').children('select[name="order_by_direction[]"]').val('ASC');
132     
133    $(".removeFilter").click(function () {
134      $(this).parent('span.filter').remove();
135    });
136  });
137 
138  $(".removeFilter").click(function () {
139    $(this).parent('span.filter').remove();
140  });
141});
142{/literal}{/footer_script}
143{/if}
144  </ul>
145</fieldset>
146{/if}
147
148{if isset($history)}
149<fieldset id="historyConf">
150  <legend></legend>
151  <ul>
152      <li>
153        <label><span class="property">{'Save page visits by guests'|@translate}</span><input type="checkbox" name="history_guest" {if ($history.history_guest)}checked="checked"{/if}></label>
154      </li>
155
156      <li>
157        <label><span class="property">{'Save page visits by users'|@translate}</span><input type="checkbox" name="log" {if ($history.log)}checked="checked"{/if}></label>
158      </li>
159
160      <li>
161        <label><span class="property">{'Save page visits by administrators'|@translate}</span><input type="checkbox" name="history_admin" {if ($history.history_admin)}checked="checked"{/if}></label>
162      </li>
163  </ul>
164</fieldset>
165{/if}
166
167{if isset($comments)}
168<fieldset id="commentsConf">
169  <legend></legend>
170  <ul>
171    <li>
172      <label>
173        <span class="property">{'Comments for all'|@translate}</span>
174        <input type="checkbox" name="comments_forall" {if ($comments.comments_forall)}checked="checked"{/if}>
175      </label>
176    </li>
177
178    <li>
179      <span class="property">
180        <label for="nb_comment_page">{'Number of comments per page'|@translate}</label>
181      </span>
182      <input type="text" size="3" maxlength="4" name="nb_comment_page" id="nb_comment_page" value="{$comments.NB_COMMENTS_PAGE}">
183    </li>
184
185    <li>
186      <label>
187        <span class="property">{'Validation'|@translate}</span>
188        <input type="checkbox" name="comments_validation" {if ($comments.comments_validation)}checked="checked"{/if}>
189      </label>
190    </li>
191
192    <li>
193      <label>
194        <span class="property">{'Email admins when a valid comment is entered'|@translate}</span>
195        <input type="checkbox" name="email_admin_on_comment" {if ($comments.email_admin_on_comment)}checked="checked"{/if}>
196      </label>
197    </li>
198
199    <li>
200      <label>
201        <span class="property">{'Email admins when a comment requires validation'|@translate}</span>
202        <input type="checkbox" name="email_admin_on_comment_validation" {if ($comments.email_admin_on_comment_validation)}checked="checked"{/if}>
203      </label>
204    </li>
205
206    <li>
207      <label>
208        <span class="property">{'Allow users to edit their own comments'|@translate}</span>
209        <input type="checkbox" name="user_can_edit_comment" {if ($comments.user_can_edit_comment)}checked="checked"{/if}>
210      </label>
211    </li>
212    <li>
213      <label>
214        <span class="property">{'Allow users to delete their own comments'|@translate}</span>
215        <input type="checkbox" name="user_can_delete_comment" {if ($comments.user_can_delete_comment)}checked="checked"{/if}>
216      </label>
217    </li>
218    <li>
219      <label>
220        <span class="property">{'Email administrators when a comment is modified'|@translate}</span>
221        <input type="checkbox" name="email_admin_on_comment_edition" {if ($comments.email_admin_on_comment_edition)}checked="checked"{/if}>
222      </label>
223    </li>
224    <li>
225      <label>
226        <span class="property">{'Email administrators when a comment is deleted'|@translate}</span>
227        <input type="checkbox" name="email_admin_on_comment_deletion" {if ($comments.email_admin_on_comment_deletion)}checked="checked"{/if}>
228      </label>
229    </li>
230
231  </ul>
232</fieldset>
233{/if}
234
235</div> <!-- configContent -->
236
237{if isset($default)}
238{$PROFILE_CONTENT}
239{/if}
240
241{if isset($display)}
242<fieldset id="indexDisplayConf">
243  <legend>{'Main Page'|@translate}</legend>
244  <ul>
245    <li>
246      <label>
247        <span class="property">{'display only recently posted photos'|@translate|@ucfirst|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
248        <input type="checkbox" name="menubar_filter_icon" {if ($display.menubar_filter_icon)}checked="checked"{/if}>
249      </label>
250    </li>   
251   
252    <li>
253      <label>
254        <span class="property">{'Activate icon "new" next to albums and pictures'|@translate}</span>
255        <input type="checkbox" name="index_new_icon" {if ($display.index_new_icon)}checked="checked"{/if}>
256      </label>
257    </li>
258
259    <li>
260      <label>
261        <span class="property">{'Sort order'|@translate|@string_format:$pwg->l10n('Activate field "%s"')}</span>
262        <input type="checkbox" name="index_sort_order_input" {if ($display.index_sort_order_input)}checked="checked"{/if}>
263      </label>
264    </li>
265
266    <li>
267      <label>
268        <span class="property">{'display all photos in all sub-albums'|@translate|@ucfirst|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
269        <input type="checkbox" name="index_flat_icon" {if ($display.index_flat_icon)}checked="checked"{/if}>
270      </label>
271    </li>
272
273    <li>
274      <label>
275        <span class="property">{'display a calendar by posted date'|@translate|@ucfirst|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
276        <input type="checkbox" name="index_posted_date_icon" {if ($display.index_posted_date_icon)}checked="checked"{/if}>
277      </label>
278    </li>
279
280    <li>
281      <label>
282        <span class="property">{'display a calendar by creation date'|@translate|@ucfirst|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
283        <input type="checkbox" name="index_created_date_icon" {if ($display.index_created_date_icon)}checked="checked"{/if}>
284      </label>
285    </li>
286
287    <li>
288      <label>
289        <span class="property">{'slideshow'|@translate|@ucfirst|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
290        <input type="checkbox" name="index_slideshow_icon" {if ($display.index_slideshow_icon)}checked="checked"{/if}>
291      </label>
292    </li>
293  </ul>
294</fieldset>
295
296<fieldset id="pictureDisplayConf">
297  <legend>{'Photo Page'|@translate}</legend>
298  <ul>
299    <li>
300      <label>
301        <span class="property">{'slideshow'|@translate|@ucfirst|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
302        <input type="checkbox" name="picture_slideshow_icon" {if ($display.picture_slideshow_icon)}checked="checked"{/if}>
303      </label>
304    </li>
305
306    <li>
307      <label>
308        <span class="property">{'Show file metadata'|@translate|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
309        <input type="checkbox" name="picture_metadata_icon" {if ($display.picture_metadata_icon)}checked="checked"{/if}>
310      </label>
311    </li>
312
313    <li>
314      <label>
315        <span class="property">{'download this file'|@translate|@ucfirst|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
316        <input type="checkbox" name="picture_download_icon" {if ($display.picture_download_icon)}checked="checked"{/if}>
317      </label>
318    </li>
319
320    <li>
321      <label>
322        <span class="property">{'add this photo to your favorites'|@translate|@ucfirst|@string_format:$pwg->l10n('Activate icon "%s"')}</span>
323        <input type="checkbox" name="picture_favorite_icon" {if ($display.picture_favorite_icon)}checked="checked"{/if}>
324      </label>
325    </li>
326
327    <li>
328      <label>
329        <span class="property">{'Activate Navigation Bar'|@translate}</span>
330        <input type="checkbox" name="picture_navigation_icons" {if ($display.picture_navigation_icons)}checked="checked"{/if}>
331      </label>
332    </li>
333
334    <li>
335      <label>
336        <span class="property">{'Activate Navigation Thumbnails'|@translate}</span>
337        <input type="checkbox" name="picture_navigation_thumb" {if ($display.picture_navigation_thumb)}checked="checked"{/if}>
338      </label>
339    </li>
340   
341    <li>
342      <label>
343        <span class="property">{'Show menubar'|@translate}</span>
344        <input type="checkbox" name="picture_menu" {if ($display.picture_menu)}checked="checked"{/if}>
345      </label>
346    </li>
347  </ul>
348</fieldset>
349
350<fieldset id="pictureInfoConf">
351  <legend>{'Photo Properties'|@translate}</legend>
352  <ul>
353    <li>
354      <label>
355        <span class="property">{'Author'|@translate}</span>
356        <input type="checkbox" name="picture_informations[author]" {if ($display.picture_informations.author)}checked="checked"{/if}>
357      </label>
358    </li>
359
360    <li>
361      <label>
362        <span class="property">{'Created on'|@translate}</span>
363        <input type="checkbox" name="picture_informations[created_on]" {if ($display.picture_informations.created_on)}checked="checked"{/if}>
364      </label>
365    </li>
366
367    <li>
368      <label>
369        <span class="property">{'Posted on'|@translate}</span>
370        <input type="checkbox" name="picture_informations[posted_on]" {if ($display.picture_informations.posted_on)}checked="checked"{/if}>
371      </label>
372    </li>
373
374    <li>
375      <label>
376        <span class="property">{'Dimensions'|@translate}</span>
377        <input type="checkbox" name="picture_informations[dimensions]" {if ($display.picture_informations.dimensions)}checked="checked"{/if}>
378      </label>
379    </li>
380
381    <li>
382      <label>
383        <span class="property">{'File'|@translate}</span>
384        <input type="checkbox" name="picture_informations[file]" {if ($display.picture_informations.file)}checked="checked"{/if}>
385      </label>
386    </li>
387
388    <li>
389      <label>
390        <span class="property">{'Filesize'|@translate}</span>
391        <input type="checkbox" name="picture_informations[filesize]" {if ($display.picture_informations.filesize)}checked="checked"{/if}>
392      </label>
393    </li>
394
395    <li>
396      <label>
397        <span class="property">{'Tags'|@translate}</span>
398        <input type="checkbox" name="picture_informations[tags]" {if ($display.picture_informations.tags)}checked="checked"{/if}>
399      </label>
400    </li>
401
402    <li>
403      <label>
404        <span class="property">{'Albums'|@translate}</span>
405        <input type="checkbox" name="picture_informations[categories]" {if ($display.picture_informations.categories)}checked="checked"{/if}>
406      </label>
407    </li>
408
409    <li>
410      <label>
411        <span class="property">{'Visits'|@translate}</span>
412        <input type="checkbox" name="picture_informations[visits]" {if ($display.picture_informations.visits)}checked="checked"{/if}>
413      </label>
414    </li>
415
416    <li>
417      <label>
418        <span class="property">{'Average rate'|@translate}</span>
419        <input type="checkbox" name="picture_informations[average_rate]" {if ($display.picture_informations.average_rate)}checked="checked"{/if}>
420      </label>
421    </li>
422
423    <li>
424      <label>
425        <span class="property">{'Who can see this photo?'|@translate} ({'available for administrators only'|@translate})</span>
426        <input type="checkbox" name="picture_informations[privacy_level]" {if ($display.picture_informations.privacy_level)}checked="checked"{/if}>
427      </label>
428    </li>
429  </ul>
430</fieldset>
431{/if}
432
433{if !isset($default)}
434  <p>
435    <input class="submit" type="submit" name="submit" value="{'Submit'|@translate}">
436    <input class="submit" type="reset" name="reset" value="{'Reset'|@translate}">
437  </p>
438</form>
439{/if}
Note: See TracBrowser for help on using the repository browser.