diff options
Diffstat (limited to 'data/templates/products')
-rw-r--r-- | data/templates/products/entry.html | 41 | ||||
-rw-r--r-- | data/templates/products/index.html | 11 | ||||
-rw-r--r-- | data/templates/products/inventory.html | 49 |
3 files changed, 90 insertions, 11 deletions
diff --git a/data/templates/products/entry.html b/data/templates/products/entry.html index ec13aa6..64b2aa4 100644 --- a/data/templates/products/entry.html +++ b/data/templates/products/entry.html @@ -30,14 +30,39 @@ </table> <div id="restock" style="display: {{{ISADMIN}}};"> - <form action="/products/{{{EAN}}}/restock" class="form-inline"> - <input class="form-control" name="amount" type="number" min="1" placeholder="Amount" title="Amount" /> - <input class="form-control" name="price" type="number" step="0.01" min="0.00" placeholder="Price" title="Price per Piece" /> - <select class="form-control" name="supplier" title="Supplier"> - {{{SUPPLIERS}}} - </select> - <input class="form-control" name="best_before_date" type="date" title="Best Before Date (YYYY-MM-DD)" /> - <button type="submit" class="btn btn-primary"><span class="glyphicon glyphicon-plus" aria-hidden="true"></span></button> + + <form action="/products/{{{EAN}}}/restock" class="form-horizontal"> + <div class="control-group"> + <label class="control-label">Amount</label> + <div class="controls"> + <input name="amount" type="number" min="1" placeholder="Amount" /> + </div> + </div> + <div class="control-group"> + <label class="control-label">Price per Piece</label> + <div class="controls"> + <input name="price" type="number" step="0.01" min="0.00" placeholder="Price" /> + </div> + </div> + <div class="control-group"> + <label class="control-label">Suppplier</label> + <div class="controls"> + <select name="supplier"> + {{{SUPPLIERS}}} + </select> + </div> + </div> + <div class="control-group"> + <label class="control-label">Best Before Date</label> + <div class="controls"> + <input name="best_before_date" type="date" /> + </div> + </div> + <div class="control-group"> + <div class="controls"> + <button type="submit" class="btn btn-primary"><i class="icon-plus"></i> Restock</button> + </div> + </div> </form> </div> diff --git a/data/templates/products/index.html b/data/templates/products/index.html index 8ece21a..ba7e08c 100644 --- a/data/templates/products/index.html +++ b/data/templates/products/index.html @@ -1,8 +1,13 @@ -<a href="/products/bestbefore">product list with best before dates</a> - <table id="producttable" class="table table-bordered table-striped table-condensed"> <thead> - <tr><th>EAN</th></th><th>Name</th><th>Category</th><th>Amount</th><th>Memberprice</th><th>Guestprice</th></tr> + <tr> + <th>EAN</th> + <th>Name</th> + <th>Category</th> + <th>Amount</th> + <th>Memberprice</th> + <th>Guestprice</th> + </tr> </thead> <tbody> {{{DATA}}} diff --git a/data/templates/products/inventory.html b/data/templates/products/inventory.html new file mode 100644 index 0000000..eb02081 --- /dev/null +++ b/data/templates/products/inventory.html @@ -0,0 +1,49 @@ +<h1>Inventory <small>Thanks that you do it! </small></h1> + +<div class="{{{SUCESS_HIDDEN}}} alert alert-success"> + <strong>Success!</strong> Every change was added. Thank you! +</div> + +<div class="alert alert-info"> + <strong>Tip!</strong> You can download an inventory PDF to collect the data offline. + <a href="/products/inventory-pdf" target="_blank" class="btn btn-primary">Only products with amount > 0</a> + <a href="/products/inventory-pdf?all=1" target="_blank" class="btn btn-primary">All products</a> +</div> + +<form action="/products/inventory" method="POST" class="form-horizontal"> + <div class="{{{RESTOCK_HIDDEN}}} form-group"> + <label class="control-label col-sm-3">Select the supplier for the restock action.</label> + <div class="col-sm-3"> + <select name="supplierId" class="form-control"> + {{{SUPPLIERS}}} + </select> + </div> + </div> + <div class="{{{RESTOCK_HIDDEN}}} form-group"> + <label class="control-label col-sm-3">Select the Shop User for loss transaction.</label> + <div class="col-sm-3"> + <select name="userId" class="form-control"> + {{{USERS}}} + </select> + </div> + </div> + <table class="sortable table table-bordered table-striped table-condensed"> + <thead> + <tr> + <th>EAN</th> + <th>Name</th> + <th>Category</th> + <th>Expected Amount</th> + <th>Real Amount</th> + </tr> + </thead> + <tbody> + {{{DATA}}} + </tbody> + </table> + + <div class="pull-right"> + {{{ACTION}}} + </div> + +</form>
\ No newline at end of file |