brotherton-erpnext/erpnext/patches/jan_mar_2012/website.py

25 lines
717 B
Python
Raw Normal View History

2012-01-25 05:07:35 +00:00
# website patch
import webnotes
def execute():
2012-01-25 09:36:28 +00:00
cleanup_file_data()
return
2012-01-25 05:07:35 +00:00
update_patch_log()
from webnotes.modules import reload_doc
reload_doc('website', 'Module Def', 'Website')
reload_doc('website', 'Role', 'Website Manager')
reload_doc('website', 'doctype', 'home_settings')
reload_doc('website', 'doctype', 'top_bar_settings')
reload_doc('website', 'doctype', 'top_bar_item')
reload_doc('website', 'page', 'home')
2012-01-25 09:36:28 +00:00
def cleanup_file_data():
webnotes.conn.commit()
webnotes.conn.sql("""alter table `tabFile Data` drop column blob_content""")
webnotes.conn.begin()
2012-01-25 05:07:35 +00:00
def update_patch_log():
webnotes.conn.commit()
webnotes.conn.sql("""alter table __PatchLog engine=InnoDB""")
webnotes.conn.begin()