From 3d53e8675597599ec13d82c9e564b7c87ecb31fc Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Thu, 12 Jul 2012 20:12:40 +0530 Subject: [PATCH] fixes in log comment and web page saving --- erpnext/website/blog.py | 4 ++-- erpnext/website/web_page.py | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/erpnext/website/blog.py b/erpnext/website/blog.py index f628338ee0..0c287ad1a1 100644 --- a/erpnext/website/blog.py +++ b/erpnext/website/blog.py @@ -58,10 +58,10 @@ def add_comment(args=None): import webnotes.utils comment['comment_date'] = webnotes.utils.pretty_date(comment['creation']) - template_args = { 'comment_list': [comment] } + template_args = { 'comment_list': [comment], 'template': 'html/comment.html' } # get html of comment row - comment_html = website.web_cache.build_html(template_args, 'html/comment.html') + comment_html = website.web_cache.build_html(template_args) return comment_html \ No newline at end of file diff --git a/erpnext/website/web_page.py b/erpnext/website/web_page.py index e03ff0d109..1058d7fa02 100644 --- a/erpnext/website/web_page.py +++ b/erpnext/website/web_page.py @@ -52,7 +52,8 @@ class Page(object): (self.doc.page_name, self.doc.name)) if res and res[0][0] > 0: webnotes.msgprint("""A %s with the same title already exists. - Please change the title and save again.""" % self.doctype, raise_exception=1) + Please change the title of %s and save again.""" + % (self.doctype, self.doc.name), raise_exception=1) def clear_web_cache(self): """