mirror of
https://github.com/almet/copanier.git
synced 2025-04-28 11:32:38 +02:00
Make import / export work with ruptures. Fixes #4
This commit is contained in:
parent
2e524c92c1
commit
931cc77f11
3 changed files with 4 additions and 2 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -3,3 +3,5 @@ __pycache__
|
|||
tmp/
|
||||
db/
|
||||
venv
|
||||
.env
|
||||
.vscode
|
|
@ -178,7 +178,7 @@ class Product(Base):
|
|||
img: str = ""
|
||||
packing: int = None
|
||||
producer: str = ""
|
||||
rupture: bool = False
|
||||
rupture: str = None
|
||||
|
||||
def __str__(self):
|
||||
out = self.name
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
<tbody>
|
||||
{% for product in delivery.get_products_by(producer) %}
|
||||
<tr>
|
||||
<th class="product">{{ product }}</th>
|
||||
<th class="product {% if product.rupture %}rupture{% endif %}">{{ product }} {% if product.rupture %}(RUPTURE !){% endif %}
|
||||
<td>{{ product.price | round(2) }} €</td>
|
||||
{% if delivery.has_packing %}
|
||||
<td class="packing">{% if product.packing %}{{ product.packing }} x {% endif %} {{ product.unit }}</td>
|
||||
|
|
Loading…
Reference in a new issue