1 | {combine_script id='LocalStorageCache' load='footer' path='admin/themes/default/js/LocalStorageCache.js'} |
---|
2 | |
---|
3 | {assign var="selectizeTheme" value=($themeconf.name=='roma')|ternary:'dark':'default'} |
---|
4 | {combine_script id='jquery.selectize' load='footer' path='themes/default/js/plugins/selectize.min.js'} |
---|
5 | {combine_css id='jquery.selectize' path="themes/default/js/plugins/selectize.`$selectizeTheme`.css"} |
---|
6 | |
---|
7 | {footer_script} |
---|
8 | {* <!-- CATEGORIES --> *} |
---|
9 | var categoriesCache = new CategoriesCache({ |
---|
10 | serverKey: '{$CACHE_KEYS.categories}', |
---|
11 | serverId: '{$CACHE_KEYS._hash}', |
---|
12 | rootUrl: '{$ROOT_URL}' |
---|
13 | }); |
---|
14 | |
---|
15 | categoriesCache.selectize(jQuery('[data-selectize=categories]'), { |
---|
16 | default: 0, |
---|
17 | filter: function(categories, options) { |
---|
18 | // remove itself and children |
---|
19 | var filtered = jQuery.grep(categories, function(cat) { |
---|
20 | return !(/\b{$CAT_ID}\b/.test(cat.uppercats)); |
---|
21 | }); |
---|
22 | |
---|
23 | filtered.push({ |
---|
24 | id: 0, |
---|
25 | fullname: '------------', |
---|
26 | global_rank: 0 |
---|
27 | }); |
---|
28 | |
---|
29 | return filtered; |
---|
30 | } |
---|
31 | }); |
---|
32 | {/footer_script} |
---|
33 | |
---|
34 | |
---|
35 | <div class="titrePage"> |
---|
36 | <h2><span style="letter-spacing:0">{$CATEGORIES_NAV}</span> › {'Edit album'|@translate} {$TABSHEET_TITLE}</h2> |
---|
37 | </div> |
---|
38 | |
---|
39 | <form action="{$F_ACTION}" method="POST" id="catModify"> |
---|
40 | |
---|
41 | <fieldset> |
---|
42 | <legend>{'Informations'|@translate}</legend> |
---|
43 | |
---|
44 | <table style="width:100%"> |
---|
45 | <tr> |
---|
46 | <td id="albumThumbnail"> |
---|
47 | {if isset($representant) } |
---|
48 | {if isset($representant.picture) } |
---|
49 | <a href="{$representant.picture.URL}"><img src="{$representant.picture.SRC}" alt=""></a> |
---|
50 | {else} |
---|
51 | <img src="{$ROOT_URL}{$themeconf.admin_icon_dir}/category_representant_random.png" alt="{'Random photo'|@translate}"> |
---|
52 | {/if} |
---|
53 | |
---|
54 | {if $representant.ALLOW_SET_RANDOM } |
---|
55 | <p style="text-align:center;"><input class="submit" type="submit" name="set_random_representant" value="{'Refresh'|@translate}" title="{'Find a new representant by random'|@translate}"></p> |
---|
56 | {/if} |
---|
57 | |
---|
58 | {if isset($representant.ALLOW_DELETE) } |
---|
59 | <p><input class="submit" type="submit" name="delete_representant" value="{'Delete Representant'|@translate}"></p> |
---|
60 | {/if} |
---|
61 | {/if} |
---|
62 | </td> |
---|
63 | |
---|
64 | <td id="albumLinks"> |
---|
65 | <p>{$INTRO}</p> |
---|
66 | <ul> |
---|
67 | {if cat_admin_access($CAT_ID)} |
---|
68 | <li><a class="icon-eye" href="{$U_JUMPTO}">{'jump to album'|@translate} →</a></li> |
---|
69 | {/if} |
---|
70 | |
---|
71 | {if isset($U_MANAGE_ELEMENTS) } |
---|
72 | <li><a class="icon-picture" href="{$U_MANAGE_ELEMENTS}">{'manage album photos'|@translate}</a></li> |
---|
73 | {/if} |
---|
74 | |
---|
75 | <li style="text-transform:lowercase;"><a class="icon-plus-circled" href="{$U_ADD_PHOTOS_ALBUM}">{'Add Photos'|translate}</a></li> |
---|
76 | |
---|
77 | <li><a class="icon-sitemap" href="{$U_CHILDREN}">{'manage sub-albums'|@translate}</a></li> |
---|
78 | |
---|
79 | {if isset($U_SYNC) } |
---|
80 | <li><a class="icon-exchange" href="{$U_SYNC}">{'Synchronize'|@translate}</a> ({'Directory'|@translate} = {$CAT_FULL_DIR})</li> |
---|
81 | {/if} |
---|
82 | |
---|
83 | {if isset($U_DELETE) } |
---|
84 | <li><a class="icon-trash" href="{$U_DELETE}" onclick="return confirm('{'Are you sure?'|@translate|@escape:javascript}');">{'delete album'|@translate}</a></li> |
---|
85 | {/if} |
---|
86 | |
---|
87 | </ul> |
---|
88 | </td> |
---|
89 | </tr> |
---|
90 | </table> |
---|
91 | |
---|
92 | </fieldset> |
---|
93 | |
---|
94 | <fieldset> |
---|
95 | <legend>{'Properties'|@translate}</legend> |
---|
96 | <p> |
---|
97 | <strong>{'Name'|@translate}</strong> |
---|
98 | <br> |
---|
99 | <input type="text" class="large" name="name" value="{$CAT_NAME}" maxlength="255"> |
---|
100 | </p> |
---|
101 | |
---|
102 | <p> |
---|
103 | <strong>{'Description'|@translate}</strong> |
---|
104 | <br> |
---|
105 | <textarea cols="50" rows="5" name="comment" id="comment" class="description">{$CAT_COMMENT}</textarea> |
---|
106 | </p> |
---|
107 | |
---|
108 | {if isset($parent_category) } |
---|
109 | <p> |
---|
110 | <strong>{'Parent album'|@translate}</strong> |
---|
111 | <br> |
---|
112 | <select data-selectize="categories" data-value="{$parent_category|@json_encode|escape:html}" |
---|
113 | name="parent" style="width:400px"></select> |
---|
114 | </p> |
---|
115 | {/if} |
---|
116 | |
---|
117 | <p> |
---|
118 | <strong>{'Lock'|@translate}</strong> |
---|
119 | <br> |
---|
120 | {html_radios name='visible' values=['true','false'] output=['No'|translate,'Yes'|translate] selected=$CAT_VISIBLE} |
---|
121 | </p> |
---|
122 | |
---|
123 | {if isset($CAT_COMMENTABLE)} |
---|
124 | <p> |
---|
125 | <strong>{'Comments'|@translate}</strong> |
---|
126 | <br> |
---|
127 | {html_radios name='commentable' values=['false','true'] output=['No'|translate,'Yes'|translate] selected=$CAT_COMMENTABLE} |
---|
128 | </p> |
---|
129 | {/if} |
---|
130 | |
---|
131 | <p style="margin:0"> |
---|
132 | <input class="submit" type="submit" value="{'Save Settings'|@translate}" name="submit"> |
---|
133 | </p> |
---|
134 | </fieldset> |
---|
135 | |
---|
136 | </form> |
---|