Skip to content

Commit bf6f0c6

Browse files
committed
oprava BOM tabulky
1 parent 8ad009a commit bf6f0c6

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

src/OpenIntranet/templates/production.bom_table.hbs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{%for i, row in enumerate(data) %}
22
{% set valid = bson.objectid.ObjectId.is_valid(row['cUST_ID']) %}
33

4-
<!-- {{i}}, {{row}} -->
54
<tr>
65
<td>
76
<div>#{{i+1}}</div>
@@ -58,7 +57,7 @@
5857
{%for packets in row['packets'] %}
5958
{% set count = 0 %}
6059
{% for packet in packets['packets'] %}
61-
{% set this_warehouse = bool(packet['packets']['position'][0]['warehouse'] == current_warehouse) %}
60+
{% set this_warehouse = bool(packet['packets']['position'][0]['warehouse']['_id'] == current_warehouse) %}
6261
{% if this_warehouse %}
6362
<div> <span class="text-muted hover-packet" packet_id="{{packet['packets']['_id']}}"><i class="bi bi-box-seam"></i> {{str(packet['packets']['_id'])[-4:]}}</span> &middot; <b>{{packet['packet_count']}}</b><small>/{{packet['packet_count']}}</small> ks &middot; <span class="text-muted" data-toggle="tooltip" data-placement="top" title="{{ packet['packets']['position'][0]['text']}}">(<i class="bi bi-inboxes"></i> {{ packet['packets']['position'][0]['name']}})</span></div>
6463
{%set count += packet['packet_count'] %}

0 commit comments

Comments
 (0)