Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions posnext/doc_events/sales_invoice.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@


def validate_si(doc,method):
# if 'branch' not in doc.__dict__:
# frappe.throw("Create Branch Accounting Dimensions.")
if doc.pos_profile:
show_branch = frappe.db.get_value("POS Profile",doc.pos_profile,'show_branch')
if 'branch' not in doc.__dict__ and show_branch==1:
frappe.throw("Create Branch Accounting Dimensions.")
if doc.is_return and doc.is_pos:
doc.update_outstanding_for_self = 0
if doc.payments:
Expand Down
Loading