{* * $Revision: 17380 $ * Read this before changing templates! http://codex.gallery2.org/Gallery2:Editing_Templates *}

{g->text text="System Maintenance"}

{if isset($form.error.maintenanceModeRequired)}

{g->text text="Gallery must be in maintenance mode before the task can be run."}

{/if} {if isset($status.run)}
{capture name=taskTitle}{g->text text=$AdminMaintenance.tasks[$status.run.taskId].title l10Domain=$AdminMaintenance.tasks[$status.run.taskId].l10Domain}{/capture} {if ($status.run.success)}

{g->text text="Completed %s task successfully." arg1=$smarty.capture.taskTitle}

{else}

{g->text text="The %s task failed to complete successfully." arg1=$smarty.capture.taskTitle}

{/if}
{/if} {if isset($status.setMode)}

{if isset($status.setMode.setOn)} {g->text text="Maintenance Mode has been turned on."} {elseif isset($status.setMode.setOff)} {g->text text="Maintenance Mode has been turned off."} {/if}

{/if}

{g->text text="Maintenance Mode"}

{g->text text="Restrict user access to the system while maintenance is being performed."}

{g->text text="Maintenance Mode Url"}

{g->text text="The Maintenance Mode Url specifies where requests will be redirected when access to the site has been restricted by the administrator."} {g->text text="If left blank Gallery will display a default page with an administrator login link. This page will be themed when the code base is up to date, otherwise it will display a plain unstyled page."}
{g->text text="For example: /maintenance.html"}

{foreach from=$AdminMaintenance.tasks key=taskId item=info} {cycle values="gbEven,gbOdd" assign="rowClass"} {/foreach}
{g->text text="Task name"} {g->text text="Last run"} {g->text text="Success/Fail"} {g->text text="Action"}
{if !isset($status.run) || $status.run.taskId != $taskId}+{else}-{/if} {g->text text=$info.title l10Domain=$info.l10Domain} {if isset($info.timestamp)} {g->date timestamp=$info.timestamp style="datetime"} {else} {g->text text="Not run yet"} {/if} {if isset($info.success)} {if $info.success}
{g->text text="Success"}
{else}
{g->text text="Failed"}
{/if} {else} {g->text text="Not run yet"} {/if}
{g->text text="run now"}
{g->text text=$info.description l10Domain=$info.l10Domain} {if !empty($info.details)}

{g->text text="Last Run Details:"}

{foreach from=$info.details item=text} {$text}
{/foreach}

{/if}