1 | {include file='include/tag_selection.inc.tpl'} |
---|
2 | {include file='include/datepicker.inc.tpl'} |
---|
3 | {include file='include/colorbox.inc.tpl'} |
---|
4 | {include file='include/add_album.inc.tpl'} |
---|
5 | |
---|
6 | {combine_script id='common' load='footer' path='admin/themes/default/js/common.js'} |
---|
7 | {combine_script id='jquery.ui.slider' require='jquery.ui' load='footer' path='themes/default/js/ui/minified/jquery.ui.slider.min.js'} |
---|
8 | {combine_css path="themes/default/js/ui/theme/jquery.ui.slider.css"} |
---|
9 | |
---|
10 | {footer_script}{literal} |
---|
11 | pwg_initialization_datepicker("#date_creation_day", "#date_creation_month", "#date_creation_year", "#date_creation_linked_date", "#date_creation_action_set"); |
---|
12 | {/literal}{/footer_script} |
---|
13 | |
---|
14 | {footer_script}{literal} |
---|
15 | /* Shift-click: select all photos between the click and the shift+click */ |
---|
16 | jQuery(document).ready(function() { |
---|
17 | var last_clicked=0; |
---|
18 | var last_clickedstatus=true; |
---|
19 | jQuery.fn.enableShiftClick = function() { |
---|
20 | var inputs = []; |
---|
21 | var count=0; |
---|
22 | this.find('input[type=checkbox]').each(function() { |
---|
23 | var pos=count; |
---|
24 | inputs[count++]=this; |
---|
25 | $(this).bind("shclick", function (dummy,event) { |
---|
26 | if (event.shiftKey) { |
---|
27 | var first = last_clicked; |
---|
28 | var last = pos; |
---|
29 | if (first > last) { |
---|
30 | first=pos; |
---|
31 | last=last_clicked; |
---|
32 | } |
---|
33 | |
---|
34 | for (var i=first; i<=last;i++) { |
---|
35 | input = $(inputs[i]); |
---|
36 | $(input).prop('checked', last_clickedstatus); |
---|
37 | if (last_clickedstatus) |
---|
38 | { |
---|
39 | $(input).siblings("span.wrap2").addClass("thumbSelected"); |
---|
40 | } |
---|
41 | else |
---|
42 | { |
---|
43 | $(input).siblings("span.wrap2").removeClass("thumbSelected"); |
---|
44 | } |
---|
45 | } |
---|
46 | } |
---|
47 | else { |
---|
48 | last_clicked = pos; |
---|
49 | last_clickedstatus = this.checked; |
---|
50 | } |
---|
51 | return true; |
---|
52 | }); |
---|
53 | $(this).click(function(event) { $(this).triggerHandler("shclick",event)}); |
---|
54 | }); |
---|
55 | } |
---|
56 | $('ul.thumbnails').enableShiftClick(); |
---|
57 | }); |
---|
58 | {/literal}{/footer_script} |
---|
59 | |
---|
60 | {combine_css path='themes/default/js/plugins/jquery.tokeninput.css'} |
---|
61 | {combine_script id='jquery.tokeninput' load='footer' require='jquery' path='themes/default/js/plugins/jquery.tokeninput.js'} |
---|
62 | {combine_script id='jquery.progressBar' load='footer' path='themes/default/js/plugins/jquery.progressbar.min.js'} |
---|
63 | {combine_script id='jquery.ajaxmanager' load='footer' path='themes/default/js/plugins/jquery.ajaxmanager.js'} |
---|
64 | |
---|
65 | {footer_script require='jquery.tokeninput'} |
---|
66 | jQuery(document).ready(function() {ldelim} |
---|
67 | jQuery("a.preview-box").colorbox(); |
---|
68 | |
---|
69 | var tag_src = [{foreach from=$tags item=tag name=tags}{ldelim}name:"{$tag.name|@escape:'javascript'}",id:"{$tag.id}"{rdelim}{if !$smarty.foreach.tags.last},{/if}{/foreach}]; |
---|
70 | jQuery("#tags").tokenInput( |
---|
71 | tag_src, |
---|
72 | {ldelim} |
---|
73 | hintText: '{'Type in a search term'|@translate}', |
---|
74 | noResultsText: '{'No results'|@translate}', |
---|
75 | searchingText: '{'Searching...'|@translate}', |
---|
76 | newText: ' ({'new'|@translate})', |
---|
77 | animateDropdown: false, |
---|
78 | preventDuplicates: true, |
---|
79 | allowFreeTagging: true |
---|
80 | } |
---|
81 | ); |
---|
82 | |
---|
83 | jQuery("#tagsFilter").tokenInput( |
---|
84 | tag_src, |
---|
85 | {ldelim} |
---|
86 | hintText: '{'Type in a search term'|@translate}', |
---|
87 | noResultsText: '{'No results'|@translate}', |
---|
88 | searchingText: '{'Searching...'|@translate}', |
---|
89 | animateDropdown: false, |
---|
90 | preventDuplicates: true, |
---|
91 | allowFreeTagging: false |
---|
92 | } |
---|
93 | ); |
---|
94 | |
---|
95 | }); |
---|
96 | {/footer_script} |
---|
97 | |
---|
98 | {footer_script} |
---|
99 | var nb_thumbs_page = {$nb_thumbs_page}; |
---|
100 | var nb_thumbs_set = {$nb_thumbs_set}; |
---|
101 | var are_you_sure = "{'Are you sure?'|@translate|@escape:'javascript'}"; |
---|
102 | var applyOnDetails_pattern = "{'on the %d selected photos'|@translate}"; |
---|
103 | var all_elements = [{if !empty($all_elements)}{','|@implode:$all_elements}{/if}]; |
---|
104 | var derivatives = {ldelim} |
---|
105 | elements: null, |
---|
106 | done: 0, |
---|
107 | total: 0, |
---|
108 | |
---|
109 | finished: function() {ldelim} |
---|
110 | return derivatives.done == derivatives.total && derivatives.elements && derivatives.elements.length==0; |
---|
111 | } |
---|
112 | }; |
---|
113 | |
---|
114 | var selectedMessage_pattern = "{'%d of %d photos selected'|@translate}"; |
---|
115 | var selectedMessage_none = "{'No photo selected, %d photos in current set'|@translate}"; |
---|
116 | var selectedMessage_all = "{'All %d photos are selected'|@translate}"; |
---|
117 | |
---|
118 | var width_str = '{'Width'|@translate}'; |
---|
119 | var height_str = '{'Height'|@translate}'; |
---|
120 | var max_width_str = '{'Maximum width'|@translate}'; |
---|
121 | var max_height_str = '{'Maximum height'|@translate}'; |
---|
122 | {literal} |
---|
123 | |
---|
124 | function progress(success) { |
---|
125 | jQuery('#progressBar').progressBar(derivatives.done, { |
---|
126 | max: derivatives.total, |
---|
127 | textFormat: 'fraction', |
---|
128 | boxImage: 'themes/default/images/progressbar.gif', |
---|
129 | barImage: 'themes/default/images/progressbg_orange.gif' |
---|
130 | }); |
---|
131 | if (success !== undefined) { |
---|
132 | var type = success ? 'regenerateSuccess': 'regenerateError', |
---|
133 | s = jQuery('[name="'+type+'"]').val(); |
---|
134 | jQuery('[name="'+type+'"]').val(++s); |
---|
135 | } |
---|
136 | |
---|
137 | if (derivatives.finished()) { |
---|
138 | jQuery('#applyAction').click(); |
---|
139 | } |
---|
140 | } |
---|
141 | |
---|
142 | $(document).ready(function() { |
---|
143 | function checkPermitAction() { |
---|
144 | var nbSelected = 0; |
---|
145 | if ($("input[name=setSelected]").is(':checked')) { |
---|
146 | nbSelected = nb_thumbs_set; |
---|
147 | } |
---|
148 | else { |
---|
149 | nbSelected = $(".thumbnails input[type=checkbox]").filter(':checked').length; |
---|
150 | } |
---|
151 | |
---|
152 | if (nbSelected == 0) { |
---|
153 | $("#permitAction").hide(); |
---|
154 | $("#forbidAction").show(); |
---|
155 | } |
---|
156 | else { |
---|
157 | $("#permitAction").show(); |
---|
158 | $("#forbidAction").hide(); |
---|
159 | } |
---|
160 | |
---|
161 | $("#applyOnDetails").text( |
---|
162 | sprintf( |
---|
163 | applyOnDetails_pattern, |
---|
164 | nbSelected |
---|
165 | ) |
---|
166 | ); |
---|
167 | |
---|
168 | // display the number of currently selected photos in the "Selection" fieldset |
---|
169 | if (nbSelected == 0) { |
---|
170 | $("#selectedMessage").text( |
---|
171 | sprintf( |
---|
172 | selectedMessage_none, |
---|
173 | nb_thumbs_set |
---|
174 | ) |
---|
175 | ); |
---|
176 | } |
---|
177 | else if (nbSelected == nb_thumbs_set) { |
---|
178 | $("#selectedMessage").text( |
---|
179 | sprintf( |
---|
180 | selectedMessage_all, |
---|
181 | nb_thumbs_set |
---|
182 | ) |
---|
183 | ); |
---|
184 | } |
---|
185 | else { |
---|
186 | $("#selectedMessage").text( |
---|
187 | sprintf( |
---|
188 | selectedMessage_pattern, |
---|
189 | nbSelected, |
---|
190 | nb_thumbs_set |
---|
191 | ) |
---|
192 | ); |
---|
193 | } |
---|
194 | } |
---|
195 | |
---|
196 | $('.thumbnails img').tipTip({ |
---|
197 | 'delay' : 0, |
---|
198 | 'fadeIn' : 200, |
---|
199 | 'fadeOut' : 200 |
---|
200 | }); |
---|
201 | |
---|
202 | $("[id^=action_]").hide(); |
---|
203 | |
---|
204 | $("select[name=selectAction]").change(function () { |
---|
205 | $("[id^=action_]").hide(); |
---|
206 | $("#action_"+$(this).prop("value")).show(); |
---|
207 | |
---|
208 | /* make sure the #albumSelect is on the right select box so that the */ |
---|
209 | /* "add new album" popup fills the right select box */ |
---|
210 | if ("associate" == $(this).prop("value") || "move" == $(this).prop("value")) { |
---|
211 | jQuery("#albumSelect").removeAttr("id"); |
---|
212 | jQuery("#action_"+$(this).prop("value")+" select").attr("id", "albumSelect"); |
---|
213 | } |
---|
214 | |
---|
215 | if ($(this).val() != -1) { |
---|
216 | $("#applyActionBlock").show(); |
---|
217 | } |
---|
218 | else { |
---|
219 | $("#applyActionBlock").hide(); |
---|
220 | } |
---|
221 | }); |
---|
222 | |
---|
223 | $(".wrap1 label").click(function (event) { |
---|
224 | $("input[name=setSelected]").prop('checked', false); |
---|
225 | |
---|
226 | var wrap2 = $(this).children(".wrap2"); |
---|
227 | var checkbox = $(this).children("input[type=checkbox]"); |
---|
228 | |
---|
229 | checkbox.triggerHandler("shclick",event); |
---|
230 | |
---|
231 | if ($(checkbox).is(':checked')) { |
---|
232 | $(wrap2).addClass("thumbSelected"); |
---|
233 | } |
---|
234 | else { |
---|
235 | $(wrap2).removeClass('thumbSelected'); |
---|
236 | } |
---|
237 | |
---|
238 | checkPermitAction(); |
---|
239 | }); |
---|
240 | |
---|
241 | $("#selectAll").click(function () { |
---|
242 | $("input[name=setSelected]").prop('checked', false); |
---|
243 | selectPageThumbnails(); |
---|
244 | checkPermitAction(); |
---|
245 | return false; |
---|
246 | }); |
---|
247 | |
---|
248 | function selectPageThumbnails() { |
---|
249 | $(".thumbnails label").each(function() { |
---|
250 | var wrap2 = $(this).children(".wrap2"); |
---|
251 | var checkbox = $(this).children("input[type=checkbox]"); |
---|
252 | |
---|
253 | $(checkbox).prop('checked', true); |
---|
254 | $(wrap2).addClass("thumbSelected"); |
---|
255 | }); |
---|
256 | } |
---|
257 | |
---|
258 | $("#selectNone").click(function () { |
---|
259 | $("input[name=setSelected]").prop('checked', false); |
---|
260 | |
---|
261 | $(".thumbnails label").each(function() { |
---|
262 | var wrap2 = $(this).children(".wrap2"); |
---|
263 | var checkbox = $(this).children("input[type=checkbox]"); |
---|
264 | |
---|
265 | $(checkbox).prop('checked', false); |
---|
266 | $(wrap2).removeClass("thumbSelected"); |
---|
267 | }); |
---|
268 | checkPermitAction(); |
---|
269 | return false; |
---|
270 | }); |
---|
271 | |
---|
272 | $("#selectInvert").click(function () { |
---|
273 | $("input[name=setSelected]").prop('checked', false); |
---|
274 | |
---|
275 | $(".thumbnails label").each(function() { |
---|
276 | var wrap2 = $(this).children(".wrap2"); |
---|
277 | var checkbox = $(this).children("input[type=checkbox]"); |
---|
278 | |
---|
279 | $(checkbox).prop('checked', !$(checkbox).is(':checked')); |
---|
280 | |
---|
281 | if ($(checkbox).is(':checked')) { |
---|
282 | $(wrap2).addClass("thumbSelected"); |
---|
283 | } |
---|
284 | else { |
---|
285 | $(wrap2).removeClass('thumbSelected'); |
---|
286 | } |
---|
287 | }); |
---|
288 | checkPermitAction(); |
---|
289 | return false; |
---|
290 | }); |
---|
291 | |
---|
292 | $("#selectSet").click(function () { |
---|
293 | selectPageThumbnails(); |
---|
294 | $("input[name=setSelected]").prop('checked', true); |
---|
295 | checkPermitAction(); |
---|
296 | return false; |
---|
297 | }); |
---|
298 | |
---|
299 | $("input[name=remove_author]").click(function () { |
---|
300 | if ($(this).is(':checked')) { |
---|
301 | $("input[name=author]").hide(); |
---|
302 | } |
---|
303 | else { |
---|
304 | $("input[name=author]").show(); |
---|
305 | } |
---|
306 | }); |
---|
307 | |
---|
308 | $("input[name=remove_title]").click(function () { |
---|
309 | if ($(this).is(':checked')) { |
---|
310 | $("input[name=title]").hide(); |
---|
311 | } |
---|
312 | else { |
---|
313 | $("input[name=title]").show(); |
---|
314 | } |
---|
315 | }); |
---|
316 | |
---|
317 | $("input[name=remove_date_creation]").click(function () { |
---|
318 | if ($(this).is(':checked')) { |
---|
319 | $("#set_date_creation").hide(); |
---|
320 | } |
---|
321 | else { |
---|
322 | $("#set_date_creation").show(); |
---|
323 | } |
---|
324 | }); |
---|
325 | |
---|
326 | $(".removeFilter").click(function () { |
---|
327 | var filter = $(this).parent('li').attr("id"); |
---|
328 | filter_disable(filter); |
---|
329 | |
---|
330 | return false; |
---|
331 | }); |
---|
332 | |
---|
333 | function filter_enable(filter) { |
---|
334 | /* show the filter*/ |
---|
335 | $("#"+filter).show(); |
---|
336 | |
---|
337 | /* check the checkbox to declare we use this filter */ |
---|
338 | $("input[type=checkbox][name="+filter+"_use]").prop("checked", true); |
---|
339 | |
---|
340 | /* forbid to select this filter in the addFilter list */ |
---|
341 | $("#addFilter").children("option[value="+filter+"]").attr("disabled", "disabled"); |
---|
342 | } |
---|
343 | |
---|
344 | $("#addFilter").change(function () { |
---|
345 | var filter = $(this).prop("value"); |
---|
346 | filter_enable(filter); |
---|
347 | $(this).prop("value", -1); |
---|
348 | }); |
---|
349 | |
---|
350 | function filter_disable(filter) { |
---|
351 | /* hide the filter line */ |
---|
352 | $("#"+filter).hide(); |
---|
353 | |
---|
354 | /* uncheck the checkbox to declare we do not use this filter */ |
---|
355 | $("input[name="+filter+"_use]").prop("checked", false); |
---|
356 | |
---|
357 | /* give the possibility to show it again */ |
---|
358 | $("#addFilter").children("option[value="+filter+"]").removeAttr("disabled"); |
---|
359 | } |
---|
360 | |
---|
361 | $("#removeFilters").click(function() { |
---|
362 | $("#filterList li").each(function() { |
---|
363 | var filter = $(this).attr("id"); |
---|
364 | filter_disable(filter); |
---|
365 | }); |
---|
366 | return false; |
---|
367 | }); |
---|
368 | |
---|
369 | jQuery('#applyAction').click(function() { |
---|
370 | var action = jQuery('[name="selectAction"]').val(); |
---|
371 | if (action == 'delete_derivatives') { |
---|
372 | var d_count = $('#action_delete_derivatives input[type=checkbox]').filter(':checked').length |
---|
373 | , e_count = $('input[name="setSelected"]').is(':checked') ? nb_thumbs_set : $('.thumbnails input[type=checkbox]').filter(':checked').length; |
---|
374 | if (d_count*e_count > 500) |
---|
375 | return confirm(are_you_sure); |
---|
376 | } |
---|
377 | |
---|
378 | if (action != 'generate_derivatives' |
---|
379 | || derivatives.finished() ) |
---|
380 | { |
---|
381 | return true; |
---|
382 | } |
---|
383 | |
---|
384 | jQuery('.bulkAction').hide(); |
---|
385 | |
---|
386 | var queuedManager = jQuery.manageAjax.create('queued', { |
---|
387 | queue: true, |
---|
388 | cacheResponse: false, |
---|
389 | maxRequests: 1 |
---|
390 | }); |
---|
391 | |
---|
392 | derivatives.elements = []; |
---|
393 | if (jQuery('input[name="setSelected"]').is(':checked')) |
---|
394 | derivatives.elements = all_elements; |
---|
395 | else |
---|
396 | jQuery('.thumbnails input[type=checkbox]').each(function() { |
---|
397 | if (jQuery(this).is(':checked')) { |
---|
398 | derivatives.elements.push(jQuery(this).val()); |
---|
399 | } |
---|
400 | }); |
---|
401 | |
---|
402 | jQuery('#applyActionBlock').hide(); |
---|
403 | jQuery('select[name="selectAction"]').hide(); |
---|
404 | jQuery('#regenerationMsg').show(); |
---|
405 | |
---|
406 | progress(); |
---|
407 | getDerivativeUrls(); |
---|
408 | return false; |
---|
409 | }); |
---|
410 | |
---|
411 | function getDerivativeUrls() { |
---|
412 | var ids = derivatives.elements.splice(0, 500); |
---|
413 | var params = {max_urls: 100000, ids: ids, types: []}; |
---|
414 | jQuery("#action_generate_derivatives input").each( function(i, t) { |
---|
415 | if ($(t).is(":checked")) |
---|
416 | params.types.push( t.value ); |
---|
417 | } ); |
---|
418 | |
---|
419 | jQuery.ajax( { |
---|
420 | type: "POST", |
---|
421 | url: 'ws.php?format=json&method=pwg.getMissingDerivatives', |
---|
422 | data: params, |
---|
423 | dataType: "json", |
---|
424 | success: function(data) { |
---|
425 | if (!data.stat || data.stat != "ok") { |
---|
426 | return; |
---|
427 | } |
---|
428 | derivatives.total += data.result.urls.length; |
---|
429 | progress(); |
---|
430 | for (var i=0; i < data.result.urls.length; i++) { |
---|
431 | jQuery.manageAjax.add("queued", { |
---|
432 | type: 'GET', |
---|
433 | url: data.result.urls[i] + "&ajaxload=true", |
---|
434 | dataType: 'json', |
---|
435 | success: ( function(data) { derivatives.done++; progress(true) }), |
---|
436 | error: ( function(data) { derivatives.done++; progress(false) }) |
---|
437 | }); |
---|
438 | } |
---|
439 | if (derivatives.elements.length) |
---|
440 | setTimeout( getDerivativeUrls, 25 * (derivatives.total-derivatives.done)); |
---|
441 | } |
---|
442 | } ); |
---|
443 | } |
---|
444 | |
---|
445 | checkPermitAction(); |
---|
446 | |
---|
447 | /* dimensions sliders */ |
---|
448 | /** |
---|
449 | * find the key from a value in the startStopValues array |
---|
450 | */ |
---|
451 | function getSliderKeyFromValue(value, values) { |
---|
452 | for (var key in values) { |
---|
453 | if (values[key] == value) { |
---|
454 | return key; |
---|
455 | } |
---|
456 | } |
---|
457 | |
---|
458 | return 0; |
---|
459 | } |
---|
460 | |
---|
461 | {/literal} |
---|
462 | var dimension_values = {ldelim} |
---|
463 | 'width':[{$dimensions.widths}], |
---|
464 | 'height':[{$dimensions.heights}], |
---|
465 | 'ratio':[{$dimensions.ratios}] |
---|
466 | }; |
---|
467 | |
---|
468 | $("#filter_dimension_width_slider").slider({ldelim} |
---|
469 | range: true, |
---|
470 | min: 0, |
---|
471 | max: dimension_values['width'].length - 1, |
---|
472 | values: [ |
---|
473 | getSliderKeyFromValue({$dimensions.selected.min_width}, dimension_values['width']), |
---|
474 | getSliderKeyFromValue({$dimensions.selected.max_width}, dimension_values['width']) |
---|
475 | ], |
---|
476 | slide: function(event, ui) {ldelim} |
---|
477 | $("input[name='filter_dimension_min_width']").val(dimension_values['width'][ui.values[0]]); |
---|
478 | $("input[name='filter_dimension_max_width']").val(dimension_values['width'][ui.values[1]]); |
---|
479 | |
---|
480 | $("#filter_dimension_width_info").html(sprintf( |
---|
481 | "{'between %d and %d pixels'|@translate}", |
---|
482 | dimension_values['width'][ui.values[0]], |
---|
483 | dimension_values['width'][ui.values[1]] |
---|
484 | )); |
---|
485 | }, |
---|
486 | change: function(event, ui) {ldelim} |
---|
487 | $("input[name='filter_dimension_min_width']").val(dimension_values['width'][ui.values[0]]); |
---|
488 | $("input[name='filter_dimension_max_width']").val(dimension_values['width'][ui.values[1]]); |
---|
489 | |
---|
490 | $("#filter_dimension_width_info").html(sprintf( |
---|
491 | "{'between %d and %d pixels'|@translate}", |
---|
492 | dimension_values['width'][ui.values[0]], |
---|
493 | dimension_values['width'][ui.values[1]] |
---|
494 | )); |
---|
495 | } |
---|
496 | }); |
---|
497 | |
---|
498 | $("#filter_dimension_height_slider").slider({ldelim} |
---|
499 | range: true, |
---|
500 | min: 0, |
---|
501 | max: dimension_values['height'].length - 1, |
---|
502 | values: [ |
---|
503 | getSliderKeyFromValue({$dimensions.selected.min_height}, dimension_values['height']), |
---|
504 | getSliderKeyFromValue({$dimensions.selected.max_height}, dimension_values['height']) |
---|
505 | ], |
---|
506 | slide: function(event, ui) {ldelim} |
---|
507 | $("input[name='filter_dimension_min_height']").val(dimension_values['height'][ui.values[0]]); |
---|
508 | $("input[name='filter_dimension_max_height']").val(dimension_values['height'][ui.values[1]]); |
---|
509 | |
---|
510 | $("#filter_dimension_height_info").html(sprintf( |
---|
511 | "{'between %d and %d pixels'|@translate}", |
---|
512 | dimension_values['height'][ui.values[0]], |
---|
513 | dimension_values['height'][ui.values[1]] |
---|
514 | )); |
---|
515 | }, |
---|
516 | change: function(event, ui) {ldelim} |
---|
517 | $("input[name='filter_dimension_min_height']").val(dimension_values['height'][ui.values[0]]); |
---|
518 | $("input[name='filter_dimension_max_height']").val(dimension_values['height'][ui.values[1]]); |
---|
519 | |
---|
520 | $("#filter_dimension_height_info").html(sprintf( |
---|
521 | "{'between %d and %d pixels'|@translate}", |
---|
522 | dimension_values['height'][ui.values[0]], |
---|
523 | dimension_values['height'][ui.values[1]] |
---|
524 | )); |
---|
525 | } |
---|
526 | }); |
---|
527 | |
---|
528 | $("#filter_dimension_ratio_slider").slider({ldelim} |
---|
529 | range: true, |
---|
530 | min: 0, |
---|
531 | max: dimension_values['ratio'].length - 1, |
---|
532 | values: [ |
---|
533 | getSliderKeyFromValue({$dimensions.selected.min_ratio}, dimension_values['ratio']), |
---|
534 | getSliderKeyFromValue({$dimensions.selected.max_ratio}, dimension_values['ratio']) |
---|
535 | ], |
---|
536 | slide: function(event, ui) {ldelim} |
---|
537 | $("input[name='filter_dimension_min_ratio']").val(dimension_values['ratio'][ui.values[0]]); |
---|
538 | $("input[name='filter_dimension_max_ratio']").val(dimension_values['ratio'][ui.values[1]]); |
---|
539 | |
---|
540 | $("#filter_dimension_ratio_info").html(sprintf( |
---|
541 | "{'between %.2f and %.2f'|@translate}", |
---|
542 | dimension_values['ratio'][ui.values[0]], |
---|
543 | dimension_values['ratio'][ui.values[1]] |
---|
544 | )); |
---|
545 | }, |
---|
546 | change: function(event, ui) {ldelim} |
---|
547 | $("input[name='filter_dimension_min_ratio']").val(dimension_values['ratio'][ui.values[0]]); |
---|
548 | $("input[name='filter_dimension_max_ratio']").val(dimension_values['ratio'][ui.values[1]]); |
---|
549 | |
---|
550 | $("#filter_dimension_ratio_info").html(sprintf( |
---|
551 | "{'between %.2f and %.2f'|@translate}", |
---|
552 | dimension_values['ratio'][ui.values[0]], |
---|
553 | dimension_values['ratio'][ui.values[1]] |
---|
554 | )); |
---|
555 | } |
---|
556 | }); |
---|
557 | |
---|
558 | $("a.dimensions-choice").click(function() {ldelim} |
---|
559 | var type = jQuery(this).data("type"); |
---|
560 | var min = jQuery(this).data("min"); |
---|
561 | var max = jQuery(this).data("max"); |
---|
562 | |
---|
563 | $("#filter_dimension_"+ type +"_slider").slider("values", 0, |
---|
564 | getSliderKeyFromValue(min, dimension_values[type]) |
---|
565 | ); |
---|
566 | |
---|
567 | $("#filter_dimension_"+type+"_slider").slider("values", 1, |
---|
568 | getSliderKeyFromValue(max, dimension_values[type]) |
---|
569 | ); |
---|
570 | }); |
---|
571 | }); |
---|
572 | |
---|
573 | {/footer_script} |
---|
574 | |
---|
575 | <div id="batchManagerGlobal"> |
---|
576 | |
---|
577 | <h2>{'Batch Manager'|@translate}</h2> |
---|
578 | |
---|
579 | <form action="{$F_ACTION}" method="post"> |
---|
580 | <input type="hidden" name="start" value="{$START}"> |
---|
581 | |
---|
582 | <fieldset> |
---|
583 | <legend>{'Filter'|@translate}</legend> |
---|
584 | |
---|
585 | <ul id="filterList"> |
---|
586 | <li id="filter_prefilter" {if !isset($filter.prefilter)}style="display:none"{/if}> |
---|
587 | <a href="#" class="removeFilter" title="{'remove this filter'|@translate}"><span>[x]</span></a> |
---|
588 | <input type="checkbox" name="filter_prefilter_use" class="useFilterCheckbox" {if isset($filter.prefilter)}checked="checked"{/if}> |
---|
589 | {'Predefined filter'|@translate} |
---|
590 | <select name="filter_prefilter"> |
---|
591 | {foreach from=$prefilters item=prefilter} |
---|
592 | <option value="{$prefilter.ID}" {if isset($filter.prefilter) && $filter.prefilter eq $prefilter.ID}selected="selected"{/if}>{$prefilter.NAME}</option> |
---|
593 | {/foreach} |
---|
594 | </select> |
---|
595 | </li> |
---|
596 | |
---|
597 | <li id="filter_category" {if !isset($filter.category)}style="display:none"{/if}> |
---|
598 | <a href="#" class="removeFilter" title="remove this filter"><span>[x]</span></a> |
---|
599 | <input type="checkbox" name="filter_category_use" class="useFilterCheckbox" {if isset($filter.category)}checked="checked"{/if}> |
---|
600 | {'Album'|@translate} |
---|
601 | <select style="width:400px" name="filter_category" size="1"> |
---|
602 | {html_options options=$category_full_name_options selected=$filter_category_selected} |
---|
603 | </select> |
---|
604 | <label><input type="checkbox" name="filter_category_recursive" {if isset($filter.category_recursive)}checked="checked"{/if}> {'include child albums'|@translate}</label> |
---|
605 | </li> |
---|
606 | |
---|
607 | <li id="filter_tags" {if !isset($filter.tags)}style="display:none"{/if}> |
---|
608 | <a href="#" class="removeFilter" title="remove this filter"><span>[x]</span></a> |
---|
609 | <input type="checkbox" name="filter_tags_use" class="useFilterCheckbox" {if isset($filter.tags)}checked="checked"{/if}> |
---|
610 | {'Tags'|@translate} |
---|
611 | <select id="tagsFilter" name="filter_tags"> |
---|
612 | {if isset($filter_tags)}{foreach from=$filter_tags item=tag} |
---|
613 | <option value="{$tag.id}">{$tag.name}</option> |
---|
614 | {/foreach}{/if} |
---|
615 | </select> |
---|
616 | <label><span><input type="radio" name="tag_mode" value="AND" {if !isset($filter.tag_mode) or $filter.tag_mode eq 'AND'}checked="checked"{/if}> {'All tags'|@translate}</span></label> |
---|
617 | <label><span><input type="radio" name="tag_mode" value="OR" {if isset($filter.tag_mode) and $filter.tag_mode eq 'OR'}checked="checked"{/if}> {'Any tag'|@translate}</span></label> |
---|
618 | </li> |
---|
619 | |
---|
620 | <li id="filter_level" {if !isset($filter.level)}style="display:none"{/if}> |
---|
621 | <a href="#" class="removeFilter" title="remove this filter"><span>[x]</span></a> |
---|
622 | <input type="checkbox" name="filter_level_use" class="useFilterCheckbox" {if isset($filter.level)}checked="checked"{/if}> |
---|
623 | {'Privacy level'|@translate} |
---|
624 | <select name="filter_level" size="1"> |
---|
625 | {html_options options=$filter_level_options selected=$filter_level_options_selected} |
---|
626 | </select> |
---|
627 | <label><input type="checkbox" name="filter_level_include_lower" {if isset($filter.level_include_lower)}checked="checked"{/if}> {'include photos with lower privacy level'|@translate}</label> |
---|
628 | </li> |
---|
629 | |
---|
630 | <li id="filter_dimension" {if !isset($filter.dimension)}style="display:none"{/if}> |
---|
631 | <a href="#" class="removeFilter" title="remove this filter"><span>[x]</span></a> |
---|
632 | <input type="checkbox" name="filter_dimension_use" class="useFilterCheckbox" {if isset($filter.dimension)}checked="checked"{/if}> |
---|
633 | {'Dimensions'|@translate} |
---|
634 | |
---|
635 | <blockquote> |
---|
636 | {'Width'|@translate} <span id="filter_dimension_width_info">{'between %d and %d pixels'|@translate:$dimensions.selected.min_width:$dimensions.selected.max_width}</span> |
---|
637 | | <a class="dimensions-choice" data-type="width" data-min="{$dimensions.bounds.min_width}" data-max="{$dimensions.bounds.max_width}">{'Reset'|@translate}</a> |
---|
638 | <div id="filter_dimension_width_slider"></div> |
---|
639 | |
---|
640 | {'Height'|@translate} <span id="filter_dimension_height_info">{'between %d and %d pixels'|@translate:$dimensions.selected.min_height:$dimensions.selected.max_height}</span> |
---|
641 | | <a class="dimensions-choice" data-type="height" data-min="{$dimensions.bounds.min_height}" data-max="{$dimensions.bounds.max_height}">{'Reset'|@translate}</a> |
---|
642 | <div id="filter_dimension_height_slider"></div> |
---|
643 | |
---|
644 | {'Ratio'|@translate} ({'Width'|@translate}/{'Height'|@translate}) <span id="filter_dimension_ratio_info">{'between %.2f and %.2f'|@translate:$dimensions.selected.min_ratio:$dimensions.selected.max_ratio}</span> |
---|
645 | {if isset($dimensions.ratio_portrait)} |
---|
646 | | <a class="dimensions-choice" data-type="ratio" data-min="{$dimensions.ratio_portrait.min}" data-max="{$dimensions.ratio_portrait.max}">{'Portrait'|@translate}</a> |
---|
647 | {/if} |
---|
648 | {if isset($dimensions.ratio_square)} |
---|
649 | | <a class="dimensions-choice" data-type="ratio" data-min="{$dimensions.ratio_square.min}" data-max="{$dimensions.ratio_square.max}">{'square'|@translate}</a> |
---|
650 | {/if} |
---|
651 | {if isset($dimensions.ratio_landscape)} |
---|
652 | | <a class="dimensions-choice" data-type="ratio" data-min="{$dimensions.ratio_landscape.min}" data-max="{$dimensions.ratio_landscape.max}">{'Landscape'|@translate}</a> |
---|
653 | {/if} |
---|
654 | {if isset($dimensions.ratio_panorama)} |
---|
655 | | <a class="dimensions-choice" data-type="ratio" data-min="{$dimensions.ratio_panorama.min}" data-max="{$dimensions.ratio_panorama.max}">{'Panorama'|@translate}</a> |
---|
656 | {/if} |
---|
657 | | <a class="dimensions-choice" data-type="ratio" data-min="{$dimensions.bounds.min_ratio}" data-max="{$dimensions.bounds.max_ratio}">{'Reset'|@translate}</a> |
---|
658 | <div id="filter_dimension_ratio_slider"></div> |
---|
659 | </blockquote> |
---|
660 | |
---|
661 | <input type="hidden" name="filter_dimension_min_width" value="{$dimensions.selected.min_width}"> |
---|
662 | <input type="hidden" name="filter_dimension_max_width" value="{$dimensions.selected.max_width}"> |
---|
663 | <input type="hidden" name="filter_dimension_min_height" value="{$dimensions.selected.min_height}"> |
---|
664 | <input type="hidden" name="filter_dimension_max_height" value="{$dimensions.selected.max_height}"> |
---|
665 | <input type="hidden" name="filter_dimension_min_ratio" value="{$dimensions.selected.min_ratio}"> |
---|
666 | <input type="hidden" name="filter_dimension_max_ratio" value="{$dimensions.selected.max_ratio}"> |
---|
667 | </li> |
---|
668 | </ul> |
---|
669 | |
---|
670 | <p class="actionButtons"> |
---|
671 | <select id="addFilter"> |
---|
672 | <option value="-1">{'Add a filter'|@translate}</option> |
---|
673 | <option disabled="disabled">------------------</option> |
---|
674 | <option value="filter_prefilter" {if isset($filter.prefilter)}disabled="disabled"{/if}>{'Predefined filter'|@translate}</option> |
---|
675 | <option value="filter_category" {if isset($filter.category)}disabled="disabled"{/if}>{'Album'|@translate}</option> |
---|
676 | <option value="filter_tags" {if isset($filter.tags)}disabled="disabled"{/if}>{'Tags'|@translate}</option> |
---|
677 | <option value="filter_level" {if isset($filter.level)}disabled="disabled"{/if}>{'Privacy level'|@translate}</option> |
---|
678 | <option value="filter_dimension" {if isset($filter.dimension)}disabled="disabled"{/if}>{'Dimensions'|@translate}</option> |
---|
679 | </select> |
---|
680 | <a id="removeFilters" href="">{'Remove all filters'|@translate}</a> |
---|
681 | </p> |
---|
682 | |
---|
683 | <p class="actionButtons" id="applyFilterBlock"> |
---|
684 | <input id="applyFilter" class="submit" type="submit" value="{'Refresh photo set'|@translate}" name="submitFilter"> |
---|
685 | </p> |
---|
686 | |
---|
687 | </fieldset> |
---|
688 | |
---|
689 | <fieldset> |
---|
690 | |
---|
691 | <legend>{'Selection'|@translate}</legend> |
---|
692 | |
---|
693 | {if !empty($thumbnails)} |
---|
694 | <p id="checkActions"> |
---|
695 | {'Select:'|@translate} |
---|
696 | {if $nb_thumbs_set > $nb_thumbs_page} |
---|
697 | <a href="#" id="selectAll">{'The whole page'|@translate}</a>, |
---|
698 | <a href="#" id="selectSet">{'The whole set'|@translate}</a>, |
---|
699 | {else} |
---|
700 | <a href="#" id="selectAll">{'All'|@translate}</a>, |
---|
701 | {/if} |
---|
702 | <a href="#" id="selectNone">{'None'|@translate}</a>, |
---|
703 | <a href="#" id="selectInvert">{'Invert'|@translate}</a> |
---|
704 | |
---|
705 | <span id="selectedMessage"></span> |
---|
706 | |
---|
707 | <input type="checkbox" name="setSelected" style="display:none" {if count($selection) == $nb_thumbs_set}checked="checked"{/if}> |
---|
708 | </p> |
---|
709 | |
---|
710 | <ul class="thumbnails"> |
---|
711 | {html_style} |
---|
712 | UL.thumbnails SPAN.wrap2{ldelim} |
---|
713 | width: {$thumb_params->max_width()+2}px; |
---|
714 | } |
---|
715 | UL.thumbnails SPAN.wrap2 {ldelim} |
---|
716 | height: {$thumb_params->max_height()+25}px; |
---|
717 | } |
---|
718 | {/html_style} |
---|
719 | {foreach from=$thumbnails item=thumbnail} |
---|
720 | {assign var='isSelected' value=$thumbnail.id|@in_array:$selection} |
---|
721 | <li> |
---|
722 | <span class="wrap1"> |
---|
723 | <label> |
---|
724 | <input type="checkbox" name="selection[]" value="{$thumbnail.id}" {if $isSelected}checked="checked"{/if}> |
---|
725 | <span class="wrap2{if $isSelected} thumbSelected{/if}"> |
---|
726 | <div class="actions"><a href="{$thumbnail.FILE_SRC}" class="preview-box">{'Zoom'|@translate}</a> · <a href="{$thumbnail.U_EDIT}" target="_blank">{'Edit'|@translate}</a></div> |
---|
727 | {if $thumbnail.level > 0} |
---|
728 | <em class="levelIndicatorB">{'Level %d'|@sprintf:$thumbnail.level|@translate}</em> |
---|
729 | <em class="levelIndicatorF" title="{'Who can see these photos?'|@translate} : ">{'Level %d'|@sprintf:$thumbnail.level|@translate}</em> |
---|
730 | {/if} |
---|
731 | <img src="{$thumbnail.thumb->get_url()}" alt="{$thumbnail.file}" title="{$thumbnail.TITLE|@escape:'html'}" {$thumbnail.thumb->get_size_htm()}> |
---|
732 | </span> |
---|
733 | </label> |
---|
734 | </span> |
---|
735 | </li> |
---|
736 | {/foreach} |
---|
737 | </ul> |
---|
738 | |
---|
739 | {if !empty($navbar) } |
---|
740 | <div style="clear:both;"> |
---|
741 | |
---|
742 | <div style="float:left"> |
---|
743 | {include file='navigation_bar.tpl'|@get_extent:'navbar'} |
---|
744 | </div> |
---|
745 | |
---|
746 | <div style="float:right;margin-top:10px;">{'display'|@translate} |
---|
747 | <a href="{$U_DISPLAY}&display=20">20</a> |
---|
748 | · <a href="{$U_DISPLAY}&display=50">50</a> |
---|
749 | · <a href="{$U_DISPLAY}&display=100">100</a> |
---|
750 | · <a href="{$U_DISPLAY}&display=all">{'all'|@translate}</a> |
---|
751 | {'photos per page'|@translate} |
---|
752 | </div> |
---|
753 | </div> |
---|
754 | {/if} |
---|
755 | |
---|
756 | {else} |
---|
757 | <div>{'No photo in the current set.'|@translate}</div> |
---|
758 | {/if} |
---|
759 | </fieldset> |
---|
760 | |
---|
761 | <fieldset id="action"> |
---|
762 | |
---|
763 | <legend>{'Action'|@translate}</legend> |
---|
764 | <div id="forbidAction"{if count($selection) != 0} style="display:none"{/if}>{'No photo selected, no action possible.'|@translate}</div> |
---|
765 | <div id="permitAction"{if count($selection) == 0} style="display:none"{/if}> |
---|
766 | |
---|
767 | <select name="selectAction"> |
---|
768 | <option value="-1">{'Choose an action'|@translate}</option> |
---|
769 | <option disabled="disabled">------------------</option> |
---|
770 | <option value="delete" class="icon-trash">{'Delete selected photos'|@translate}</option> |
---|
771 | <option value="associate">{'Associate to album'|@translate}</option> |
---|
772 | <option value="move">{'Move to album'|@translate}</option> |
---|
773 | {if !empty($dissociate_options)} |
---|
774 | <option value="dissociate">{'Dissociate from album'|@translate}</option> |
---|
775 | {/if} |
---|
776 | <option value="add_tags">{'Add tags'|@translate}</option> |
---|
777 | {if !empty($DEL_TAG_SELECTION)} |
---|
778 | <option value="del_tags">{'remove tags'|@translate}</option> |
---|
779 | {/if} |
---|
780 | <option value="author">{'Set author'|@translate}</option> |
---|
781 | <option value="title">{'Set title'|@translate}</option> |
---|
782 | <option value="date_creation">{'Set creation date'|@translate}</option> |
---|
783 | <option value="level" class="icon-lock">{'Who can see these photos?'|@translate}</option> |
---|
784 | <option value="metadata">{'Synchronize metadata'|@translate}</option> |
---|
785 | {if ($IN_CADDIE)} |
---|
786 | <option value="remove_from_caddie">{'Remove from caddie'|@translate}</option> |
---|
787 | {else} |
---|
788 | <option value="add_to_caddie">{'Add to caddie'|@translate}</option> |
---|
789 | {/if} |
---|
790 | <option value="delete_derivatives">{'Delete multiple size images'|@translate}</option> |
---|
791 | <option value="generate_derivatives">{'Generate multiple size images'|@translate}</option> |
---|
792 | {if !empty($element_set_global_plugins_actions)} |
---|
793 | {foreach from=$element_set_global_plugins_actions item=action} |
---|
794 | <option value="{$action.ID}">{$action.NAME}</option> |
---|
795 | {/foreach} |
---|
796 | {/if} |
---|
797 | </select> |
---|
798 | |
---|
799 | <!-- delete --> |
---|
800 | <div id="action_delete" class="bulkAction"> |
---|
801 | <p><label><input type="checkbox" name="confirm_deletion" value="1"> {'Are you sure?'|@translate}</label></p> |
---|
802 | </div> |
---|
803 | |
---|
804 | <!-- associate --> |
---|
805 | <div id="action_associate" class="bulkAction"> |
---|
806 | <select style="width:400px" name="associate" size="1"> |
---|
807 | {html_options options=$category_full_name_options} |
---|
808 | </select> |
---|
809 | <br>{'... or '|@translate} <a href="#" class="addAlbumOpen" title="{'create a new album'|@translate}">{'create a new album'|@translate}</a> |
---|
810 | </div> |
---|
811 | |
---|
812 | <!-- move --> |
---|
813 | <div id="action_move" class="bulkAction"> |
---|
814 | <select style="width:400px" name="move" size="1"> |
---|
815 | {html_options options=$category_full_name_options} |
---|
816 | </select> |
---|
817 | <br>{'... or '|@translate} <a href="#" class="addAlbumOpen" title="{'create a new album'|@translate}">{'create a new album'|@translate}</a> |
---|
818 | </div> |
---|
819 | |
---|
820 | |
---|
821 | <!-- dissociate --> |
---|
822 | <div id="action_dissociate" class="bulkAction"> |
---|
823 | <select style="width:400px" name="dissociate" size="1"> |
---|
824 | {if !empty($dissociate_options)}{html_options options=$dissociate_options }{/if} |
---|
825 | </select> |
---|
826 | </div> |
---|
827 | |
---|
828 | |
---|
829 | <!-- add_tags --> |
---|
830 | <div id="action_add_tags" class="bulkAction"> |
---|
831 | <select id="tags" name="add_tags"> |
---|
832 | </select> |
---|
833 | </div> |
---|
834 | |
---|
835 | <!-- del_tags --> |
---|
836 | <div id="action_del_tags" class="bulkAction"> |
---|
837 | {if !empty($DEL_TAG_SELECTION)}{$DEL_TAG_SELECTION}{/if} |
---|
838 | </div> |
---|
839 | |
---|
840 | <!-- author --> |
---|
841 | <div id="action_author" class="bulkAction"> |
---|
842 | <label><input type="checkbox" name="remove_author"> {'remove author'|@translate}</label><br> |
---|
843 | {assign var='authorDefaultValue' value='Type here the author name'|@translate} |
---|
844 | <input type="text" class="large" name="author" value="{$authorDefaultValue}" onfocus="this.value=(this.value=='{$authorDefaultValue|@escape:javascript}') ? '' : this.value;" onblur="this.value=(this.value=='') ? '{$authorDefaultValue|@escape:javascript}' : this.value;"> |
---|
845 | </div> |
---|
846 | |
---|
847 | <!-- title --> |
---|
848 | <div id="action_title" class="bulkAction"> |
---|
849 | <label><input type="checkbox" name="remove_title"> {'remove title'|@translate}</label><br> |
---|
850 | {assign var='titleDefaultValue' value='Type here the title'|@translate} |
---|
851 | <input type="text" class="large" name="title" value="{$titleDefaultValue}" onfocus="this.value=(this.value=='{$titleDefaultValue|@escape:javascript}') ? '' : this.value;" onblur="this.value=(this.value=='') ? '{$titleDefaultValue|@escape:javascript}' : this.value;"> |
---|
852 | </div> |
---|
853 | |
---|
854 | <!-- date_creation --> |
---|
855 | <div id="action_date_creation" class="bulkAction"> |
---|
856 | <label><input type="checkbox" name="remove_date_creation"> {'remove creation date'|@translate}</label><br> |
---|
857 | <div id="set_date_creation"> |
---|
858 | <select id="date_creation_day" name="date_creation_day"> |
---|
859 | <option value="0">--</option> |
---|
860 | {section name=day start=1 loop=32} |
---|
861 | <option value="{$smarty.section.day.index}" {if $smarty.section.day.index==$DATE_CREATION_DAY}selected="selected"{/if}>{$smarty.section.day.index}</option> |
---|
862 | {/section} |
---|
863 | </select> |
---|
864 | <select id="date_creation_month" name="date_creation_month"> |
---|
865 | {html_options options=$month_list selected=$DATE_CREATION_MONTH} |
---|
866 | </select> |
---|
867 | <input id="date_creation_year" |
---|
868 | name="date_creation_year" |
---|
869 | type="text" |
---|
870 | size="4" |
---|
871 | maxlength="4" |
---|
872 | value="{$DATE_CREATION_YEAR}"> |
---|
873 | <input id="date_creation_linked_date" name="date_creation_linked_date" type="hidden" size="10" disabled="disabled"> |
---|
874 | </div> |
---|
875 | </div> |
---|
876 | |
---|
877 | <!-- level --> |
---|
878 | <div id="action_level" class="bulkAction"> |
---|
879 | <select name="level" size="1"> |
---|
880 | {html_options options=$level_options selected=$level_options_selected} |
---|
881 | </select> |
---|
882 | </div> |
---|
883 | |
---|
884 | <!-- metadata --> |
---|
885 | <div id="action_metadata" class="bulkAction"> |
---|
886 | </div> |
---|
887 | |
---|
888 | <!-- generate derivatives --> |
---|
889 | <div id="action_generate_derivatives" class="bulkAction"> |
---|
890 | <a href="javascript:selectGenerateDerivAll()">{'All'|@translate}</a>, |
---|
891 | <a href="javascript:selectGenerateDerivNone()">{'None'|@translate}</a> |
---|
892 | <br> |
---|
893 | {foreach from=$generate_derivatives_types key=type item=disp} |
---|
894 | <label><input type="checkbox" name="generate_derivatives_type[]" value="{$type}"> {$disp}</label> |
---|
895 | {/foreach} |
---|
896 | {footer_script} |
---|
897 | function selectGenerateDerivAll() {ldelim} |
---|
898 | $("#action_generate_derivatives input[type=checkbox]").prop("checked", true); |
---|
899 | } |
---|
900 | function selectGenerateDerivNone() {ldelim} |
---|
901 | $("#action_generate_derivatives input[type=checkbox]").prop("checked", false); |
---|
902 | } |
---|
903 | {/footer_script} |
---|
904 | </div> |
---|
905 | |
---|
906 | <!-- delete derivatives --> |
---|
907 | <div id="action_delete_derivatives" class="bulkAction"> |
---|
908 | <a href="javascript:selectDelDerivAll()">{'All'|@translate}</a>, |
---|
909 | <a href="javascript:selectDelDerivNone()">{'None'|@translate}</a> |
---|
910 | <br> |
---|
911 | {foreach from=$del_derivatives_types key=type item=disp} |
---|
912 | <label><input type="checkbox" name="del_derivatives_type[]" value="{$type}"> {$disp}</label> |
---|
913 | {/foreach} |
---|
914 | {footer_script} |
---|
915 | function selectDelDerivAll() {ldelim} |
---|
916 | $("#action_delete_derivatives input[type=checkbox]").prop("checked", true); |
---|
917 | } |
---|
918 | function selectDelDerivNone() {ldelim} |
---|
919 | $("#action_delete_derivatives input[type=checkbox]").prop("checked", false); |
---|
920 | } |
---|
921 | {/footer_script} |
---|
922 | </div> |
---|
923 | |
---|
924 | <!-- progress bar --> |
---|
925 | <div id="regenerationMsg" class="bulkAction" style="display:none"> |
---|
926 | <p id="regenerationText" style="margin-bottom:10px;">{'Generate multiple size images'|@translate}</p> |
---|
927 | <span class="progressBar" id="progressBar"></span> |
---|
928 | <input type="hidden" name="regenerateSuccess" value="0"> |
---|
929 | <input type="hidden" name="regenerateError" value="0"> |
---|
930 | </div> |
---|
931 | |
---|
932 | <!-- plugins --> |
---|
933 | {if !empty($element_set_global_plugins_actions)} |
---|
934 | {foreach from=$element_set_global_plugins_actions item=action} |
---|
935 | <div id="action_{$action.ID}" class="bulkAction"> |
---|
936 | {if !empty($action.CONTENT)}{$action.CONTENT}{/if} |
---|
937 | </div> |
---|
938 | {/foreach} |
---|
939 | {/if} |
---|
940 | |
---|
941 | <p id="applyActionBlock" style="display:none" class="actionButtons"> |
---|
942 | <input id="applyAction" class="submit" type="submit" value="{'Apply action'|@translate}" name="submit"> <span id="applyOnDetails"></span></p> |
---|
943 | |
---|
944 | </div> <!-- #permitAction --> |
---|
945 | </fieldset> |
---|
946 | |
---|
947 | </form> |
---|
948 | |
---|
949 | </div> <!-- #batchManagerGlobal --> |
---|