diff --git a/home/page/activity/activity.txt b/home/page/activity/activity.txt index 57f4b7a0825..f00fac1f462 100644 --- a/home/page/activity/activity.txt +++ b/home/page/activity/activity.txt @@ -1,8 +1,8 @@ [ { - "creation": "2012-06-14 18:44:56", + "creation": "2013-04-09 11:45:31", "docstatus": 0, - "modified": "2013-04-03 14:59:38", + "modified": "2013-04-09 11:47:32", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/patches/april_2013/p04_update_role_in_pages.py b/patches/april_2013/p04_update_role_in_pages.py index 6a4ecc6548a..39590448767 100644 --- a/patches/april_2013/p04_update_role_in_pages.py +++ b/patches/april_2013/p04_update_role_in_pages.py @@ -3,9 +3,10 @@ import webnotes.model def execute(): for p in ["activity", "todo", "questions", "question-view"]: pbean = webnotes.bean("Page", p) - pbean.doclist.append({ - "doctype": "Page Role", - "role": "All", - "parentfield": "roles" - }) - pbean.save() \ No newline at end of file + if len(pbean.doclist) == 1: + pbean.doclist.append({ + "doctype": "Page Role", + "role": "All", + "parentfield": "roles" + }) + pbean.save() \ No newline at end of file diff --git a/utilities/page/question_view/question_view.txt b/utilities/page/question_view/question_view.txt index d6478524c30..87fd053732a 100644 --- a/utilities/page/question_view/question_view.txt +++ b/utilities/page/question_view/question_view.txt @@ -1,20 +1,31 @@ [ { - "owner": "Administrator", + "creation": "2013-04-09 11:45:31", "docstatus": 0, - "creation": "2011-05-04 11:09:50", + "modified": "2013-04-09 11:47:24", "modified_by": "Administrator", - "modified": "2011-03-29 13:54:27" + "owner": "Administrator" }, { - "name": "__common__", + "doctype": "Page", "module": "Utilities", - "standard": "Yes", + "name": "__common__", "page_name": "Question View", - "doctype": "Page" + "standard": "Yes" }, { - "name": "question-view", - "doctype": "Page" + "doctype": "Page Role", + "name": "__common__", + "parent": "question-view", + "parentfield": "roles", + "parenttype": "Page", + "role": "All" + }, + { + "doctype": "Page", + "name": "question-view" + }, + { + "doctype": "Page Role" } ] \ No newline at end of file diff --git a/utilities/page/questions/questions.txt b/utilities/page/questions/questions.txt index 64aaa514d3d..d17cbc45614 100644 --- a/utilities/page/questions/questions.txt +++ b/utilities/page/questions/questions.txt @@ -1,20 +1,31 @@ [ { - "owner": "Administrator", + "creation": "2013-04-09 11:45:31", "docstatus": 0, - "creation": "2011-05-04 11:09:49", + "modified": "2013-04-09 11:47:36", "modified_by": "Administrator", - "modified": "2011-03-29 13:53:57" + "owner": "Administrator" }, { - "name": "__common__", + "doctype": "Page", "module": "Utilities", - "standard": "Yes", + "name": "__common__", "page_name": "Questions", - "doctype": "Page" + "standard": "Yes" }, { - "name": "questions", - "doctype": "Page" + "doctype": "Page Role", + "name": "__common__", + "parent": "questions", + "parentfield": "roles", + "parenttype": "Page", + "role": "All" + }, + { + "doctype": "Page", + "name": "questions" + }, + { + "doctype": "Page Role" } ] \ No newline at end of file