mirror of
https://github.com/Piwigo/Piwigo.git
synced 2026-08-07 17:23:04 +02:00
fixes #1295 do not hide inactive plugins right after an activation
So that you save a click (to show inactive plugins) after an update (which deactivate all plugins)
This commit is contained in:
@@ -64,7 +64,14 @@ if (isset($_GET['action']) and isset($_GET['plugin']))
|
|||||||
$template->delete_compiled_templates();
|
$template->delete_compiled_templates();
|
||||||
$persistent_cache->purge(true);
|
$persistent_cache->purge(true);
|
||||||
}
|
}
|
||||||
redirect($base_url);
|
|
||||||
|
$redirect_url = $base_url;
|
||||||
|
if ('activate' == $_GET['action'])
|
||||||
|
{
|
||||||
|
$redirect_url.= '&show_inactive';
|
||||||
|
}
|
||||||
|
|
||||||
|
redirect($redirect_url);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -208,6 +215,7 @@ $template->assign(
|
|||||||
'PWG_TOKEN' => $pwg_token,
|
'PWG_TOKEN' => $pwg_token,
|
||||||
'base_url' => $base_url,
|
'base_url' => $base_url,
|
||||||
'show_details' => $show_details,
|
'show_details' => $show_details,
|
||||||
|
'max_inactive_before_hide' => isset($_GET['show_inactive']) ? 999 : 8,
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@@ -243,7 +243,7 @@ jQuery(".pluginMiniBox").each(function(index){
|
|||||||
</div> {* PluginBoxes*}
|
</div> {* PluginBoxes*}
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
<div class="pluginBoxes plugin-{$plugin.STATE}" {if $plugin.STATE == 'inactive'}{if $count_types_plugins["inactive"]>8}style="display:none"{/if}{/if}>
|
<div class="pluginBoxes plugin-{$plugin.STATE}" {if $plugin.STATE == 'inactive'}{if $count_types_plugins["inactive"]>$max_inactive_before_hide}style="display:none"{/if}{/if}>
|
||||||
{assign var='field_name' value=$plugin.STATE}
|
{assign var='field_name' value=$plugin.STATE}
|
||||||
|
|
||||||
<div class="pluginBoxesHead">
|
<div class="pluginBoxesHead">
|
||||||
@@ -332,7 +332,7 @@ jQuery(".pluginMiniBox").each(function(index){
|
|||||||
</div> {* PluginBoxes Container*}
|
</div> {* PluginBoxes Container*}
|
||||||
</div> {* PluginBoxes*}
|
</div> {* PluginBoxes*}
|
||||||
|
|
||||||
<div class="showInactivePlugins" {if $count_types_plugins["inactive"]<=8}style="display:none"{/if} >
|
<div class="showInactivePlugins" {if $count_types_plugins["inactive"]<=$max_inactive_before_hide}style="display:none"{/if} >
|
||||||
<div class="showInactivePluginsInfo">
|
<div class="showInactivePluginsInfo">
|
||||||
{assign var='badge_inactive' value='<span class="pluginBoxesCount">%s</span>'|@sprintf:$count_types_plugins["inactive"]}
|
{assign var='badge_inactive' value='<span class="pluginBoxesCount">%s</span>'|@sprintf:$count_types_plugins["inactive"]}
|
||||||
<div>{'You have %s inactive plugins'|translate:$badge_inactive}</div>
|
<div>{'You have %s inactive plugins'|translate:$badge_inactive}</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user