diff --git a/erpnext/__init__.py b/erpnext/__init__.py index 58b7955490..b548693fa7 100644 --- a/erpnext/__init__.py +++ b/erpnext/__init__.py @@ -2,7 +2,7 @@ from __future__ import unicode_literals import frappe -__version__ = '7.1.4' +__version__ = '7.1.5' def get_default_company(user=None): '''Get default company for user''' diff --git a/erpnext/buying/doctype/request_for_quotation/request_for_quotation.py b/erpnext/buying/doctype/request_for_quotation/request_for_quotation.py index 78af1efc12..802888d57a 100644 --- a/erpnext/buying/doctype/request_for_quotation/request_for_quotation.py +++ b/erpnext/buying/doctype/request_for_quotation/request_for_quotation.py @@ -131,7 +131,8 @@ class RequestforQuotation(BuyingController): def send_email(self, data, sender, subject, message, attachments): make(subject = subject, content=message,recipients=data.email_id, - sender=sender,attachments = attachments, send_email=True)["name"] + sender=sender,attachments = attachments, send_email=True, + doctype=self.doctype, name=self.name)["name"] frappe.msgprint(_("Email sent to supplier {0}").format(data.supplier)) diff --git a/erpnext/docs/assets/img/articles/withhold-1.png b/erpnext/docs/assets/img/articles/withhold-1.png new file mode 100644 index 0000000000..89b63a0d8b Binary files /dev/null and b/erpnext/docs/assets/img/articles/withhold-1.png differ diff --git a/erpnext/docs/assets/img/articles/withhold-2.gif b/erpnext/docs/assets/img/articles/withhold-2.gif new file mode 100644 index 0000000000..87a92c1edb Binary files /dev/null and b/erpnext/docs/assets/img/articles/withhold-2.gif differ diff --git a/erpnext/docs/user/manual/en/accounts/articles/adjust-withhold-amount-payment-entry.md b/erpnext/docs/user/manual/en/accounts/articles/adjust-withhold-amount-payment-entry.md new file mode 100644 index 0000000000..d469b2883e --- /dev/null +++ b/erpnext/docs/user/manual/en/accounts/articles/adjust-withhold-amount-payment-entry.md @@ -0,0 +1,37 @@ +#Adjust Withhold Amount in the Payment Entry + +###Question + +Let's assume that outstanding against a Sales Invoice is 20,000. When client makes payment, they will only pay 19,600. Rest 400 will be booked under Withhold account. How to manage this scenario in the Payment Entry. + +###Answer + +In the Payment Entry, you can mention Withhold Account in the Deductions or Loss table. Detailed steps below. + +####Step 1: Setup Withhold Account + +Create a Withhold Account in your Chart of Accounts master. + +`Accounts > Chart of Accounts' + +####Step 2: Payment Entry + +To create Payment Entry, go to unpaid Sales Invoice and create click on Make Payment button. + +#####Step 2.1: Enter Payment Amount + +Enter Payment Amount as 19,600. + +Sales Invoice Payment Amount + +#####Step 2.2: Allocate Against Sales Invoice + +Against Sales Invoice, allocate 20,000 (explained in GIF below). + +#####Step 2.3: Add Deduction/Loss Account + +You can notice that there is a difference of 400 in the Payment Amount and the Amount Allocated against Sales Invoice. You can book this difference account under Withhold Account. + +Deduction/Loss Account + + Following same steps, you can also manage difference availed due to Currency Exchange Gain/Loss. \ No newline at end of file diff --git a/erpnext/docs/user/manual/en/accounts/articles/index.txt b/erpnext/docs/user/manual/en/accounts/articles/index.txt index c2fbf70726..77474bd159 100644 --- a/erpnext/docs/user/manual/en/accounts/articles/index.txt +++ b/erpnext/docs/user/manual/en/accounts/articles/index.txt @@ -11,4 +11,5 @@ post-dated-cheque-entry update-stock-option-in-sales-invoice what-is-the-differences-of-total-and-valuation-in-tax-and-charges withdrawing-salary-from-owners-equity-account +adjust-withhold-amount-payment-entry c-form \ No newline at end of file diff --git a/erpnext/stock/doctype/stock_entry/stock_entry.py b/erpnext/stock/doctype/stock_entry/stock_entry.py index a60e945934..1a3c26c2b2 100644 --- a/erpnext/stock/doctype/stock_entry/stock_entry.py +++ b/erpnext/stock/doctype/stock_entry/stock_entry.py @@ -31,7 +31,7 @@ class StockEntry(StockController): item.update(get_bin_details(item.item_code, item.s_warehouse)) def validate(self): - self.pro_doc = None + self.pro_doc = frappe._dict() if self.production_order: self.pro_doc = frappe.get_doc('Production Order', self.production_order) @@ -582,7 +582,7 @@ class StockEntry(StockController): def set_production_order_details(self): if not getattr(self, "pro_doc", None): - self.pro_doc = None + self.pro_doc = frappe._dict() if self.production_order: # common validations