[fix] [minor] paid amount should be zero if not pos invoice
This commit is contained in:
parent
6c18cbcb4b
commit
21cf403b57
@ -521,6 +521,8 @@ class DocType(SellingController):
|
|||||||
self.make_packing_list()
|
self.make_packing_list()
|
||||||
else:
|
else:
|
||||||
self.doclist = self.doc.clear_table(self.doclist, 'packing_details')
|
self.doclist = self.doc.clear_table(self.doclist, 'packing_details')
|
||||||
|
|
||||||
|
if not cint(self.doc.is_pos):
|
||||||
webnotes.conn.set(self.doc,'paid_amount',0)
|
webnotes.conn.set(self.doc,'paid_amount',0)
|
||||||
|
|
||||||
def check_prev_docstatus(self):
|
def check_prev_docstatus(self):
|
||||||
|
@ -75,7 +75,7 @@ class AccountsController(TransactionBase):
|
|||||||
self.doc.conversion_rate = self.doc.plc_conversion_rate
|
self.doc.conversion_rate = self.doc.plc_conversion_rate
|
||||||
|
|
||||||
if self.meta.get_field("currency"):
|
if self.meta.get_field("currency"):
|
||||||
if self.doc.currency != company_currency:
|
if self.doc.currency and self.doc.currency != company_currency:
|
||||||
if not self.doc.conversion_rate:
|
if not self.doc.conversion_rate:
|
||||||
exchange = self.doc.currency + "-" + company_currency
|
exchange = self.doc.currency + "-" + company_currency
|
||||||
self.doc.conversion_rate = flt(webnotes.conn.get_value("Currency Exchange",
|
self.doc.conversion_rate = flt(webnotes.conn.get_value("Currency Exchange",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user