From a4fee08d8d069142805fb8c9507807611dbede6d Mon Sep 17 00:00:00 2001 From: Azka Nathan Date: Wed, 16 Aug 2023 09:04:55 +0700 Subject: fix mail template --- indoteknik_custom/models/purchase_order.py | 2 +- indoteknik_custom/views/mail_template_po.xml | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/indoteknik_custom/models/purchase_order.py b/indoteknik_custom/models/purchase_order.py index d73f9037..9e851ef9 100755 --- a/indoteknik_custom/models/purchase_order.py +++ b/indoteknik_custom/models/purchase_order.py @@ -196,7 +196,7 @@ class PurchaseOrder(models.Model): for line in self.order_line: if not line.product_id.purchase_ok: raise UserError("Terdapat barang yang tidak bisa diproses") - if line.price_vendor != 0 and line.price_unit != line.price_vendor: + if line.price_unit != line.price_vendor: send_email = True break diff --git a/indoteknik_custom/views/mail_template_po.xml b/indoteknik_custom/views/mail_template_po.xml index 410520b3..5937f8f2 100644 --- a/indoteknik_custom/views/mail_template_po.xml +++ b/indoteknik_custom/views/mail_template_po.xml @@ -1,12 +1,12 @@ - + PO: Sync Unit Price Purchase Pricelist Your PO ${object.name} - darren@indoteknik.co.id + darren@indoteknik.co.id, tyas@indoteknik.com, azkan4elll@gmail.com @@ -51,7 +51,7 @@

Berikut adalah rincian PO: % for line in object.order_line: - % if line.price_vendor != 0 and line.price_unit != line.price_vendor + % if line.price_unit != line.price_vendor
  • Nama Produk: ${line.product_id.name}
  • Harga Unit dalam PO: Rp ${'{:,.2f}'.format(line.price_unit)}
  • -- cgit v1.2.3