mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-29 18:04:46 +00:00
[cleanup] purchase common
This commit is contained in:
@@ -293,20 +293,14 @@ class DocType(BuyingController):
|
||||
reconcile_against_document(lst)
|
||||
|
||||
def on_submit(self):
|
||||
purchase_controller = webnotes.get_obj("Purchase Common")
|
||||
purchase_controller.is_item_table_empty(self)
|
||||
|
||||
self.check_prev_docstatus()
|
||||
|
||||
# Check for Approving Authority
|
||||
get_obj('Authorization Control').validate_approving_authority(self.doc.doctype,self.doc.company, self.doc.grand_total)
|
||||
|
||||
get_obj('Authorization Control').validate_approving_authority(self.doc.doctype,
|
||||
self.doc.company, self.doc.grand_total)
|
||||
|
||||
# this sequence because outstanding may get -negative
|
||||
self.make_gl_entries()
|
||||
|
||||
self.update_against_document_in_jv()
|
||||
|
||||
self.update_prevdoc_status()
|
||||
|
||||
def make_gl_entries(self):
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
{
|
||||
"creation": "2013-05-24 19:29:05",
|
||||
"docstatus": 0,
|
||||
"modified": "2013-10-11 13:12:38",
|
||||
"modified": "2013-10-18 13:12:38",
|
||||
"modified_by": "Administrator",
|
||||
"owner": "Administrator"
|
||||
},
|
||||
@@ -323,7 +323,7 @@
|
||||
"fieldname": "packing_details",
|
||||
"fieldtype": "Table",
|
||||
"label": "Packing Details",
|
||||
"options": "Delivery Note Packing Item",
|
||||
"options": "Packed Item",
|
||||
"print_hide": 1,
|
||||
"read_only": 0
|
||||
},
|
||||
|
||||
@@ -75,7 +75,7 @@ def get_item_sales_bom():
|
||||
|
||||
for d in webnotes.conn.sql("""select parenttype, parent, parent_item,
|
||||
item_code, warehouse, -1*qty as total_qty, parent_detail_docname
|
||||
from `tabDelivery Note Packing Item` where docstatus=1""", as_dict=True):
|
||||
from `tabPacked Item` where docstatus=1""", as_dict=True):
|
||||
item_sales_bom.setdefault(d.parenttype, webnotes._dict()).setdefault(d.parent,
|
||||
webnotes._dict()).setdefault(d.parent_item, []).append(d)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user