Merge pull request #3636 from neilLasrado/po

Patch for Production Order Track Operation
This commit is contained in:
Nabin Hait 2015-07-13 12:38:45 +05:30
commit 6809b4d86c
2 changed files with 10 additions and 1 deletions

View File

@ -171,4 +171,5 @@ execute:frappe.db.sql("""delete from `tabProject Task`""")
erpnext.patches.v5_0.item_variants
erpnext.patches.v5_0.update_item_desc_in_invoice
erpnext.patches.v5_1.fix_against_account
erpnext.patches.v5_1.fix_credit_days_based_on
erpnext.patches.v5_1.fix_credit_days_based_on
erpnext.patches.v5_1.track_operations

View File

@ -0,0 +1,8 @@
from __future__ import unicode_literals
import frappe
def execute():
frappe.reload_doctype("Production Order")
frappe.db.sql("""Update `tabProduction Order` as po set track_operations=1 where
exists(select name from `tabProduction Order Operation` as po_operation where po_operation.parent = po.name )""")