<?php
/* Smarty version 4.3.4, created on 2024-08-26 08:43:50
  from '/var/www/html/users/ba/lazbw_marker_include/admin/layout/templates/functions/backup.html' */

/* @var Smarty_Internal_Template $_smarty_tpl */
if ($_smarty_tpl->_decodeProperties($_smarty_tpl, array (
  'version' => '4.3.4',
  'unifunc' => 'content_66cc2426232438_34796231',
  'has_nocache_code' => false,
  'file_dependency' => 
  array (
    'cdf48e3f476419510e7958dfe4292c203126bbbb' => 
    array (
      0 => '/var/www/html/users/ba/lazbw_marker_include/admin/layout/templates/functions/backup.html',
      1 => 1685518172,
      2 => 'file',
    ),
  ),
  'includes' => 
  array (
  ),
),false)) {
function content_66cc2426232438_34796231 (Smarty_Internal_Template $_smarty_tpl) {
?><h3>Sicherung der Einstellungen durchführen</h3>

<?php if ($_smarty_tpl->tpl_vars['execbackup']->value == 1) {?>
  <?php if ($_smarty_tpl->tpl_vars['succeed']->value == 1) {?>
  <div class="status_ok">
    Eine neue Sicherung der Einstellungen wurde angelegt.
  </div>
  <?php } else { ?>
  <div class="status_error">
    Eine Sicherung der Einstellungen konnte nicht (komplett) durchgeführt werden.
  </div>
  
  <?php
$_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['backuperrors']->value, 'error');
$_smarty_tpl->tpl_vars['error']->do_else = true;
if ($_from !== null) foreach ($_from as $_smarty_tpl->tpl_vars['error']->value) {
$_smarty_tpl->tpl_vars['error']->do_else = false;
?>
  <div class="status_error">
    <?php echo $_smarty_tpl->tpl_vars['error']->value;?>

  </div>  
  <?php
}
$_smarty_tpl->smarty->ext->_foreach->restore($_smarty_tpl, 1);?>
  <?php }?>
  <br />
<?php }?>

<div class="right_float">
  <form id="copysettingsform" action="<?php echo $_smarty_tpl->tpl_vars['selflink']->value;?>
" method="post">
    <input type="hidden" name="dobackup_all" value="all" />
    <input type="submit" id="dobackup" name="dobackup" value="Komplette Sicherung" />
  </form>
</div>

<p>
Eine Sicherung beinhaltet alle für den Betrieb von KuferWEB notwendigen 
Einstellungen (Settings, Sichten, Konstanten und Datenbankeinstellungen).
</p>

<form id="copysettingsform" action="<?php echo $_smarty_tpl->tpl_vars['selflink']->value;?>
" method="post">
  <div class="right_float">
    <input type="submit" name="dobackup" value="Auswahl sichern" />
  </div>
  <input type="checkbox" id="dobackup_system" name="dobackup_system" value="system" />
  <label for="dobackup_system">Systemeinstellungen</label><br />
  <input type="checkbox" id="dobackup_settings" name="dobackup_settings" value="settings" />
  <label for="dobackup_settings">Layouteinstellungen</label><br />
  <input type="checkbox" id="dobackup_constants" name="dobackup_constants" value="constants" />
  <label for="dobackup_constants">Konstanten</label><br />
  <input type="checkbox" id="dobackup_sights" name="dobackup_sights" value="sights" />
  <label for="dobackup_sights">Sichten</label><br />
  <input type="checkbox" id="dobackup_css" name="dobackup_css" value="css" />
  <label for="dobackup_css">CSS - Dateien</label><br />
  <input type="checkbox" id="dobackup_kufertools_layout" name="dobackup_kufertools_layout" value="kufertools_layout" />
  <label for="dobackup_css">KuferTools Layout</label><br />
</form>
<br />


<h3>Vorhandene Sicherungen</h3>

<?php if ($_smarty_tpl->tpl_vars['delete']->value == 1) {?>
  <?php if ($_smarty_tpl->tpl_vars['deletesuccess']->value == 1) {?>
  <div class="status_ok">
    Die Sicherung "<?php echo $_smarty_tpl->tpl_vars['deletebackuptitle']->value;?>
" vom "<?php echo $_smarty_tpl->tpl_vars['deletebackupdate']->value;?>
" wurde gelöscht.
  </div>
  <?php } else { ?>
  <div class="status_error">
    <?php echo $_smarty_tpl->tpl_vars['deletesuccess']->value;?>

  </div>
  <?php }?>
  <br />
<?php }?>

<?php if ($_smarty_tpl->tpl_vars['restore']->value == 1) {?>
  <?php if ($_smarty_tpl->tpl_vars['restoresuccess']->value == 1) {?>
  <div class="status_ok">
    Die Sicherung "<?php echo $_smarty_tpl->tpl_vars['restorebackuptitle']->value;?>
" vom "<?php echo $_smarty_tpl->tpl_vars['restorebackupdate']->value;?>
" wurde wiederhergestellt.
  </div>
  <?php } else { ?>
  <div class="status_error">
    <?php echo $_smarty_tpl->tpl_vars['restoresuccess']->value;?>

  </div>
  <?php }?>
  <br />
<?php }?>

<?php if ($_smarty_tpl->tpl_vars['countbackups']->value > 0) {?>
<table width="99%">
  <tr>
    <th>Datum</th>
    <th>Beschreibung</th>
    <th>&nbsp;</th></tr>
<?php
$_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['backups']->value, 'backup');
$_smarty_tpl->tpl_vars['backup']->do_else = true;
if ($_from !== null) foreach ($_from as $_smarty_tpl->tpl_vars['backup']->value) {
$_smarty_tpl->tpl_vars['backup']->do_else = false;
?>
  <tr>
    <td><?php echo $_smarty_tpl->tpl_vars['backup']->value['date'];?>
</td>
    <td><?php echo $_smarty_tpl->tpl_vars['backup']->value['title'];?>
</td>
    <td align="right">
      <form action="<?php echo $_smarty_tpl->tpl_vars['selflink']->value;?>
" method="post">
        <input type="hidden" name="backupid" value="<?php echo $_smarty_tpl->tpl_vars['backup']->value['id'];?>
" />
        <input type="submit" name="restore" value="Einspielen" />
        <input type="submit" name="del" value="Löschen" />
      </form>
    </td></tr>
<?php
}
$_smarty_tpl->smarty->ext->_foreach->restore($_smarty_tpl, 1);?>
</table>
<?php } else { ?>
<p>
  <div class="status_warning">
    Aktuell stehen keine Sicherungen zur Verfügung!
  </div>
</p>
<?php }
}
}
