summaryrefslogtreecommitdiffstats
path: root/lbu-commit-html.lsp
diff options
context:
space:
mode:
Diffstat (limited to 'lbu-commit-html.lsp')
-rw-r--r--lbu-commit-html.lsp85
1 files changed, 45 insertions, 40 deletions
diff --git a/lbu-commit-html.lsp b/lbu-commit-html.lsp
index 1efc362..6164739 100644
--- a/lbu-commit-html.lsp
+++ b/lbu-commit-html.lsp
@@ -1,43 +1,48 @@
-<?
-local view = ...
-
-local function packURL(script, prefix, controller, action, extra)
- ret = script .. "/" .. prefix .. controller .. "/" .. action
- sep = '?'
- for k,v in pairs(extra) do
- ret = ret .. sep .. k .. '=' .. v
- sep = '&'
- end
- return ret
-end
-?>
+<? local view = ... ?>
-<h1><?= view.title?></h1>
-<? if (table.maxn(view.data) > 0) then ?>
- <h2>List</h2>
-<? end ?>
-<? for i,item in ipairs(view.note or {}) do ?>
- <p class='error'><?= item.content ?></p>
-<? end ?>
-<? for i,item in ipairs(view.data) do ?>
- <dt><?= item.name ?></dt><dd><?= item.status ?></dd>
-<? end ?>
+<h1>SYSTEM INFO</h1>
+
+<dl>
+ <dt>Program status</dt>
+ <dd><?= view.status.status or "" ?></dd>
+ <dt>Program version</dt>
+ <dd><?= view.status.version ?></dd>
+</dl>
+
+<H2>PROGRAM SPECIFIC OPTIONS/INFORMATION</H2>
+<dl>
+ <dt>Archives will be saved to</dt>
+ <dd><?= view.status.LBU_MEDIA or "" ?></dd>
+ <dt>Archives will be encrypted</dt>
+ <dd><? if (view.status.ENCRYPTION) then io.write("yes <I>(Using cipher: " .. view.status.DEFAULT_CIPHER .. ")</I>") else io.write("No") end ?></DD>
+</dl>
+
+<H1>MANAGEMENT</H1>
-<h2>Functions</h2>
-<dt>Save these changes</dt>
-<dd><?= html.form.start {
- method="POST",
- action = packURL(view.script, view.prefix,
- view.controller, view.action, {})
- }?>
-<?= html.form.submit { name = view.action, value = view.action }?>
-<?= html.form.stop() ?>
-</dd>
-
-<? for i,item in ipairs(view.text) do
- if item.label then ?>
- <h2><?= item.label ?></h2>
- <? end ?>
- <pre><?= item.content ?></pre>
+<H2>Save to media</h2>
+<form name="cmd" action="" method="POST">
+<dl>
+ <dt>Simulate/Test a commit</dt>
+ <dd><input type=submit class="submit" name="lbusimulate" value="simulate" ></dd>
+ <dt>Actually Commit and save changes</dt>
+ <dd><input type=submit class="submit" name="lbucommit" value="commit" ></dd>
+</dl>
+</form>
+
+
+
+
+<dl>
+<? if (view.cmdresult) then ?>
+ <dt>Result of previous action</dt>
+ <dd><pre><?= view.cmdresult ?></pre></DD>
<? end ?>
-<? -- vim: set filetype=lua : ?>
+</dl>
+
+<?
+--[[ DEBUG INFORMATION
+require("debugs")
+io.write(debugs.variables(view))
+--]]
+?>
+