diff --git a/patches/november_2012/production_order_patch.py b/patches/november_2012/production_order_patch.py new file mode 100644 index 00000000000..e4423fcaf4f --- /dev/null +++ b/patches/november_2012/production_order_patch.py @@ -0,0 +1,8 @@ +def execute(): + import webnotes + webnotes.conn.sql("""update `tabProduction Order` + set use_multi_level_bom = if(consider_sa_items='Yes', 0, 1)""") + + webnotes.conn.sql("""update `tabStock Entry` + set use_multi_level_bom = if(consider_sa_items_as_raw_materials='Yes', 0, 1)""") + \ No newline at end of file diff --git a/patches/patch_list.py b/patches/patch_list.py index 0bf4d3c05e9..b9621a89097 100644 --- a/patches/patch_list.py +++ b/patches/patch_list.py @@ -699,4 +699,8 @@ patch_list = [ 'patch_module': 'patches.november_2012', 'patch_file': 'add_theme_to_profile', }, + { + 'patch_module': 'patches.november_2012', + 'patch_file': 'production_order_patch', + }, ] \ No newline at end of file