brotherton-erpnext/patches/april_2013/p05_fixes_in_reverse_modules.py

13 lines
401 B
Python
Raw Normal View History

2013-11-20 07:29:58 +00:00
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
# License: GNU General Public License v3. See license.txt
import webnotes, json
import webnotes.utils
def execute():
modules = webnotes.get_config().modules
2013-04-11 04:06:20 +00:00
ml = json.loads(webnotes.conn.get_global("hidden_modules") or "[]")
if len(ml) == len(modules.keys()):
webnotes.conn.set_global("hidden_modules", json.dumps([]))