Hi @rmehta used same input as mentioned above. Added
webnotes.errprint(["gl entries: ", gl_entries])
to
def on_submit(self):
self.check_credit_limit()
webnotes.errprint(["gl entries: ", gl_entries])
self.make_gl_entries()
self.update_advance_paid()
self.update_expense_claim()
in /home/frappe/frappe-bench/apps/erpnext/erpnext/accounts/doctype/journal_entry/journal_entry.py
retruned:
{ "data": { "write_off_amount": 0, "naming_series": "JV-", "cheque_date": "12-06-2016", "voucher_type": "Bank Entry", "doctype": "Journal Entry", "owner": "email@email.com", "letter_head": null, "accounts": [ { "creation": "2016-06-14 09:13:21.201316", "doctype": "Journal Entry Account", "exchange_rate": 1.0, "owner": "email@email.com", "cost_center": "costcenter", "modified_by": "email@email.com", "party_type": "Customer", "reference_type": "Sales Invoice", "debit": 0.0, "party": "CUST-00001", "against_account": "Bank", "account_type": "Receivable", "parent": "JV-00014", "reference_name": "SINV-00017", "debit_in_account_currency": 0.0, "party_balance": 0.0, "is_advance": "No", "docstatus": 1, "account_currency": "EUR", "account": "Debtors", "name": "6158168833", "idx": 1, "modified": "2016-06-14 09:13:21.201316", "credit": 0.0, "parenttype": "Journal Entry", "balance": 0, "credit_in_account_currency": 0.0, "parentfield": "accounts" }, { "creation": "2016-06-14 09:13:21.201316", "doctype": "Journal Entry Account", "exchange_rate": 1.0, "owner": "email@email.com", "cost_center": "costcenter", "modified_by": "email@email.com", "party_type": null, "reference_type": null, "debit": 0.0, "party": null, "against_account": "CUST-00001", "account_type": "Bank", "parent": "JV-00014", "reference_name": null, "debit_in_account_currency": 0.0, "party_balance": 0, "is_advance": "No", "docstatus": 1, "account_currency": "EUR", "account": "Bank", "name": "191e28a1ee", "idx": 2, "modified": "2016-06-14 09:13:21.201316", "credit": 0.0, "parenttype": "Journal Entry", "balance": 0, "credit_in_account_currency": 0.0, "parentfield": "accounts" } ], "cheque_no": "tr_w5vHkJcmcN", "bill_no": null, "user_remark": null, "modified_by": "email@email.com", "title": "wc_order_575dcb45bb8d5", "amended_from": null, "docstatus": 1, "total_amount_in_words": "", "bill_date": null, "due_date": null, "creation": "2016-06-14 09:13:21.201316", "parent": null, "multi_currency": 0, "company": "Company", "total_credit": 0.0, "clearance_date": null, "difference": 0.0, "pay_to_recd_from": "Name", "total_amount": 0.0, "remark": "Reference #tr_w5vHkJcmcN dated 06-12-2016", "name": "JV-00014", "idx": 0, "modified": "2016-06-14 09:13:21.201316", "write_off_based_on": "Accounts Receivable", "parenttype": null, "select_print_heading": null, "stock_entry": null, "total_debit": 0.0, "is_opening": "No", "posting_date": "12-06-2016", "parentfield": null } }
Hope to hear from you. N.