From caa0e1db19c0616031f7879d4298ed152b05f557 Mon Sep 17 00:00:00 2001 From: Marius Peter Date: Sun, 1 May 2022 21:38:59 +0200 Subject: Jinja2 templates. --- app/templates/modules/calculator.html | 8 -- app/templates/modules/catalog.html | 35 --------- app/templates/modules/creator.html | 8 -- app/templates/modules/customers.html | 43 +++++++++++ app/templates/modules/invoices.html | 44 +++++++++++ app/templates/modules/logger.html | 136 +++++++++++++++++++++++++++++++++- app/templates/modules/orders.html | 37 +++++++++ app/templates/modules/products.html | 51 +++++++++++++ 8 files changed, 310 insertions(+), 52 deletions(-) delete mode 100644 app/templates/modules/calculator.html delete mode 100644 app/templates/modules/catalog.html delete mode 100644 app/templates/modules/creator.html create mode 100644 app/templates/modules/customers.html create mode 100644 app/templates/modules/invoices.html create mode 100644 app/templates/modules/orders.html create mode 100644 app/templates/modules/products.html (limited to 'app/templates/modules') diff --git a/app/templates/modules/calculator.html b/app/templates/modules/calculator.html deleted file mode 100644 index f951a17..0000000 --- a/app/templates/modules/calculator.html +++ /dev/null @@ -1,8 +0,0 @@ -{% extends "base.html" %} -{% block title %} -Calculator -{% endblock %} - -{% block content %} -insert module content here. -{% endblock %} diff --git a/app/templates/modules/catalog.html b/app/templates/modules/catalog.html deleted file mode 100644 index 857c654..0000000 --- a/app/templates/modules/catalog.html +++ /dev/null @@ -1,35 +0,0 @@ - - -{% extends "base.html" %} -{% block title %} - Catalog -{% endblock %} - -{% block content %} - insert module content here. - -

- Add product to your catalog -

- - - - - - - - - - - - {% for product in catalog %} - - - - - - - {% endfor %} - -
NamePriceSupplierUpdated
{{ product.name }}{{ product.price }}{{ product.supplier }}{{ product.updated }}
-{% endblock %} diff --git a/app/templates/modules/creator.html b/app/templates/modules/creator.html deleted file mode 100644 index 588f428..0000000 --- a/app/templates/modules/creator.html +++ /dev/null @@ -1,8 +0,0 @@ -{% extends "base.html" %} -{% block title %} -Creator -{% endblock %} - -{% block content %} -insert module content here. -{% endblock %} diff --git a/app/templates/modules/customers.html b/app/templates/modules/customers.html new file mode 100644 index 0000000..c693097 --- /dev/null +++ b/app/templates/modules/customers.html @@ -0,0 +1,43 @@ +{# -*- mode: web; -*- #} + +{% extends "base.html" %} +{% block title %} +Customers +{% endblock %} + +{% block content %} +
+ Add customer +
+ + + + + + + + + + + + + {% for customer in customers %} + + + {% if customer.website %} + + {% else %} + + {% endif %} + + + {% if customer.email %} + + {% else %} + + {% endif %} + + {% endfor %} + +
NameCityPhoneE-mail
{{ customer.name }}{{ customer.name }}{{ customer.city }}{{ customer.phone }}{{ customer.email }}
+{% endblock %} diff --git a/app/templates/modules/invoices.html b/app/templates/modules/invoices.html new file mode 100644 index 0000000..76fe267 --- /dev/null +++ b/app/templates/modules/invoices.html @@ -0,0 +1,44 @@ +{# -*- mode: jinja2; -*- #} + +{% extends "base.html" %} +{% block title %} + Products +{% endblock %} + +{% block content %} + +
+ New invoice +
+ + Track your invoices and create new ones here. + + + + + + + + + + + + + {% for invoice in invoices %} + + + + + + + {% if product.date_time_updated %} + + {% else %} + + {% endif %} + + + {% endfor %} + +
ActionsNamePrice (net)Price (gross)Updated
{{ product.name }}{{ product.price_net }}{{ product.price_gross }}{{ product.date_time_updated }}{{ product.date_time_created }}
+{% endblock %} diff --git a/app/templates/modules/logger.html b/app/templates/modules/logger.html index 7ba93b3..f3321e9 100644 --- a/app/templates/modules/logger.html +++ b/app/templates/modules/logger.html @@ -1,8 +1,142 @@ +{# -*- mode: web; -*- #} + {% extends "base.html" %} + {% block title %} Logger {% endblock %} {% block content %} -insert module content here. + + +
+ Add log +
+ +Track operating logs. + +

Most recent target

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
ActionsIDTypeUpdatedNNO3PKCaMgSNaClFeZnBMnCuMoSiNNH4
+ + +
+ +
+
{{ target.primary_key }}Target{{ target.date_time_updated }}{{ target.nno3 }}{{ target.p }}{{ target.k }}{{ target.ca }}{{ target.mg }}{{ target.s }}{{ target.na }}{{ target.cl }}{{ target.fe }}{{ target.zn }}{{ target.b }}{{ target.mn }}{{ target.cu }}{{ target.mo }}{{ target.si }}{{ target.nnh4 }}
+ +

Logs

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + {% for log in logs %} + + + + + {% if log.target == "True" %} + + {% else %} + + {% endif %} + + + + + + + + + + + + + + + + + + + {% endfor %} + +
ActionsIDTypeUpdatedNNO3PKCaMgSNaClFeZnBMnCuMoSiNNH4
+ + +
+ +
+
{{ log.primary_key }}TargetLog{{ log.date_time_updated }}{{ log.nno3 }}{{ log.p }}{{ log.k }}{{ log.ca }}{{ log.mg }}{{ log.s }}{{ log.na }}{{ log.cl }}{{ log.fe }}{{ log.zn }}{{ log.b }}{{ log.mn }}{{ log.cu }}{{ log.mo }}{{ log.si }}{{ log.nnh4 }}
{% endblock %} diff --git a/app/templates/modules/orders.html b/app/templates/modules/orders.html new file mode 100644 index 0000000..bf94d3d --- /dev/null +++ b/app/templates/modules/orders.html @@ -0,0 +1,37 @@ +{# -*- mode: web; -*- #} + +{% extends "base.html" %} +{% block title %} +Orders +{% endblock %} + +{% block content %} +Track your orders and their payment status here. + +

+ Add order +

+ + + + + + + + + + + + + {% for order in orders %} + + + + + + + + {% endfor %} + +
IDDateCustomerContentUpdated
{{ order.id }}{{ order.date }}{{ order.customer }}{{ order.content }}{{ order.updated }}
+{% endblock %} diff --git a/app/templates/modules/products.html b/app/templates/modules/products.html new file mode 100644 index 0000000..97b692a --- /dev/null +++ b/app/templates/modules/products.html @@ -0,0 +1,51 @@ +{# -*- mode: web; -*- #} + +{% extends "base.html" %} +{% block title %} +Products +{% endblock %} + +{% block content %} + + +
+ Add product +
+ +Track products you sell here. + + + + + + + + + + + + + {% for product in products %} + + + + + + + {% if product.date_time_updated %} + + {% else %} + + {% endif %} + + + {% endfor %} + +
ActionsNamePrice (net)Price (gross)Updated
+ + +
+ +
+
{{ product.name }}{{ product.price_net }}{{ product.price_gross }}{{ product.date_time_updated }}{{ product.date_time_created }}
+{% endblock %} -- cgit v1.2.3