added allow_rename and also fix in autonotification

This commit is contained in:
Rushabh Mehta
2012-12-03 11:33:08 +05:30
parent 08a437bad7
commit 833f070991
14 changed files with 1862 additions and 2178 deletions

View File

@@ -24,13 +24,13 @@ def get_list(arg=None):
webnotes.form_dict['limit_page_length'] = int(webnotes.form_dict['limit_page_length'])
webnotes.form_dict['user'] = webnotes.session['user']
# set all messages as read
webnotes.conn.sql("""UPDATE `tabComment`
set docstatus = 1 where comment_doctype in ('My Company', 'Message')
and comment_docname = %s
""", webnotes.user.name)
if webnotes.form_dict['contact'] == webnotes.session['user']:
# set all messages as read
webnotes.conn.sql("""UPDATE `tabComment`
set docstatus = 1 where comment_doctype in ('My Company', 'Message')
and comment_docname = %s
""", webnotes.user.name)
# return messages
return webnotes.conn.sql("""select * from `tabComment`
where (owner=%(contact)s