diff options
| author | Simon Rettberg | 2016-05-03 19:03:09 +0200 |
|---|---|---|
| committer | Simon Rettberg | 2016-05-03 19:03:09 +0200 |
| commit | 50404f3b23b7fd6aeae4c9d2f6df0ea25e984e66 (patch) | |
| tree | 05e99fdffa696434960d7c77966c0bc36d6339e8 /modules/backup/templates | |
| parent | Second half of merge.... (diff) | |
| download | slx-admin-50404f3b23b7fd6aeae4c9d2f6df0ea25e984e66.tar.gz slx-admin-50404f3b23b7fd6aeae4c9d2f6df0ea25e984e66.tar.xz slx-admin-50404f3b23b7fd6aeae4c9d2f6df0ea25e984e66.zip | |
WIP
Diffstat (limited to 'modules/backup/templates')
| -rw-r--r-- | modules/backup/templates/_page.html | 41 | ||||
| -rw-r--r-- | modules/backup/templates/restore.html | 62 |
2 files changed, 0 insertions, 103 deletions
diff --git a/modules/backup/templates/_page.html b/modules/backup/templates/_page.html deleted file mode 100644 index 47b5a174..00000000 --- a/modules/backup/templates/_page.html +++ /dev/null @@ -1,41 +0,0 @@ -<h1>{{lang_backupRestore}}</h1> - -<form action="?do=Backup" method="post"> - <input type="hidden" name="token" value="{{token}}"> - <input type="hidden" name="action" value="backup"> - <div class="panel panel-default"> - <div class="panel-heading">{{lang_backup}}</div> - <div class="panel-body"> - <p>{{lang_backupDescription}}</p> - <button class="btn btn-primary" type="submit">{{lang_download}}</button> - </div> - </div> -</form> - -<form action="?do=Backup" method="post" enctype="multipart/form-data"> - <input type="hidden" name="token" value="{{token}}"> - <input type="hidden" name="action" value="restore"> - <div class="panel panel-default"> - <div class="panel-heading">{{lang_restore}}</div> - <div class="panel-body"> - <p>{{lang_restoreDescription}}</p> - <div class="input-group upload-ex"> - <input type="text" class="form-control" readonly placeholder="{{lang_selectFile}}"> - <span class="input-group-btn"> - <span class="btn btn-default btn-file"> - {{lang_browseForFile}}… <input type="file" name="backupfile"> - </span> - </span> - </div> - <div> - <label><input type="checkbox" name="restore_openslx" checked="checked"> {{lang_restoreSystemConfig}}</label> - <p><i>{{lang_systemExplanation}}</i></p> - </div> - <div> - <label><input type="checkbox" name="restore_dozmod" checked="checked"> {{lang_restoreDozmodConfig}}</label> - <p><i>{{lang_dozmodExplanation}}</i></p> - </div> - <button class="btn btn-primary" type="submit">{{lang_restore}}</button> - </div> - </div> -</form>
\ No newline at end of file diff --git a/modules/backup/templates/restore.html b/modules/backup/templates/restore.html deleted file mode 100644 index 4494a993..00000000 --- a/modules/backup/templates/restore.html +++ /dev/null @@ -1,62 +0,0 @@ -<div class="panel panel-default"> - <div class="panel-heading">{{lang_backup}}</div> - <div class="panel-body"> - <div id="zeug"> - <div data-tm-id="{{syncid}}" data-tm-log="messages">{{lang_stopping}} syncdaemon</div> - <div data-tm-id="{{dmsdid}}" data-tm-log="messages">{{lang_stopping}} dmsd</div> - <div data-tm-id="{{ldadpid}}" data-tm-log="messages">{{lang_stopping}} ldadp</div> - <div data-tm-id="{{mountid}}" data-tm-log="messages">{{lang_stopping}} vmstore</div> - <div data-tm-id="{{restoreid}}" data-tm-log="messages" data-tm-callback="restoreCb">{{lang_restoreConfig}}</div> - <div data-tm-id="{{rebootid}}" data-tm-log="messages">{{lang_reboot}}</div> - </div> - <div id="restorefailed" class="alert alert-danger" style="display:none"> - {{lang_restoreFailed}} - </div> - <div id="waiting" style="display:none"> - <span id="dots"></span> - </div> - </div> -</div> - -<script type="text/javascript"> - function restoreCb(task) - { - if (!task || !task.statusCode) - return; - if (task.statusCode === 'TASK_ERROR') { - $('#restorefailed').show('slow'); - } - if (task.statusCode === 'TASK_ERROR' || task.statusCode === 'TASK_FINISHED') { - startRebootPoll(); - } - } - - function startRebootPoll() - { - $('#waiting').show(); - $('#waiting').prepend('<span class="glyphicon glyphicon-refresh slx-rotation"></span>'); - $('#dots').text('{{lang_waitReboot}}'); - slxDotInterval = setInterval(function() { $('#dots').text($('#dots').text() + '..'); }, 3000); - setTimeout('rebootPoll()', 10000); - } - - function rebootPoll() - { - if (slxDotInterval !== false) { - clearInterval(slxDotInterval); - slxDotInterval = false; - } - $('#dots').text($('#dots').text() + '..'); - slxTimeoutId = setTimeout('rebootPoll()', 3500); - $.ajax({url: "index.php?do=Main", timeout: 3000}).success(function(data, textStatus, jqXHR) { - if (textStatus !== "success" && textStatus !== "notmodified") - return; - if (data.indexOf('Status: DB running') === -1) - return; - clearTimeout(slxTimeoutId); - setTimeout(function() { - window.location.replace("index.php?do=Main&message[]=success%7Crestore-done"); - }, 3500); - }); - } -</script> |
