Merge branch 'master' of github.com:webnotes/erpnext
This commit is contained in:
commit
787374b79e
@ -11,11 +11,11 @@ def execute():
|
||||
from markdown2 import markdown
|
||||
|
||||
for page in webnotes.conn.sql("""select name, main_section from `tabWeb Page`"""):
|
||||
m = markdown(page[1]).encode("utf8")
|
||||
m = markdown(page[1] or "").encode("utf8")
|
||||
webnotes.conn.set_value("Web Page", page[0], "main_section", m)
|
||||
|
||||
for page in webnotes.conn.sql("""select name, content from `tabBlog`"""):
|
||||
m = markdown(page[1]).encode("utf8")
|
||||
m = markdown(page[1] or "").encode("utf8")
|
||||
webnotes.conn.set_value("Blog", page[0], "content", m)
|
||||
|
||||
# delete website cache
|
||||
|
@ -22,6 +22,7 @@ import os
|
||||
import conf
|
||||
import webnotes
|
||||
import website.utils
|
||||
from webnotes.utils import cstr
|
||||
|
||||
template_map = {
|
||||
'Web Page': 'html/web_page.html',
|
||||
@ -42,7 +43,6 @@ def get_page_html(page_name, comments=''):
|
||||
comments += "\n\npage load status: cache"
|
||||
|
||||
# insert comments
|
||||
import webnotes.utils
|
||||
html += """\n<!-- %s -->""" % webnotes.utils.cstr(comments)
|
||||
|
||||
return html
|
||||
|
Loading…
x
Reference in New Issue
Block a user