From ca600b756c06b0f0b9b16ed9c3a72db1153d5be6 Mon Sep 17 00:00:00 2001 From: Roman Widmann Date: Wed, 7 Feb 2018 13:35:57 +0100 Subject: [PATCH] =?UTF-8?q?F=C3=A4lle=204576,=204574:=20Dokumentenvorlagen?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dp_reports/models/report_helper.py | 11 ++++-- .../dp_reports/reports/report_templates.xml | 4 +- .../static/src/less/report_backend.less | 19 ++++++++++ .../dp_reports_account/reports/invoice.xml | 22 +++++++---- .../dp_reports_sale/reports/sale.xml | 38 +++++++++++++------ 5 files changed, 68 insertions(+), 26 deletions(-) diff --git a/ext/custom-addons/dp_reports/models/report_helper.py b/ext/custom-addons/dp_reports/models/report_helper.py index 462cac2c..4810c15f 100644 --- a/ext/custom-addons/dp_reports/models/report_helper.py +++ b/ext/custom-addons/dp_reports/models/report_helper.py @@ -15,10 +15,13 @@ class ReportHelper(models.AbstractModel): elif not temp and idx != 0: return False else: - temp = temp.__getattribute__(field) - if not temp: - return False - return True + if len(temp) > 1: + temp = temp[0].__getattribute__(field) + else: + temp = temp.__getattribute__(field) + if temp: + return True + return False @api.model def _formatLang(self, value, currency=True): diff --git a/ext/custom-addons/dp_reports/reports/report_templates.xml b/ext/custom-addons/dp_reports/reports/report_templates.xml index 85df0cb9..ad221e47 100644 --- a/ext/custom-addons/dp_reports/reports/report_templates.xml +++ b/ext/custom-addons/dp_reports/reports/report_templates.xml @@ -56,7 +56,7 @@

-
+ @@ -153,7 +153,7 @@


-
+


diff --git a/ext/custom-addons/dp_reports/static/src/less/report_backend.less b/ext/custom-addons/dp_reports/static/src/less/report_backend.less index a414aef3..c298a22f 100644 --- a/ext/custom-addons/dp_reports/static/src/less/report_backend.less +++ b/ext/custom-addons/dp_reports/static/src/less/report_backend.less @@ -14,8 +14,27 @@ body.container { .header { font-size:10pt; font-family: 'Raleway'; + position: relative; } +/* +.header-logo { + position: absolute; + top: 0; + left: 80%; +} + +.header-label { + font-size:20pt; + font-weight: bold; + color: #A72523; + vertical-align: bottom; + position: absolute; + bottom: 0; + left: 0; +} +*/ + .header-label { font-size:20pt; font-weight: bold; diff --git a/ext/custom-addons/dp_reports_account/reports/invoice.xml b/ext/custom-addons/dp_reports_account/reports/invoice.xml index 7464e366..124b716b 100644 --- a/ext/custom-addons/dp_reports_account/reports/invoice.xml +++ b/ext/custom-addons/dp_reports_account/reports/invoice.xml @@ -15,7 +15,7 @@

-
+
@@ -24,10 +24,11 @@


-
-
-
- +
+
+
+
+ UID-Nr.:
@@ -44,8 +45,8 @@
- Angebotsdatum: - ????????? + Rechnungsdatum: + Email: Artikel: @@ -57,7 +58,7 @@ Telefon: Bezeichnung: - ????????? +
@@ -178,6 +179,11 @@

+

+ EORI-Nr.: + +
+

diff --git a/ext/custom-addons/dp_reports_sale/reports/sale.xml b/ext/custom-addons/dp_reports_sale/reports/sale.xml index 5b3b63c2..76f10bf9 100644 --- a/ext/custom-addons/dp_reports_sale/reports/sale.xml +++ b/ext/custom-addons/dp_reports_sale/reports/sale.xml @@ -14,7 +14,7 @@

-
+
@@ -23,10 +23,11 @@


-
-
-
- +
+
+
+
+ UID-Nr.:
@@ -44,7 +45,7 @@
Angebotsdatum: - + Email: Artikel: @@ -52,11 +53,11 @@
Lieferdatum: - + Telefon: Bezeichnung: - ????????? +
@@ -84,12 +85,10 @@
- - + kg - - + kg @@ -188,6 +187,21 @@

+

+ Bitte prüfen Sie bei Anlieferung sofort die Verkackung bzw. Ware auf Beschädigung!
+ Falls die beschädigte Ware angenommen wird, besteht kein Anspruch auf Kostenerstattung bzw. Austausch. +

+ +

+ Gültigkeit: 14 Tage ab Ausstellungsdatum +

+

+ Auftrag erteilt am: ____________________ +

+

+ Unterschrift: ____________________ +

+