Browse Source

[fixes] hide drop ship section and typo

develop
Saurabh 9 years ago
parent
commit
2c85efe31a
  1. 2
      erpnext/buying/doctype/purchase_order/purchase_order.js
  2. 4
      erpnext/buying/doctype/purchase_order/purchase_order.py

2
erpnext/buying/doctype/purchase_order/purchase_order.js

@ -36,6 +36,8 @@ erpnext.buying.PurchaseOrderController = erpnext.buying.BuyingController.extend(
}
}
cur_frm.set_df_property("drop_ship", "hidden", !allow_delivery);
if(doc.docstatus == 1 && !in_list(["Stopped", "Closed", "Delivered"], doc.status)) {
if (this.frm.has_perm("submit")) {
if(flt(doc.per_billed, 2) < 100 || doc.per_received < 100) {

4
erpnext/buying/doctype/purchase_order/purchase_order.py

@ -51,7 +51,7 @@ class PurchaseOrder(BuyingController):
self.validate_for_subcontracting()
self.validate_minimum_order_qty()
self.create_raw_materials_supplied("supplied_items")
self.set_received_qtyand_billed_amount_for_drop_ship_items()
self.set_received_qty_and_billed_amount_for_drop_ship_items()
def validate_with_previous_doc(self):
super(PurchaseOrder, self).validate_with_previous_doc({
@ -254,7 +254,7 @@ class PurchaseOrder(BuyingController):
return is_drop_ship
def set_received_qtyand_billed_amount_for_drop_ship_items(self):
def set_received_qty_and_billed_amount_for_drop_ship_items(self):
for item in self.items:
if item.delivered_by_supplier == 1:
item.received_qty = item.qty

Loading…
Cancel
Save