1 | {footer_script} |
---|
2 | var incompatible_msg = '{'WARNING! This plugin does not seem to be compatible with this version of Piwigo.'|@translate|@escape:'javascript'}'; |
---|
3 | incompatible_msg += '\n'; |
---|
4 | incompatible_msg += '{'Do you want to activate anyway?'|@translate|@escape:'javascript'}'; |
---|
5 | |
---|
6 | {literal} |
---|
7 | jQuery(document).ready(function() { |
---|
8 | jQuery('.incompatible').click(function() { |
---|
9 | return confirm(incompatible_msg); |
---|
10 | }); |
---|
11 | jQuery('.warning').tipTip({ |
---|
12 | 'delay' : 0, |
---|
13 | 'fadeIn' : 200, |
---|
14 | 'fadeOut' : 200 |
---|
15 | }); |
---|
16 | }); |
---|
17 | {/literal}{/footer_script} |
---|
18 | |
---|
19 | <div class="titrePage"> |
---|
20 | <h2>{'Plugins'|@translate}</h2> |
---|
21 | </div> |
---|
22 | |
---|
23 | {if isset($plugins)} |
---|
24 | |
---|
25 | {foreach from=$plugin_states item=plugin_state} |
---|
26 | <fieldset> |
---|
27 | <legend> |
---|
28 | {if $plugin_state == 'active'} |
---|
29 | {'Active Plugins'|@translate} |
---|
30 | |
---|
31 | {elseif $plugin_state == 'inactive'} |
---|
32 | {'Inactive Plugins'|@translate} |
---|
33 | |
---|
34 | {elseif $plugin_state == 'uninstalled'} |
---|
35 | {'Uninstalled Plugins'|@translate} |
---|
36 | |
---|
37 | {elseif $plugin_state == 'missing'} |
---|
38 | {'Missing Plugins'|@translate} |
---|
39 | |
---|
40 | {elseif $plugin_state == 'merged'} |
---|
41 | {'Obsolete Plugins'|@translate} |
---|
42 | |
---|
43 | {/if} |
---|
44 | </legend> |
---|
45 | {foreach from=$plugins item=plugin name=plugins_loop} |
---|
46 | {if $plugin.STATE == $plugin_state} |
---|
47 | <div class="pluginBox"> |
---|
48 | <table> |
---|
49 | <tr> |
---|
50 | <td class="pluginBoxNameCell{if $plugin.INCOMPATIBLE} warning" title="{'WARNING! This plugin does not seem to be compatible with this version of Piwigo.'|@translate|@escape:'html'}{/if}"> |
---|
51 | {$plugin.NAME} |
---|
52 | </td> |
---|
53 | <td>{$plugin.DESC}</td> |
---|
54 | </tr> |
---|
55 | <tr> |
---|
56 | <td> |
---|
57 | {if $plugin.STATE == 'active'} |
---|
58 | <a href="{$plugin.U_ACTION}&action=deactivate">{'Deactivate'|@translate}</a> |
---|
59 | |
---|
60 | {elseif $plugin_state == 'inactive'} |
---|
61 | <a href="{$plugin.U_ACTION}&action=activate" {if $plugin.INCOMPATIBLE}class="incompatible"{/if}>{'Activate'|@translate}</a> |
---|
62 | | <a href="{$plugin.U_ACTION}&action=uninstall" onclick="return confirm('{'Are you sure?'|@translate|@escape:'javascript'}');">{'Uninstall'|@translate}</a> |
---|
63 | |
---|
64 | {elseif $plugin_state == 'uninstalled'} |
---|
65 | <a href="{$plugin.U_ACTION}&action=install">{'Install'|@translate}</a> |
---|
66 | | <a href="{$plugin.U_ACTION}&action=delete" onclick="return confirm('{'Are you sure you want to delete this plugin?'|@translate|@escape:'javascript'}');">{'Delete'|@translate}</a> |
---|
67 | |
---|
68 | {elseif $plugin_state == 'missing'} |
---|
69 | <a href="{$plugin.U_ACTION}&action=uninstall" onclick="return confirm('{'Are you sure?'|@translate|@escape:'javascript'}');">{'Uninstall'|@translate}</a> |
---|
70 | |
---|
71 | {elseif $plugin_state == 'merged'} |
---|
72 | <a href="{$plugin.U_ACTION}&action=delete">{'Delete'|@translate}</a> |
---|
73 | {/if} |
---|
74 | </td> |
---|
75 | <td> |
---|
76 | {'Version'|@translate} {$plugin.VERSION} |
---|
77 | {if not empty($plugin.AUTHOR)} |
---|
78 | {if not empty($plugin.AUTHOR_URL)} |
---|
79 | {assign var='author' value='<a href="%s">%s</a>'|@sprintf:$plugin.AUTHOR_URL:$plugin.AUTHOR} |
---|
80 | {else} |
---|
81 | {assign var='author' value=$plugin.AUTHOR} |
---|
82 | {/if} |
---|
83 | | {'By %s'|@translate|@sprintf:$author} |
---|
84 | {/if} |
---|
85 | |
---|
86 | {if not empty($plugin.VISIT_URL)} |
---|
87 | | <a class="externalLink" href="{$plugin.VISIT_URL}">{'Visit plugin site'|@translate}</a> |
---|
88 | {/if} |
---|
89 | </td> |
---|
90 | </tr> |
---|
91 | </table> |
---|
92 | </div> |
---|
93 | {/if} |
---|
94 | {/foreach} |
---|
95 | </fieldset> |
---|
96 | {/foreach} |
---|
97 | |
---|
98 | {/if} |
---|