brotherton-erpnext/erpnext/patches/v4_2/default_website_style.py

12 lines
392 B
Python
Raw Normal View History

from __future__ import unicode_literals
2014-08-25 09:47:20 +00:00
import frappe
2016-06-23 12:55:50 +00:00
from frappe.www.style_settings import default_properties
2014-08-25 09:47:20 +00:00
def execute():
frappe.reload_doc('website', 'doctype', 'style_settings')
2014-08-25 09:47:20 +00:00
style_settings = frappe.get_doc("Style Settings", "Style Settings")
if not style_settings.apply_style:
style_settings.update(default_properties)
style_settings.apply_style = 1
style_settings.save()