From a0778fec613155c371ca58221e9300b753231b11 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Mon, 26 Dec 2011 12:28:14 +0530 Subject: [PATCH] Reload gl mapper patches --- erpnext/patches/reload_gl_mapper.py | 6 ++++++ erpnext/patches/update_gle_against_voucher_for_jv.py | 4 ---- 2 files changed, 6 insertions(+), 4 deletions(-) create mode 100644 erpnext/patches/reload_gl_mapper.py diff --git a/erpnext/patches/reload_gl_mapper.py b/erpnext/patches/reload_gl_mapper.py new file mode 100644 index 0000000000..edb00bce69 --- /dev/null +++ b/erpnext/patches/reload_gl_mapper.py @@ -0,0 +1,6 @@ +def execute(): + import webnotes + from webnotes.modules.module_manager import reload_doc + + # reload jv gl mapper + reload_doc('accounts', 'GL Mapper', 'Journal Voucher') diff --git a/erpnext/patches/update_gle_against_voucher_for_jv.py b/erpnext/patches/update_gle_against_voucher_for_jv.py index 96401ba2b8..5a03ec799c 100644 --- a/erpnext/patches/update_gle_against_voucher_for_jv.py +++ b/erpnext/patches/update_gle_against_voucher_for_jv.py @@ -1,11 +1,7 @@ def execute(): import webnotes - from webnotes.modules.module_manager import reload_doc from webnotes.model.code import get_obj - # reload jv gl mapper - reload_doc('accounts', 'GL Mapper', 'Journal Voucher') - # select jv where against_jv exists jv = webnotes.conn.sql("select distinct parent from `tabJournal Voucher Detail` where docstatus = 1 and ifnull(against_jv, '') != ''")