summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorSebastian Reichel <sre@ring0.de>2013-06-15 23:12:26 +0200
committerSebastian Reichel <sre@ring0.de>2013-06-15 23:12:26 +0200
commite11d76395ce0ba821f58bfb1956a56f6ffc8494b (patch)
treec01a24058b017c9f2b36d934e02f3cea5c408fde /templates
parent8504754a40d47b69b0aa1e786f0b1db45405a3fd (diff)
downloadserial-barcode-scanner-e11d76395ce0ba821f58bfb1956a56f6ffc8494b.tar.bz2
web: add cashbox tracking
Diffstat (limited to 'templates')
-rw-r--r--templates/cashbox/add.html17
-rw-r--r--templates/cashbox/index.html11
-rw-r--r--templates/menu.html3
3 files changed, 31 insertions, 0 deletions
diff --git a/templates/cashbox/add.html b/templates/cashbox/add.html
new file mode 100644
index 0000000..6e26f00
--- /dev/null
+++ b/templates/cashbox/add.html
@@ -0,0 +1,17 @@
+<div id="add-successful" class="alert alert-success" style="display: {{{NEW.OK}}};">
+ <p>Successfully balanced cashbox:</p>
+
+ <table class="table">
+ <tr><th>Type</th><td>{{{TYPE}}}</td></tr>
+ <tr><th>Amount</th><td>{{{AMOUNT}}}</td></tr>
+ </table>
+</div>
+
+<div id="add-failed" class="alert alert-error" style="display: {{{NEW.FAIL}}};">
+ <h4>Error</h4>
+ Creating new cashbox balance entry failed. Please make
+ sure you have sufficient permissions and gave valid
+ values for type and amount.
+</div>
+
+<a href="/cashbox">Back to cashbox overview</a>
diff --git a/templates/cashbox/index.html b/templates/cashbox/index.html
new file mode 100644
index 0000000..1466272
--- /dev/null
+++ b/templates/cashbox/index.html
@@ -0,0 +1,11 @@
+Current Cashbox Status: <input name"status" type="number" readonly="readonly" value="{{{CASHBOX_STATUS}}}"/>
+
+<form action="/cashbox/add" class="form-horizontal">
+ <legend>Cashbox Balance/Withdrawal/Deposit</legend>
+ <select name="type" size="1">
+ <option value="loss">Balance (Loss)</option>
+ <option value="user">Withdrawal / Deposit</option>
+ </select>
+ <input class="input-medium" name="amount" type="number" placeholder="Amount" />
+ <button type="submit" class="btn btn-primary"><i class="icon-plus"></i></button>
+</form>
diff --git a/templates/menu.html b/templates/menu.html
index 747853d..138cc23 100644
--- a/templates/menu.html
+++ b/templates/menu.html
@@ -4,6 +4,8 @@
<ul class="nav">
<li class="{{{MENU.home}}}"><a href="/">Home</a></li>
<li class="{{{MENU.products}}}"><a href="/products">Products</a></li>
+ <li class="{{{MENU.cashbox}}} {{{SUPERUSER}}}"><a href="/cashbox">Cashbox</a></li>
+<!--
<li class="{{{MENU.stats}}} dropdown">
<a href="#" id="statsmenu" class="dropdown-toggle" data-toggle="dropdown">Statistics <b class="caret"></b></a>
<ul class="dropdown-menu">
@@ -14,6 +16,7 @@
<li><a href="/stats/profit_per_product">Graph: Profit / Product</a></li>
</ul>
</li>
+-->
<li class="{{{MENU.users}}} {{{SUPERUSER}}} dropdown">
<a href="#" id="usersmenu" class="dropdown-toggle" data-toggle="dropdown">Users <b class="caret"></b></a>
<ul class="dropdown-menu">