-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathproduct-balance.html
72 lines (58 loc) · 1.92 KB
/
product-balance.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
{% extends 'base.html' %}
{% block title %}
<title>Inventory Managment App</title>
{% endblock %}
{% block content %}
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/list.js/2.3.1/list.min.js"></script>
<main>
<div class="container-fluid">
<h1 class="mt-4">Dashboard</h1>
<ol class="breadcrumb mb-4">
<li class="breadcrumb-item"><a href="/">Dashboard</a></li>
<li class="breadcrumb-item active">Product Balance</li>
</ol>
<div class="card mb-4">
<div class="card-header">Product Balance</div>
<div class="card-body">
<div class="card mb-4">
<div class="card-header">
<i class="fas fa-table mr-1"></i>
Product Balance Report
</div>
<div class="card-body">
<div class="table-responsive">
{% if movements|length < 1 %}
<h4>There are no Movements, add one above</h4>
{% else %}
<table class="table table-bordered" id="dataTable" width="100%" cellspacing="0">
<thead>
<tr>
<th>Product Name</th>
{% for wkey in movements.values()|last %}
<th>{{ wkey }}</th>
{% endfor %}
</tr>
</thead>
<tfoot>
</tfoot>
<tbody>
{% for pkey, values in movements.items() %}
<tr>
<td>{{ pkey }}</td>
{% for wkey in movements.values()|last %}
{% set quantity = values[wkey].quantity if wkey in values else 0 %}
<td>{{ quantity }}</td>
{% endfor %}
</tr>
{% endfor %}
</tbody>
</table>
{% endif %}
</div>
</div>
</div>
</div>
</div>
</div>
</main>
{% endblock %}