From 497d363fc1227890f3f3fd35f087fdde42b14448 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Tue, 26 Nov 2013 17:54:53 +0530 Subject: [PATCH 01/12] [permission model] Redesign Conflicts: patches/patch_list.py --- accounts/doctype/account/account.txt | 4 +- accounts/doctype/cost_center/cost_center.txt | 4 +- hr/doctype/employee/employee.py | 4 +- hr/doctype/employee/employee.txt | 5 +-- patches/1311/p06_update_user_properties.py | 38 +++++++++++++++++++ patches/patch_list.py | 1 + .../doctype/customer_group/customer_group.txt | 4 +- setup/doctype/item_group/item_group.txt | 4 +- setup/doctype/sales_person/sales_person.txt | 3 +- setup/doctype/territory/territory.txt | 4 +- 10 files changed, 60 insertions(+), 11 deletions(-) create mode 100644 patches/1311/p06_update_user_properties.py diff --git a/accounts/doctype/account/account.txt b/accounts/doctype/account/account.txt index 459e102d51..c76a41023b 100644 --- a/accounts/doctype/account/account.txt +++ b/accounts/doctype/account/account.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-30 12:49:46", "docstatus": 0, - "modified": "2013-09-24 11:22:18", + "modified": "2013-11-26 17:35:12", "modified_by": "Administrator", "owner": "Administrator" }, @@ -138,6 +138,7 @@ "doctype": "DocField", "fieldname": "parent_account", "fieldtype": "Link", + "ignore_restriction": 1, "label": "Parent Account", "oldfieldname": "parent_account", "oldfieldtype": "Link", @@ -154,7 +155,6 @@ "oldfieldname": "account_type", "oldfieldtype": "Select", "options": "\nFixed Asset Account\nBank or Cash\nExpense Account\nTax\nIncome Account\nChargeable\nWarehouse", - "permlevel": 0, "search_index": 0 }, { diff --git a/accounts/doctype/cost_center/cost_center.txt b/accounts/doctype/cost_center/cost_center.txt index a9c7add775..2c6a5e6748 100644 --- a/accounts/doctype/cost_center/cost_center.txt +++ b/accounts/doctype/cost_center/cost_center.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-23 19:57:17", "docstatus": 0, - "modified": "2013-07-22 15:23:10", + "modified": "2013-11-26 17:34:50", "modified_by": "Administrator", "owner": "Administrator" }, @@ -74,6 +74,7 @@ "doctype": "DocField", "fieldname": "parent_cost_center", "fieldtype": "Link", + "ignore_restriction": 1, "label": "Parent Cost Center", "oldfieldname": "parent_cost_center", "oldfieldtype": "Link", @@ -171,6 +172,7 @@ "fieldname": "old_parent", "fieldtype": "Link", "hidden": 1, + "ignore_restriction": 1, "label": "old_parent", "no_copy": 1, "oldfieldname": "old_parent", diff --git a/hr/doctype/employee/employee.py b/hr/doctype/employee/employee.py index 7129739322..a7deb0fcf4 100644 --- a/hr/doctype/employee/employee.py +++ b/hr/doctype/employee/employee.py @@ -43,9 +43,11 @@ class DocType: self.update_profile() def update_user_default(self): + if not "HR User" in webnotes.local.user.get_roles(): + webnotes.conn.set_default("Employee", self.doc.name, self.doc.user_id, "Restriction") + webnotes.conn.set_default("employee", self.doc.name, self.doc.user_id) webnotes.conn.set_default("employee_name", self.doc.employee_name, self.doc.user_id) - webnotes.conn.set_default("company", self.doc.company, self.doc.user_id) self.set_default_leave_approver() def set_default_leave_approver(self): diff --git a/hr/doctype/employee/employee.txt b/hr/doctype/employee/employee.txt index 856f26ee29..c5b5018ac7 100644 --- a/hr/doctype/employee/employee.txt +++ b/hr/doctype/employee/employee.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 09:04:18", "docstatus": 0, - "modified": "2013-11-03 11:19:10", + "modified": "2013-11-26 16:36:34", "modified_by": "Administrator", "owner": "Administrator" }, @@ -415,6 +415,7 @@ "doctype": "DocField", "fieldname": "reports_to", "fieldtype": "Link", + "ignore_restriction": 1, "label": "Reports to", "oldfieldname": "reports_to", "oldfieldtype": "Link", @@ -749,7 +750,6 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", - "match": "employee", "role": "Employee", "write": 0 }, @@ -757,7 +757,6 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", - "match": "company", "role": "HR User", "write": 1 }, diff --git a/patches/1311/p06_update_user_properties.py b/patches/1311/p06_update_user_properties.py new file mode 100644 index 0000000000..5d5b508c4c --- /dev/null +++ b/patches/1311/p06_update_user_properties.py @@ -0,0 +1,38 @@ +# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors +# License: GNU General Public License v3. See license.txt + +from __future__ import unicode_literals +import webnotes + +def execute(): + update_user_properties() + update_permissions() + webnotes.clear_cache() + +def update_user_properties(): + webnotes.reload_doc("core", "doctype", "docfield") + + for d in webnotes.conn.sql("""select parent, defkey, defvalue from tabDefaultValue + where parent not in ('__global', 'Control Panel')""", as_dict=True): + df = webnotes.conn.sql("""select options from tabDocField + where fieldname=%s and fieldtype='Link'""", d.defkey, as_dict=True) + + if df: + webnotes.conn.sql("""update tabDefaultValue + set defkey=%s, parenttype='Restriction' + where defkey=%s and + parent not in ('__global', 'Control Panel')""", (df[0].options, d.defkey)) + + # remove duplicate restrictions (if they exist) + for d in webnotes.conn.sql("""select parent, defkey, substr(defvalue,0,10), + count(*) as cnt from tabDefaultValue + where parent not in ('__global', 'Control Panel') + group by parent, defkey, defvalue""", as_dict=1): + if d.cnt > 1: + webnotes.conn.sql("""delete from tabDefaultValue where parent=%s, defkey=%s, + defvalue=%s limit %s""", (d.parent, d.defkey, d.defvalue, d.cnt-1)) + +def update_permissions(): + # clear match conditions other than owner + webnotes.conn.sql("""update tabDocPerm set `match`='' + where ifnull(`match`,'') not in ('', 'owner')""") \ No newline at end of file diff --git a/patches/patch_list.py b/patches/patch_list.py index 49c0779872..5da14338bb 100644 --- a/patches/patch_list.py +++ b/patches/patch_list.py @@ -254,6 +254,7 @@ patch_list = [ "patches.1311.p04_update_comments", "patches.1311.p05_website_brand_html", "patches.1311.p06_fix_report_columns", + "patches.1311.p06_update_user_properties", "execute:webnotes.delete_doc('DocType', 'Documentation Tool')", "execute:webnotes.delete_doc('Report', 'Stock Ledger') #2013-11-29", "patches.1312.p01_delete_old_stock_reports", diff --git a/setup/doctype/customer_group/customer_group.txt b/setup/doctype/customer_group/customer_group.txt index f76a2e1ef3..f90c14d336 100644 --- a/setup/doctype/customer_group/customer_group.txt +++ b/setup/doctype/customer_group/customer_group.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:23", "docstatus": 0, - "modified": "2013-11-02 16:52:51", + "modified": "2013-11-26 17:35:45", "modified_by": "Administrator", "owner": "Administrator" }, @@ -66,6 +66,7 @@ "doctype": "DocField", "fieldname": "parent_customer_group", "fieldtype": "Link", + "ignore_restriction": 1, "label": "Parent Customer Group", "oldfieldname": "parent_customer_group", "oldfieldtype": "Link", @@ -127,6 +128,7 @@ "fieldname": "old_parent", "fieldtype": "Link", "hidden": 1, + "ignore_restriction": 1, "label": "old_parent", "no_copy": 1, "oldfieldname": "old_parent", diff --git a/setup/doctype/item_group/item_group.txt b/setup/doctype/item_group/item_group.txt index b365893596..5af9e27ff5 100644 --- a/setup/doctype/item_group/item_group.txt +++ b/setup/doctype/item_group/item_group.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-28 10:35:29", "docstatus": 0, - "modified": "2013-11-02 19:41:37", + "modified": "2013-11-26 17:36:08", "modified_by": "Administrator", "owner": "Administrator" }, @@ -71,6 +71,7 @@ "doctype": "DocField", "fieldname": "parent_item_group", "fieldtype": "Link", + "ignore_restriction": 1, "label": "Parent Item Group", "no_copy": 0, "oldfieldname": "parent_item_group", @@ -166,6 +167,7 @@ "fieldname": "old_parent", "fieldtype": "Link", "hidden": 1, + "ignore_restriction": 1, "label": "old_parent", "no_copy": 1, "oldfieldname": "old_parent", diff --git a/setup/doctype/sales_person/sales_person.txt b/setup/doctype/sales_person/sales_person.txt index 037c6de353..8f08626f3a 100644 --- a/setup/doctype/sales_person/sales_person.txt +++ b/setup/doctype/sales_person/sales_person.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-09-10 10:53:28", + "modified": "2013-11-26 17:35:29", "modified_by": "Administrator", "owner": "Administrator" }, @@ -65,6 +65,7 @@ "doctype": "DocField", "fieldname": "parent_sales_person", "fieldtype": "Link", + "ignore_restriction": 1, "label": "Parent Sales Person", "oldfieldname": "parent_sales_person", "oldfieldtype": "Link", diff --git a/setup/doctype/territory/territory.txt b/setup/doctype/territory/territory.txt index 200f24f82f..b764db5820 100644 --- a/setup/doctype/territory/territory.txt +++ b/setup/doctype/territory/territory.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-11-02 16:59:08", + "modified": "2013-11-26 17:36:23", "modified_by": "Administrator", "owner": "Administrator" }, @@ -68,6 +68,7 @@ "doctype": "DocField", "fieldname": "parent_territory", "fieldtype": "Link", + "ignore_restriction": 1, "label": "Parent Territory", "oldfieldname": "parent_territory", "oldfieldtype": "Link", @@ -136,6 +137,7 @@ "fieldname": "old_parent", "fieldtype": "Link", "hidden": 1, + "ignore_restriction": 1, "label": "old_parent", "no_copy": 1, "oldfieldname": "old_parent", From b1ea6b1f66b87037a540f281bfa8e4c15c571bd1 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Wed, 27 Nov 2013 12:39:15 +0530 Subject: [PATCH 02/12] [permissions] Added Test Cases --- hr/doctype/employee/employee.py | 5 ++++- patches/1311/p06_update_user_properties.py | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/hr/doctype/employee/employee.py b/hr/doctype/employee/employee.py index a7deb0fcf4..46f46da80f 100644 --- a/hr/doctype/employee/employee.py +++ b/hr/doctype/employee/employee.py @@ -43,11 +43,14 @@ class DocType: self.update_profile() def update_user_default(self): + from webnotes.defaults import get_restrictions if not "HR User" in webnotes.local.user.get_roles(): - webnotes.conn.set_default("Employee", self.doc.name, self.doc.user_id, "Restriction") + if not self.doc.user_id in get_restrictions().get("Employee", []): + webnotes.conn.set_default("Employee", self.doc.name, self.doc.user_id, "Restriction") webnotes.conn.set_default("employee", self.doc.name, self.doc.user_id) webnotes.conn.set_default("employee_name", self.doc.employee_name, self.doc.user_id) + webnotes.conn.set_default("company", self.doc.company, self.doc.user_id) self.set_default_leave_approver() def set_default_leave_approver(self): diff --git a/patches/1311/p06_update_user_properties.py b/patches/1311/p06_update_user_properties.py index 5d5b508c4c..de19df2a9b 100644 --- a/patches/1311/p06_update_user_properties.py +++ b/patches/1311/p06_update_user_properties.py @@ -24,7 +24,7 @@ def update_user_properties(): parent not in ('__global', 'Control Panel')""", (df[0].options, d.defkey)) # remove duplicate restrictions (if they exist) - for d in webnotes.conn.sql("""select parent, defkey, substr(defvalue,0,10), + for d in webnotes.conn.sql("""select parent, defkey, defvalue, count(*) as cnt from tabDefaultValue where parent not in ('__global', 'Control Panel') group by parent, defkey, defvalue""", as_dict=1): From fea93d0f65e5b936ae4e41d2aefdf1c6d1e8f07d Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Wed, 27 Nov 2013 14:34:02 +0530 Subject: [PATCH 03/12] [cleanup] [minor] added webnotes.model.delete_doc (module) --- patches/december_2012/production_cleanup.py | 5 ++--- patches/september_2012/deprecate_account_balance.py | 3 +-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/patches/december_2012/production_cleanup.py b/patches/december_2012/production_cleanup.py index 9065666e1a..b8133a90d5 100644 --- a/patches/december_2012/production_cleanup.py +++ b/patches/december_2012/production_cleanup.py @@ -10,9 +10,8 @@ def execute(): rebuild_exploded_bom() def delete_doctypes(): - from webnotes.model import delete_doc - delete_doc("DocType", "Production Control") - delete_doc("DocType", "BOM Control") + webnotes.delete_doc("DocType", "Production Control") + webnotes.delete_doc("DocType", "BOM Control") def rename_module(): diff --git a/patches/september_2012/deprecate_account_balance.py b/patches/september_2012/deprecate_account_balance.py index 1f5ce72305..d39f82cb55 100644 --- a/patches/september_2012/deprecate_account_balance.py +++ b/patches/september_2012/deprecate_account_balance.py @@ -3,11 +3,10 @@ from __future__ import unicode_literals import webnotes -from webnotes.model import delete_doc def execute(): # remove doctypes for dt in ["Period", "Account Balance", "Multi Ledger Report", "Multi Ledger Report Detail", "Period Control", "Reposting Tool", "Lease Agreement", "Lease Installment"]: - delete_doc("DocType", dt) \ No newline at end of file + webnotes.delete_doc("DocType", dt) \ No newline at end of file From 57518fc5f1a76f0d0d7f5ee69f19b8e82f7f2516 Mon Sep 17 00:00:00 2001 From: Rushabh Mehta Date: Wed, 27 Nov 2013 15:05:52 +0530 Subject: [PATCH 04/12] [cleanup] [minor] default+cache related --- buying/doctype/supplier/supplier.py | 3 +-- patches/december_2012/deprecate_tds.py | 3 +-- selling/doctype/customer/customer.py | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/buying/doctype/supplier/supplier.py b/buying/doctype/supplier/supplier.py index 2435d0cc31..bef86650c5 100644 --- a/buying/doctype/supplier/supplier.py +++ b/buying/doctype/supplier/supplier.py @@ -151,8 +151,7 @@ class DocType(TransactionBase): acc = webnotes.conn.sql("select name from `tabAccount` where master_type = 'Supplier' \ and master_name = %s and docstatus < 2", self.doc.name) if acc: - from webnotes.model import delete_doc - delete_doc('Account', acc[0][0]) + webnotes.delete_doc('Account', acc[0][0]) def on_trash(self): self.delete_supplier_address() diff --git a/patches/december_2012/deprecate_tds.py b/patches/december_2012/deprecate_tds.py index e43fbfc482..a5db729d9e 100644 --- a/patches/december_2012/deprecate_tds.py +++ b/patches/december_2012/deprecate_tds.py @@ -3,7 +3,6 @@ def execute(): import webnotes - from webnotes.model import delete_doc from webnotes.model.code import get_obj from webnotes.model.doc import addchild @@ -12,7 +11,7 @@ def execute(): "TDS Rate Chart", "TDS Category", "TDS Control", "TDS Detail", "TDS Payment Detail", "TDS Rate Detail", "TDS Category Account", "Form 16A Ack Detail", "Form 16A Tax Detail"]: - delete_doc("DocType", dt) + webnotes.delete_doc("DocType", dt) webnotes.conn.commit() webnotes.conn.sql("drop table if exists `tab%s`" % dt) diff --git a/selling/doctype/customer/customer.py b/selling/doctype/customer/customer.py index 49296b0b1c..23312ecd67 100644 --- a/selling/doctype/customer/customer.py +++ b/selling/doctype/customer/customer.py @@ -144,8 +144,7 @@ class DocType(TransactionBase): acc = webnotes.conn.sql("select name from `tabAccount` where master_type = 'Customer' \ and master_name = %s and docstatus < 2", self.doc.name) if acc: - from webnotes.model import delete_doc - delete_doc('Account', acc[0][0]) + webnotes.delete_doc('Account', acc[0][0]) def on_trash(self): self.delete_customer_address() From 83638b5f0598305398e0247bf9d42694fd5e907d Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Mon, 9 Dec 2013 12:04:49 +0530 Subject: [PATCH 05/12] [minor] move warehouse user to restrictions --- controllers/buying_controller.py | 3 +- .../leave_application/leave_application.py | 2 +- .../test_leave_application.py | 7 +- .../leave_block_list/test_leave_block_list.py | 8 +- .../production_order/production_order.py | 3 +- ...p07_move_warehouse_user_to_restrictions.py | 12 +++ patches/patch_list.py | 1 + selling/doctype/sales_order/sales_order.py | 3 +- .../doctype/sales_order/test_sales_order.py | 18 ++-- startup/query_handlers.py | 1 - stock/doctype/stock_entry/test_stock_entry.py | 84 ++++++++++--------- .../stock_ledger_entry/stock_ledger_entry.py | 3 +- stock/doctype/warehouse/test_warehouse.py | 4 - stock/utils.py | 27 ------ 14 files changed, 81 insertions(+), 95 deletions(-) create mode 100644 patches/1311/p07_move_warehouse_user_to_restrictions.py diff --git a/controllers/buying_controller.py b/controllers/buying_controller.py index 35b9d25279..ab9f45c08a 100644 --- a/controllers/buying_controller.py +++ b/controllers/buying_controller.py @@ -50,13 +50,12 @@ class BuyingController(StockController): break def validate_warehouse(self): - from stock.utils import validate_warehouse_user, validate_warehouse_company + from stock.utils import validate_warehouse_company warehouses = list(set([d.warehouse for d in self.doclist.get({"doctype": self.tname}) if d.warehouse])) for w in warehouses: - validate_warehouse_user(w) validate_warehouse_company(w, self.doc.company) def get_purchase_tax_details(self): diff --git a/hr/doctype/leave_application/leave_application.py b/hr/doctype/leave_application/leave_application.py index 38ca3061d4..f2f34d7d86 100755 --- a/hr/doctype/leave_application/leave_application.py +++ b/hr/doctype/leave_application/leave_application.py @@ -151,7 +151,7 @@ class DocType(DocListController): employee = webnotes.bean("Employee", self.doc.employee) leave_approvers = [l.leave_approver for l in employee.doclist.get({"parentfield": "employee_leave_approvers"})] - + if len(leave_approvers) and self.doc.leave_approver not in leave_approvers: msgprint(("[" + _("For Employee") + ' "' + self.doc.employee + '"] ' + _("Leave Approver can be one of") + ": " diff --git a/hr/doctype/leave_application/test_leave_application.py b/hr/doctype/leave_application/test_leave_application.py index 9f8a8e1c2e..ee1504145d 100644 --- a/hr/doctype/leave_application/test_leave_application.py +++ b/hr/doctype/leave_application/test_leave_application.py @@ -10,6 +10,9 @@ class TestLeaveApplication(unittest.TestCase): def tearDown(self): webnotes.set_user("Administrator") + # so that this test doesn't affect other tests + webnotes.conn.sql("""delete from `tabEmployee Leave Approver`""") + def _clear_roles(self): webnotes.conn.sql("""delete from `tabUserRole` where parent in ("test@example.com", "test1@example.com", "test2@example.com")""") @@ -162,10 +165,10 @@ class TestLeaveApplication(unittest.TestCase): from webnotes.model.bean import BeanPermissionError self.assertRaises(BeanPermissionError, application.submit) - + webnotes.conn.sql("""delete from `tabEmployee Leave Approver` where parent=%s""", "_T-Employee-0001") - + def _test_leave_approval_valid_leave_approver_insert(self): self._clear_applications() self._add_employee_leave_approver("_T-Employee-0001", "test2@example.com") diff --git a/hr/doctype/leave_block_list/test_leave_block_list.py b/hr/doctype/leave_block_list/test_leave_block_list.py index 0f0da652f3..d2aab71497 100644 --- a/hr/doctype/leave_block_list/test_leave_block_list.py +++ b/hr/doctype/leave_block_list/test_leave_block_list.py @@ -8,23 +8,23 @@ from hr.doctype.leave_block_list.leave_block_list import get_applicable_block_da class TestLeaveBlockList(unittest.TestCase): def tearDown(self): - webnotes.session.user = "Administrator" + webnotes.set_user("Administrator") def test_get_applicable_block_dates(self): - webnotes.session.user = "test@example.com" + webnotes.set_user("test@example.com") webnotes.conn.set_value("Department", "_Test Department", "leave_block_list", "_Test Leave Block List") self.assertTrue("2013-01-02" in [d.block_date for d in get_applicable_block_dates("2013-01-01", "2013-01-03")]) def test_get_applicable_block_dates_for_allowed_user(self): - webnotes.session.user = "test1@example.com" + webnotes.set_user("test1@example.com") webnotes.conn.set_value("Department", "_Test Department 1", "leave_block_list", "_Test Leave Block List") self.assertEquals([], [d.block_date for d in get_applicable_block_dates("2013-01-01", "2013-01-03")]) def test_get_applicable_block_dates_all_lists(self): - webnotes.session.user = "test1@example.com" + webnotes.set_user("test1@example.com") webnotes.conn.set_value("Department", "_Test Department 1", "leave_block_list", "_Test Leave Block List") self.assertTrue("2013-01-02" in diff --git a/manufacturing/doctype/production_order/production_order.py b/manufacturing/doctype/production_order/production_order.py index bcb13f8a22..e00b3dc288 100644 --- a/manufacturing/doctype/production_order/production_order.py +++ b/manufacturing/doctype/production_order/production_order.py @@ -54,10 +54,9 @@ class DocType: self.validate_production_order_against_so() def validate_warehouse(self): - from stock.utils import validate_warehouse_user, validate_warehouse_company + from stock.utils import validate_warehouse_company for w in [self.doc.fg_warehouse, self.doc.wip_warehouse]: - validate_warehouse_user(w) validate_warehouse_company(w, self.doc.company) def validate_production_order_against_so(self): diff --git a/patches/1311/p07_move_warehouse_user_to_restrictions.py b/patches/1311/p07_move_warehouse_user_to_restrictions.py new file mode 100644 index 0000000000..1d7338a330 --- /dev/null +++ b/patches/1311/p07_move_warehouse_user_to_restrictions.py @@ -0,0 +1,12 @@ +# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors +# License: GNU General Public License v3. See license.txt + +from __future__ import unicode_literals +import webnotes + +def execute(): + from core.page.user_properties import user_properties + for warehouse, profile in webnotes.conn.sql("""select parent, user from `tabWarehouse User`"""): + user_properties.add(profile, "Warehouse", warehouse) + + webnotes.delete_doc("DocType", "Warehouse User") \ No newline at end of file diff --git a/patches/patch_list.py b/patches/patch_list.py index 5da14338bb..6c6eb555f7 100644 --- a/patches/patch_list.py +++ b/patches/patch_list.py @@ -263,4 +263,5 @@ patch_list = [ "patches.1311.p07_scheduler_errors_digest", "patches.1311.p08_email_digest_recipients", "execute:webnotes.delete_doc('DocType', 'Warehouse Type')", + "patches.1311.p07_move_warehouse_user_to_restrictions", ] \ No newline at end of file diff --git a/selling/doctype/sales_order/sales_order.py b/selling/doctype/sales_order/sales_order.py index a66c4460a0..d760baf36e 100644 --- a/selling/doctype/sales_order/sales_order.py +++ b/selling/doctype/sales_order/sales_order.py @@ -127,13 +127,12 @@ class DocType(SellingController): if not self.doc.delivery_status: self.doc.delivery_status = 'Not Delivered' def validate_warehouse(self): - from stock.utils import validate_warehouse_user, validate_warehouse_company + from stock.utils import validate_warehouse_company warehouses = list(set([d.reserved_warehouse for d in self.doclist.get({"doctype": self.tname}) if d.reserved_warehouse])) for w in warehouses: - validate_warehouse_user(w) validate_warehouse_company(w, self.doc.company) def validate_with_previous_doc(self): diff --git a/selling/doctype/sales_order/test_sales_order.py b/selling/doctype/sales_order/test_sales_order.py index 1549b24c89..808adbafb4 100644 --- a/selling/doctype/sales_order/test_sales_order.py +++ b/selling/doctype/sales_order/test_sales_order.py @@ -6,6 +6,9 @@ from webnotes.utils import flt import unittest class TestSalesOrder(unittest.TestCase): + def tearDown(self): + webnotes.set_user("Administrator") + def test_make_material_request(self): from selling.doctype.sales_order.sales_order import make_material_request @@ -276,28 +279,29 @@ class TestSalesOrder(unittest.TestCase): so.doclist[1].reserved_warehouse, 20.0) def test_warehouse_user(self): + webnotes.defaults.add_default("Warehouse", "_Test Warehouse 1 - _TC1", "test@example.com", "Restriction") webnotes.bean("Profile", "test@example.com").get_controller()\ .add_roles("Sales User", "Sales Manager", "Material User", "Material Manager") webnotes.bean("Profile", "test2@example.com").get_controller()\ .add_roles("Sales User", "Sales Manager", "Material User", "Material Manager") - webnotes.session.user = "test@example.com" + webnotes.set_user("test@example.com") - from stock.utils import UserNotAllowedForWarehouse + from webnotes.model.bean import BeanPermissionError so = webnotes.bean(copy = test_records[0]) so.doc.company = "_Test Company 1" so.doc.conversion_rate = 0.02 so.doc.plc_conversion_rate = 0.02 so.doclist[1].reserved_warehouse = "_Test Warehouse 2 - _TC1" - self.assertRaises(UserNotAllowedForWarehouse, so.insert) + self.assertRaises(BeanPermissionError, so.insert) - webnotes.session.user = "test2@example.com" + webnotes.set_user("test2@example.com") so.insert() + + webnotes.defaults.clear_default("Warehouse", "_Test Warehouse 1 - _TC1", "test@example.com", parenttype="Restriction") - webnotes.session.user = "Administrator" - -test_dependencies = ["Sales BOM"] +test_dependencies = ["Sales BOM", "Currency Exchange"] test_records = [ [ diff --git a/startup/query_handlers.py b/startup/query_handlers.py index 753d088de5..72ad8fa455 100644 --- a/startup/query_handlers.py +++ b/startup/query_handlers.py @@ -4,6 +4,5 @@ from __future__ import unicode_literals standard_queries = { - "Warehouse": "stock.utils.get_warehouse_list", "Customer": "selling.utils.get_customer_list", } \ No newline at end of file diff --git a/stock/doctype/stock_entry/test_stock_entry.py b/stock/doctype/stock_entry/test_stock_entry.py index d6f34f645a..781fca4455 100644 --- a/stock/doctype/stock_entry/test_stock_entry.py +++ b/stock/doctype/stock_entry/test_stock_entry.py @@ -7,9 +7,9 @@ from webnotes.utils import flt from stock.doctype.serial_no.serial_no import * from stock.doctype.purchase_receipt.test_purchase_receipt import set_perpetual_inventory - class TestStockEntry(unittest.TestCase): def tearDown(self): + webnotes.set_user("Administrator") set_perpetual_inventory(0) if hasattr(self, "old_default_company"): webnotes.conn.set_default("company", self.old_default_company) @@ -39,46 +39,6 @@ class TestStockEntry(unittest.TestCase): webnotes.conn.set_default("company", self.old_default_company) - def test_warehouse_company_validation(self): - set_perpetual_inventory(0) - self._clear_stock_account_balance() - webnotes.bean("Profile", "test2@example.com").get_controller()\ - .add_roles("Sales User", "Sales Manager", "Material User", "Material Manager") - webnotes.session.user = "test2@example.com" - - from stock.utils import InvalidWarehouseCompany - st1 = webnotes.bean(copy=test_records[0]) - st1.doclist[1].t_warehouse="_Test Warehouse 2 - _TC1" - st1.insert() - self.assertRaises(InvalidWarehouseCompany, st1.submit) - - webnotes.session.user = "Administrator" - - def test_warehouse_user(self): - set_perpetual_inventory(0) - from stock.utils import UserNotAllowedForWarehouse - - webnotes.bean("Profile", "test@example.com").get_controller()\ - .add_roles("Sales User", "Sales Manager", "Material User", "Material Manager") - - webnotes.bean("Profile", "test2@example.com").get_controller()\ - .add_roles("Sales User", "Sales Manager", "Material User", "Material Manager") - webnotes.session.user = "test@example.com" - st1 = webnotes.bean(copy=test_records[0]) - st1.doc.company = "_Test Company 1" - st1.doclist[1].t_warehouse="_Test Warehouse 2 - _TC1" - st1.insert() - self.assertRaises(UserNotAllowedForWarehouse, st1.submit) - - webnotes.session.user = "test2@example.com" - st1 = webnotes.bean(copy=test_records[0]) - st1.doc.company = "_Test Company 1" - st1.doclist[1].t_warehouse="_Test Warehouse 2 - _TC1" - st1.insert() - st1.submit() - - webnotes.session.user = "Administrator" - def test_material_receipt_gl_entry(self): self._clear_stock_account_balance() set_perpetual_inventory() @@ -799,7 +759,49 @@ class TestStockEntry(unittest.TestCase): serial_no = get_serial_nos(se.doclist[1].serial_no)[0] self.assertFalse(webnotes.conn.get_value("Serial No", serial_no, "warehouse")) + + def test_warehouse_company_validation(self): + set_perpetual_inventory(0) + self._clear_stock_account_balance() + webnotes.bean("Profile", "test2@example.com").get_controller()\ + .add_roles("Sales User", "Sales Manager", "Material User", "Material Manager") + webnotes.set_user("test2@example.com") + from stock.utils import InvalidWarehouseCompany + st1 = webnotes.bean(copy=test_records[0]) + st1.doclist[1].t_warehouse="_Test Warehouse 2 - _TC1" + st1.insert() + self.assertRaises(InvalidWarehouseCompany, st1.submit) + + # permission tests + def test_warehouse_user(self): + import webnotes.defaults + from webnotes.model.bean import BeanPermissionError + set_perpetual_inventory(0) + + webnotes.defaults.add_default("Warehouse", "_Test Warehouse 1 - _TC1", "test@example.com", "Restriction") + webnotes.defaults.add_default("Warehouse", "_Test Warehouse 2 - _TC1", "test2@example.com", "Restriction") + webnotes.bean("Profile", "test@example.com").get_controller()\ + .add_roles("Sales User", "Sales Manager", "Material User", "Material Manager") + webnotes.bean("Profile", "test2@example.com").get_controller()\ + .add_roles("Sales User", "Sales Manager", "Material User", "Material Manager") + + webnotes.set_user("test@example.com") + st1 = webnotes.bean(copy=test_records[0]) + st1.doc.company = "_Test Company 1" + st1.doclist[1].t_warehouse="_Test Warehouse 2 - _TC1" + self.assertRaises(BeanPermissionError, st1.insert) + + webnotes.set_user("test2@example.com") + st1 = webnotes.bean(copy=test_records[0]) + st1.doc.company = "_Test Company 1" + st1.doclist[1].t_warehouse="_Test Warehouse 2 - _TC1" + st1.insert() + st1.submit() + + webnotes.defaults.clear_default("Warehouse", "_Test Warehouse 1 - _TC1", "test@example.com", parenttype="Restriction") + webnotes.defaults.clear_default("Warehouse", "_Test Warehouse 2 - _TC1", "test2@example.com", parenttype="Restriction") + def make_serialized_item(): se = webnotes.bean(copy=test_records[0]) se.doclist[1].item_code = "_Test Serialized Item With Series" diff --git a/stock/doctype/stock_ledger_entry/stock_ledger_entry.py b/stock/doctype/stock_ledger_entry/stock_ledger_entry.py index f059451099..e988434cb9 100644 --- a/stock/doctype/stock_ledger_entry/stock_ledger_entry.py +++ b/stock/doctype/stock_ledger_entry/stock_ledger_entry.py @@ -13,10 +13,9 @@ class DocType(DocListController): self.doclist = doclist def validate(self): - from stock.utils import validate_warehouse_user, validate_warehouse_company + from stock.utils import validate_warehouse_company self.validate_mandatory() self.validate_item() - validate_warehouse_user(self.doc.warehouse) validate_warehouse_company(self.doc.warehouse, self.doc.company) self.scrub_posting_time() diff --git a/stock/doctype/warehouse/test_warehouse.py b/stock/doctype/warehouse/test_warehouse.py index ffc5a284d9..b0e7641a28 100644 --- a/stock/doctype/warehouse/test_warehouse.py +++ b/stock/doctype/warehouse/test_warehouse.py @@ -19,10 +19,6 @@ test_records = [ "warehouse_name": "_Test Warehouse 2", "create_account_under": "Stock Assets - _TC", "company": "_Test Company 1" - }, { - "doctype": "Warehouse User", - "parentfield": "warehouse_users", - "user": "test2@example.com" }], [{ "doctype": "Warehouse", diff --git a/stock/utils.py b/stock/utils.py index 4f5e11a657..c6e5f2d6b1 100644 --- a/stock/utils.py +++ b/stock/utils.py @@ -8,7 +8,6 @@ from webnotes.utils import flt, cstr, nowdate, add_days, cint from webnotes.defaults import get_global_default from webnotes.utils.email_lib import sendmail -class UserNotAllowedForWarehouse(webnotes.ValidationError): pass class InvalidWarehouseCompany(webnotes.ValidationError): pass def get_stock_balance_on(warehouse, posting_date=None): @@ -191,33 +190,7 @@ def get_valid_serial_nos(sr_nos, qty=0, item_code=''): raise_exception=1) return valid_serial_nos - -def get_warehouse_list(doctype, txt, searchfield, start, page_len, filters): - """used in search queries""" - wlist = [] - for w in webnotes.conn.sql_list("""select name from tabWarehouse - where name like '%%%s%%'""" % txt): - if webnotes.session.user=="Administrator": - wlist.append([w]) - else: - warehouse_users = webnotes.conn.sql_list("""select user from `tabWarehouse User` - where parent=%s""", w) - if not warehouse_users: - wlist.append([w]) - elif webnotes.session.user in warehouse_users: - wlist.append([w]) - return wlist -def validate_warehouse_user(warehouse): - if webnotes.session.user=="Administrator" or not warehouse: - return - warehouse_users = [p[0] for p in webnotes.conn.sql("""select user from `tabWarehouse User` - where parent=%s""", warehouse)] - - if warehouse_users and not (webnotes.session.user in warehouse_users): - webnotes.throw(_("Not allowed entry in Warehouse") \ - + ": " + warehouse, UserNotAllowedForWarehouse) - def validate_warehouse_company(warehouse, company): warehouse_company = webnotes.conn.get_value("Warehouse", warehouse, "company") if warehouse_company and warehouse_company != company: From bcf2422848d0a12eedd57e725815f45113371626 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Fri, 13 Dec 2013 11:51:50 +0530 Subject: [PATCH 06/12] [minor] user properties and leave application --- .../accounts_browser/accounts_browser.css | 29 ----------- .../page/accounts_browser/accounts_browser.js | 9 ++-- .../leave_application/leave_application.py | 5 ++ .../test_leave_application.py | 4 +- patches/1311/p06_update_user_properties.py | 52 ++++++++++++++++--- .../doctype/customer_issue/customer_issue.txt | 4 +- utilities/demo/make_demo.py | 16 +++--- 7 files changed, 67 insertions(+), 52 deletions(-) delete mode 100644 accounts/page/accounts_browser/accounts_browser.css diff --git a/accounts/page/accounts_browser/accounts_browser.css b/accounts/page/accounts_browser/accounts_browser.css deleted file mode 100644 index 718da365da..0000000000 --- a/accounts/page/accounts_browser/accounts_browser.css +++ /dev/null @@ -1,29 +0,0 @@ -select.accbrowser-company-select { - width: 200px; - margin-top: 2px; - margin-left: 10px; -} - -span.tree-node-toolbar { - padding: 2px; - margin-left: 15px; - border-radius: 3px; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; - border-radius: 3px; - background-color: #ddd; -} - -.tree-area a.selected { - font-weight: bold; - text-decoration: underline; -} - -span.balance-area { - float: right; - height: 13px; -} - -span.balance-bold { - font-weight: bold; -} \ No newline at end of file diff --git a/accounts/page/accounts_browser/accounts_browser.js b/accounts/page/accounts_browser/accounts_browser.js index 235e6ab541..66a40b160e 100644 --- a/accounts/page/accounts_browser/accounts_browser.js +++ b/accounts/page/accounts_browser/accounts_browser.js @@ -8,7 +8,6 @@ // see ledger pscript['onload_Accounts Browser'] = function(wrapper){ - console.log($(wrapper).html()); wn.ui.make_app_page({ parent: wrapper, single_column: true @@ -122,14 +121,14 @@ erpnext.AccountsChart = Class.extend({ } // bold - $('.balance-bold').removeClass('balance-bold'); // deselect - $(link).parent().find('.balance-area:first').addClass('balance-bold'); // select + $('.bold').removeClass('bold'); // deselect + $(link).parent().find('.balance-area:first').addClass('bold'); // select }, onrender: function(treenode) { if (ctype == 'Account' && treenode.data) { if(treenode.data.balance) { - treenode.parent.append('' + treenode.parent.append('' + format_currency(treenode.data.balance, treenode.data.currency) + ''); } @@ -142,7 +141,7 @@ erpnext.AccountsChart = Class.extend({ var data = $(link).data('node-data'); if(!data) return; - link.toolbar = $('').insertAfter(link); + link.toolbar = $('').insertAfter(link); var node_links = []; // edit diff --git a/hr/doctype/leave_application/leave_application.py b/hr/doctype/leave_application/leave_application.py index f2f34d7d86..b547d3d2c9 100755 --- a/hr/doctype/leave_application/leave_application.py +++ b/hr/doctype/leave_application/leave_application.py @@ -12,6 +12,7 @@ from webnotes import msgprint class LeaveDayBlockedError(webnotes.ValidationError): pass class OverlapError(webnotes.ValidationError): pass class InvalidLeaveApproverError(webnotes.ValidationError): pass +class LeaveApproverIdentityError(webnotes.ValidationError): pass from webnotes.model.controller import DocListController class DocType(DocListController): @@ -161,6 +162,10 @@ class DocType(DocListController): where parent=%s and role='Leave Approver'""", self.doc.leave_approver): msgprint(get_fullname(self.doc.leave_approver) + ": " \ + _("does not have role 'Leave Approver'"), raise_exception=InvalidLeaveApproverError) + + elif self.doc.docstatus==1 and len(leave_approvers) and self.doc.leave_approver != webnotes.session.user: + msgprint(_("Only the selected Leave Approver can submit this Leave Application"), + raise_exception=LeaveApproverIdentityError) def notify_employee(self, status): employee = webnotes.doc("Employee", self.doc.employee) diff --git a/hr/doctype/leave_application/test_leave_application.py b/hr/doctype/leave_application/test_leave_application.py index ee1504145d..2c4f3763a9 100644 --- a/hr/doctype/leave_application/test_leave_application.py +++ b/hr/doctype/leave_application/test_leave_application.py @@ -163,8 +163,8 @@ class TestLeaveApplication(unittest.TestCase): webnotes.set_user("test1@example.com") application.doc.status = "Approved" - from webnotes.model.bean import BeanPermissionError - self.assertRaises(BeanPermissionError, application.submit) + from hr.doctype.leave_application.leave_application import LeaveApproverIdentityError + self.assertRaises(LeaveApproverIdentityError, application.submit) webnotes.conn.sql("""delete from `tabEmployee Leave Approver` where parent=%s""", "_T-Employee-0001") diff --git a/patches/1311/p06_update_user_properties.py b/patches/1311/p06_update_user_properties.py index de19df2a9b..51da19f1ba 100644 --- a/patches/1311/p06_update_user_properties.py +++ b/patches/1311/p06_update_user_properties.py @@ -6,7 +6,9 @@ import webnotes def execute(): update_user_properties() + update_user_match() update_permissions() + remove_duplicate_restrictions() webnotes.clear_cache() def update_user_properties(): @@ -23,6 +25,49 @@ def update_user_properties(): where defkey=%s and parent not in ('__global', 'Control Panel')""", (df[0].options, d.defkey)) +def update_user_match(): + import webnotes.defaults + doctype_matches = {} + for doctype, match in webnotes.conn.sql("""select parent, `match` from `tabDocPerm` + where `match` like %s""", "%:user"): + doctype_matches.setdefault(doctype, []).append(match) + + for doctype, user_matches in doctype_matches.items(): + + # get permissions of this doctype + perms = webnotes.conn.sql("""select role, `match` from `tabDocPerm` + where parent=%s and permlevel=0 and read=1""", doctype, as_dict=True) + + # for each user with roles of this doctype, check if match condition applies + for profile in webnotes.conn.sql_list("""select name from `tabProfile` + where enabled=1 and user_type='System User'"""): + + roles = webnotes.get_roles(profile) + + user_match = False + for perm in perms: + if perm.role in roles and (perm.match and \ + (perm.match.endswith(":user") or perm.match.endswith(":profile"))): + user_match = True + break + + if not user_match: + continue + + # if match condition applies, restrict that user + # add that doc's restriction to that user + for match in user_matches: + for name in webnotes.conn.sql_list("""select name from `tab{doctype}` + where `{field}`=%s""".format(doctype=doctype, field=match.split(":")[0]), profile): + + webnotes.defaults.add_default(doctype, name, profile, "Restriction") + +def update_permissions(): + # clear match conditions other than owner + webnotes.conn.sql("""update tabDocPerm set `match`='' + where ifnull(`match`,'') not in ('', 'owner')""") + +def remove_duplicate_restrictions(): # remove duplicate restrictions (if they exist) for d in webnotes.conn.sql("""select parent, defkey, defvalue, count(*) as cnt from tabDefaultValue @@ -30,9 +75,4 @@ def update_user_properties(): group by parent, defkey, defvalue""", as_dict=1): if d.cnt > 1: webnotes.conn.sql("""delete from tabDefaultValue where parent=%s, defkey=%s, - defvalue=%s limit %s""", (d.parent, d.defkey, d.defvalue, d.cnt-1)) - -def update_permissions(): - # clear match conditions other than owner - webnotes.conn.sql("""update tabDocPerm set `match`='' - where ifnull(`match`,'') not in ('', 'owner')""") \ No newline at end of file + defvalue=%s limit %s""", (d.parent, d.defkey, d.defvalue, d.cnt-1)) \ No newline at end of file diff --git a/support/doctype/customer_issue/customer_issue.txt b/support/doctype/customer_issue/customer_issue.txt index f9fbc6bd6a..c677654ccc 100644 --- a/support/doctype/customer_issue/customer_issue.txt +++ b/support/doctype/customer_issue/customer_issue.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:30", "docstatus": 0, - "modified": "2013-11-02 16:59:22", + "modified": "2013-12-11 11:14:32", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, @@ -13,7 +13,7 @@ "is_submittable": 0, "module": "Support", "name": "__common__", - "search_fields": "status,customer,customer_name,allocated_to,allocated_on, territory" + "search_fields": "status,customer,customer_name,territory" }, { "doctype": "DocField", diff --git a/utilities/demo/make_demo.py b/utilities/demo/make_demo.py index b98fd7ac9c..87c0527578 100644 --- a/utilities/demo/make_demo.py +++ b/utilities/demo/make_demo.py @@ -3,7 +3,7 @@ import webnotes, os, datetime import webnotes.utils -from webnotes.utils import random_string +from webnotes.utils import random_string, cstr from webnotes.widgets import query_report import random import json @@ -153,7 +153,7 @@ def run_stock(current_date): for po in list(set([r[0] for r in query_report.run(report)["result"] if r[0]!="Total"]))[:how_many("Purchase Receipt")]: pr = webnotes.bean(make_purchase_receipt(po)) pr.doc.posting_date = current_date - pr.doc.fiscal_year = current_date.year + pr.doc.fiscal_year = cstr(current_date.year) pr.insert() try: pr.submit() @@ -169,7 +169,7 @@ def run_stock(current_date): for so in list(set([r[0] for r in query_report.run(report)["result"] if r[0]!="Total"]))[:how_many("Delivery Note")]: dn = webnotes.bean(make_delivery_note(so)) dn.doc.posting_date = current_date - dn.doc.fiscal_year = current_date.year + dn.doc.fiscal_year = cstr(current_date.year) dn.insert() try: dn.submit() @@ -192,7 +192,7 @@ def run_purchase(current_date): mr = webnotes.new_bean("Material Request") mr.doc.material_request_type = "Purchase" mr.doc.transaction_date = current_date - mr.doc.fiscal_year = current_date.year + mr.doc.fiscal_year = cstr(current_date.year) mr.doclist.append({ "doctype": "Material Request Item", "parentfield": "indent_details", @@ -211,7 +211,7 @@ def run_purchase(current_date): if row[0] != "Total": sq = webnotes.bean(make_supplier_quotation(row[0])) sq.doc.transaction_date = current_date - sq.doc.fiscal_year = current_date.year + sq.doc.fiscal_year = cstr(current_date.year) sq.insert() sq.submit() webnotes.conn.commit() @@ -224,7 +224,7 @@ def run_purchase(current_date): if row[0] != "Total": po = webnotes.bean(make_purchase_order(row[0])) po.doc.transaction_date = current_date - po.doc.fiscal_year = current_date.year + po.doc.fiscal_year = cstr(current_date.year) po.insert() po.submit() webnotes.conn.commit() @@ -283,7 +283,7 @@ def make_stock_entry_from_pro(pro_id, purpose, current_date): try: st = webnotes.bean(make_stock_entry(pro_id, purpose)) st.doc.posting_date = current_date - st.doc.fiscal_year = current_date.year + st.doc.fiscal_year = cstr(current_date.year) for d in st.doclist.get({"parentfield": "mtn_details"}): d.expense_account = "Stock Adjustment - " + company_abbr d.cost_center = "Main - " + company_abbr @@ -303,7 +303,7 @@ def make_quotation(current_date): "customer": get_random("Customer"), "order_type": "Sales", "transaction_date": current_date, - "fiscal_year": current_date.year + "fiscal_year": cstr(current_date.year) }]) add_random_children(b, { From 620145c59a494547d489d4f2b1e6950e6ec33112 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Mon, 16 Dec 2013 19:28:11 +0530 Subject: [PATCH 07/12] [minor] patches for restriction --- patches/1311/p08_restriction_management.py | 14 ++++++++++++++ patches/patch_list.py | 1 + 2 files changed, 15 insertions(+) create mode 100644 patches/1311/p08_restriction_management.py diff --git a/patches/1311/p08_restriction_management.py b/patches/1311/p08_restriction_management.py new file mode 100644 index 0000000000..e89d6d0a02 --- /dev/null +++ b/patches/1311/p08_restriction_management.py @@ -0,0 +1,14 @@ +# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors +# License: GNU General Public License v3. See license.txt + +from __future__ import unicode_literals +import webnotes + +def execute(): + # add role "Restriction Manager" + if not webnotes.conn.exists("Role", "Restriction Manager"): + webnotes.bean({"doctype": "Role", "role_name": "Restriction Manager"}).insert() + + # reset Page perms + from core.page.permission_manager.permission_manager import reset + reset("Page") \ No newline at end of file diff --git a/patches/patch_list.py b/patches/patch_list.py index 6c6eb555f7..efc58538ff 100644 --- a/patches/patch_list.py +++ b/patches/patch_list.py @@ -264,4 +264,5 @@ patch_list = [ "patches.1311.p08_email_digest_recipients", "execute:webnotes.delete_doc('DocType', 'Warehouse Type')", "patches.1311.p07_move_warehouse_user_to_restrictions", + "patches.1311.p08_restriction_management", ] \ No newline at end of file From 2298d59b8b50c1ad30fea7a9a17afe6e8297f68a Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Tue, 17 Dec 2013 19:04:08 +0530 Subject: [PATCH 08/12] [patch] new permission system --- ..._restriction_management.py => p08_new_permissions.py} | 9 ++++----- patches/patch_list.py | 2 +- 2 files changed, 5 insertions(+), 6 deletions(-) rename patches/1311/{p08_restriction_management.py => p08_new_permissions.py} (60%) diff --git a/patches/1311/p08_restriction_management.py b/patches/1311/p08_new_permissions.py similarity index 60% rename from patches/1311/p08_restriction_management.py rename to patches/1311/p08_new_permissions.py index e89d6d0a02..301c15e7f0 100644 --- a/patches/1311/p08_restriction_management.py +++ b/patches/1311/p08_new_permissions.py @@ -5,10 +5,9 @@ from __future__ import unicode_literals import webnotes def execute(): - # add role "Restriction Manager" - if not webnotes.conn.exists("Role", "Restriction Manager"): - webnotes.bean({"doctype": "Role", "role_name": "Restriction Manager"}).insert() - # reset Page perms from core.page.permission_manager.permission_manager import reset - reset("Page") \ No newline at end of file + reset("Page") + + # patch to move print, email into DocPerm + \ No newline at end of file diff --git a/patches/patch_list.py b/patches/patch_list.py index efc58538ff..30a4fc92ac 100644 --- a/patches/patch_list.py +++ b/patches/patch_list.py @@ -264,5 +264,5 @@ patch_list = [ "patches.1311.p08_email_digest_recipients", "execute:webnotes.delete_doc('DocType', 'Warehouse Type')", "patches.1311.p07_move_warehouse_user_to_restrictions", - "patches.1311.p08_restriction_management", + "patches.1311.p08_new_permissions", ] \ No newline at end of file From 8a436500f0423bcd0d84a35b2620fe9b75a55768 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Thu, 19 Dec 2013 19:11:30 +0530 Subject: [PATCH 09/12] [refactor] Client-side permission handling --- accounts/doctype/account/account.js | 2 +- .../p02_update_user_properties.py} | 0 .../p03_move_warehouse_user_to_restrictions.py} | 0 .../p04_new_permissions.py} | 0 patches/patch_list.py | 8 ++++---- setup/doctype/customer_group/customer_group.js | 2 +- setup/doctype/item_group/item_group.js | 2 +- setup/doctype/sales_person/sales_person.js | 2 +- setup/doctype/territory/territory.js | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) rename patches/{1311/p06_update_user_properties.py => 1312/p02_update_user_properties.py} (100%) rename patches/{1311/p07_move_warehouse_user_to_restrictions.py => 1312/p03_move_warehouse_user_to_restrictions.py} (100%) rename patches/{1311/p08_new_permissions.py => 1312/p04_new_permissions.py} (100%) diff --git a/accounts/doctype/account/account.js b/accounts/doctype/account/account.js index 8837586b06..407b2d452d 100644 --- a/accounts/doctype/account/account.js +++ b/accounts/doctype/account/account.js @@ -37,7 +37,7 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn) { // read-only for root accounts if(!doc.parent_account) { - cur_frm.perm = [[1,0,0], [1,0,0]]; + cur_frm.set_read_only(); cur_frm.set_intro(wn._("This is a root account and cannot be edited.")); } else { // credit days and type if customer or supplier diff --git a/patches/1311/p06_update_user_properties.py b/patches/1312/p02_update_user_properties.py similarity index 100% rename from patches/1311/p06_update_user_properties.py rename to patches/1312/p02_update_user_properties.py diff --git a/patches/1311/p07_move_warehouse_user_to_restrictions.py b/patches/1312/p03_move_warehouse_user_to_restrictions.py similarity index 100% rename from patches/1311/p07_move_warehouse_user_to_restrictions.py rename to patches/1312/p03_move_warehouse_user_to_restrictions.py diff --git a/patches/1311/p08_new_permissions.py b/patches/1312/p04_new_permissions.py similarity index 100% rename from patches/1311/p08_new_permissions.py rename to patches/1312/p04_new_permissions.py diff --git a/patches/patch_list.py b/patches/patch_list.py index 30a4fc92ac..d5d50b6ed0 100644 --- a/patches/patch_list.py +++ b/patches/patch_list.py @@ -254,15 +254,15 @@ patch_list = [ "patches.1311.p04_update_comments", "patches.1311.p05_website_brand_html", "patches.1311.p06_fix_report_columns", - "patches.1311.p06_update_user_properties", "execute:webnotes.delete_doc('DocType', 'Documentation Tool')", "execute:webnotes.delete_doc('Report', 'Stock Ledger') #2013-11-29", - "patches.1312.p01_delete_old_stock_reports", "execute:webnotes.delete_doc('Report', 'Payment Collection With Ageing')", "execute:webnotes.delete_doc('Report', 'Payment Made With Ageing')", "patches.1311.p07_scheduler_errors_digest", "patches.1311.p08_email_digest_recipients", "execute:webnotes.delete_doc('DocType', 'Warehouse Type')", - "patches.1311.p07_move_warehouse_user_to_restrictions", - "patches.1311.p08_new_permissions", + "patches.1312.p01_delete_old_stock_reports", + "patches.1312.p02_update_user_properties", + "patches.1312.p03_move_warehouse_user_to_restrictions", + "patches.1312.p04_new_permissions", ] \ No newline at end of file diff --git a/setup/doctype/customer_group/customer_group.js b/setup/doctype/customer_group/customer_group.js index 3e76986948..17a08c6d70 100644 --- a/setup/doctype/customer_group/customer_group.js +++ b/setup/doctype/customer_group/customer_group.js @@ -8,7 +8,7 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn) { cur_frm.cscript.set_root_readonly = function(doc) { // read-only for root customer group if(!doc.parent_customer_group) { - cur_frm.perm = [[1,0,0], [1,0,0]]; + cur_frm.set_read_only(); cur_frm.set_intro(wn._("This is a root customer group and cannot be edited.")); } else { cur_frm.set_intro(null); diff --git a/setup/doctype/item_group/item_group.js b/setup/doctype/item_group/item_group.js index 78df60925b..65e0588ebd 100644 --- a/setup/doctype/item_group/item_group.js +++ b/setup/doctype/item_group/item_group.js @@ -18,7 +18,7 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn) { cur_frm.cscript.set_root_readonly = function(doc) { // read-only for root item group if(!doc.parent_item_group) { - cur_frm.perm = [[1,0,0], [1,0,0]]; + cur_frm.set_read_only(); cur_frm.set_intro(wn._("This is a root item group and cannot be edited.")); } else { cur_frm.set_intro(null); diff --git a/setup/doctype/sales_person/sales_person.js b/setup/doctype/sales_person/sales_person.js index 55d8684653..a2db271574 100644 --- a/setup/doctype/sales_person/sales_person.js +++ b/setup/doctype/sales_person/sales_person.js @@ -8,7 +8,7 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn) { cur_frm.cscript.set_root_readonly = function(doc) { // read-only for root if(!doc.parent_sales_person) { - cur_frm.perm = [[1,0,0], [1,0,0]]; + cur_frm.set_read_only(); cur_frm.set_intro(wn._("This is a root sales person and cannot be edited.")); } else { cur_frm.set_intro(null); diff --git a/setup/doctype/territory/territory.js b/setup/doctype/territory/territory.js index 18dbbb3017..9cb1d7094b 100644 --- a/setup/doctype/territory/territory.js +++ b/setup/doctype/territory/territory.js @@ -8,7 +8,7 @@ cur_frm.cscript.refresh = function(doc, cdt, cdn) { cur_frm.cscript.set_root_readonly = function(doc) { // read-only for root territory if(!doc.parent_territory) { - cur_frm.perm = [[1,0,0], [1,0,0]]; + cur_frm.set_read_only(); cur_frm.set_intro(wn._("This is a root territory and cannot be edited.")); } else { cur_frm.set_intro(null); From 68852f25b5a4b8009cccd704f2e232aca919f5f2 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Fri, 20 Dec 2013 19:32:25 +0530 Subject: [PATCH 10/12] Added rights for print and email in DocPerm --- accounts/doctype/account/account.txt | 17 +++++++++++++++-- .../accounts_settings/accounts_settings.txt | 4 +++- .../bank_reconciliation_detail.txt | 2 +- .../doctype/budget_detail/budget_detail.txt | 2 +- .../budget_distribution/budget_distribution.txt | 4 +++- .../budget_distribution_detail.txt | 2 +- accounts/doctype/c_form/c_form.txt | 7 ++++++- .../c_form_invoice_detail.txt | 2 +- accounts/doctype/cost_center/cost_center.txt | 9 ++++++--- accounts/doctype/fiscal_year/fiscal_year.txt | 5 ++++- accounts/doctype/gl_entry/gl_entry.txt | 4 +++- .../doctype/journal_voucher/journal_voucher.txt | 5 ++++- .../journal_voucher_detail.txt | 2 +- accounts/doctype/mis_control/mis_control.txt | 2 +- .../doctype/mode_of_payment/mode_of_payment.txt | 5 ++++- .../payment_to_invoice_matching_tool.txt | 4 +++- .../payment_to_invoice_matching_tool_detail.txt | 2 +- .../period_closing_voucher.txt | 5 ++++- accounts/doctype/pos_setting/pos_setting.txt | 4 +++- .../purchase_invoice/purchase_invoice.txt | 6 ++++-- .../purchase_invoice_advance.txt | 2 +- .../purchase_invoice_item.txt | 2 +- .../purchase_taxes_and_charges.txt | 2 +- .../purchase_taxes_and_charges_master.txt | 5 ++++- .../doctype/sales_invoice/sales_invoice.txt | 6 ++++-- .../sales_invoice_advance.txt | 2 +- .../sales_invoice_item/sales_invoice_item.txt | 2 +- .../sales_taxes_and_charges.txt | 2 +- .../sales_taxes_and_charges_master.txt | 5 ++++- .../doctype/shipping_rule/shipping_rule.txt | 4 +++- .../shipping_rule_condition.txt | 2 +- .../doctype/buying_settings/buying_settings.txt | 4 +++- .../doctype/purchase_common/purchase_common.txt | 2 +- .../doctype/purchase_order/purchase_order.txt | 6 ++++-- .../purchase_order_item/purchase_order_item.txt | 2 +- .../purchase_order_item_supplied.txt | 2 +- .../purchase_receipt_item_supplied.txt | 2 +- .../quality_inspection/quality_inspection.txt | 5 ++++- .../quality_inspection_reading.txt | 2 +- buying/doctype/supplier/supplier.txt | 5 ++++- .../supplier_quotation/supplier_quotation.txt | 6 ++++-- .../supplier_quotation_item.txt | 2 +- home/doctype/feed/feed.txt | 4 +++- hr/doctype/appraisal/appraisal.txt | 5 ++++- hr/doctype/appraisal_goal/appraisal_goal.txt | 2 +- .../appraisal_template/appraisal_template.txt | 5 ++++- .../appraisal_template_goal.txt | 2 +- hr/doctype/attendance/attendance.txt | 6 +++++- hr/doctype/branch/branch.txt | 5 ++++- hr/doctype/deduction_type/deduction_type.txt | 5 ++++- hr/doctype/department/department.txt | 5 ++++- hr/doctype/designation/designation.txt | 5 ++++- hr/doctype/earning_type/earning_type.txt | 5 ++++- hr/doctype/employee/employee.txt | 7 +++++-- .../employee_education/employee_education.txt | 2 +- .../employee_external_work_history.txt | 2 +- .../employee_internal_work_history.txt | 2 +- .../employee_leave_approver.txt | 2 +- hr/doctype/employment_type/employment_type.txt | 5 ++++- hr/doctype/expense_claim/expense_claim.txt | 6 ++++-- .../expense_claim_detail.txt | 2 +- .../expense_claim_type/expense_claim_type.txt | 5 ++++- hr/doctype/grade/grade.txt | 5 ++++- hr/doctype/holiday/holiday.txt | 2 +- hr/doctype/holiday_list/holiday_list.txt | 5 ++++- hr/doctype/hr_settings/hr_settings.txt | 4 +++- hr/doctype/job_applicant/job_applicant.txt | 4 +++- hr/doctype/job_opening/job_opening.txt | 4 +++- .../leave_allocation/leave_allocation.txt | 5 ++++- .../leave_application/leave_application.txt | 11 ++++++++--- .../leave_block_list/leave_block_list.txt | 5 ++++- .../leave_block_list_allow.txt | 2 +- .../leave_block_list_date.txt | 2 +- hr/doctype/leave_type/leave_type.txt | 5 ++++- hr/doctype/salary_slip/salary_slip.txt | 5 ++++- .../salary_slip_deduction.txt | 2 +- .../salary_slip_earning/salary_slip_earning.txt | 2 +- .../salary_structure/salary_structure.txt | 4 +++- .../salary_structure_deduction.txt | 2 +- .../salary_structure_earning.txt | 2 +- .../upload_attendance/upload_attendance.txt | 4 +++- manufacturing/doctype/bom/bom.txt | 8 +++++--- .../bom_explosion_item/bom_explosion_item.txt | 2 +- manufacturing/doctype/bom_item/bom_item.txt | 2 +- .../doctype/bom_operation/bom_operation.txt | 2 +- .../production_order/production_order.txt | 5 ++++- .../production_plan_item.txt | 2 +- .../production_plan_sales_order.txt | 2 +- .../production_planning_tool.txt | 4 +++- .../doctype/workstation/workstation.txt | 6 ++++-- .../doctype/activity_type/activity_type.txt | 5 ++++- projects/doctype/project/project.txt | 4 +++- .../project_milestone/project_milestone.txt | 2 +- projects/doctype/task/task.txt | 4 +++- projects/doctype/time_log/time_log.txt | 6 +++++- .../doctype/time_log_batch/time_log_batch.txt | 5 ++++- .../time_log_batch_detail.txt | 2 +- selling/doctype/campaign/campaign.txt | 10 ++++++++-- selling/doctype/customer/customer.txt | 8 ++++++-- .../customer_discount/customer_discount.txt | 2 +- selling/doctype/industry_type/industry_type.txt | 5 ++++- .../installation_note/installation_note.txt | 5 ++++- .../installation_note_item.txt | 2 +- selling/doctype/lead/lead.txt | 4 +++- selling/doctype/opportunity/opportunity.txt | 5 ++++- .../opportunity_item/opportunity_item.txt | 2 +- selling/doctype/quotation/quotation.txt | 7 ++++--- .../doctype/quotation_item/quotation_item.txt | 2 +- selling/doctype/sales_bom/sales_bom.txt | 5 ++++- .../doctype/sales_bom_item/sales_bom_item.txt | 2 +- selling/doctype/sales_order/sales_order.txt | 6 ++++-- .../sales_order_item/sales_order_item.txt | 2 +- selling/doctype/sales_team/sales_team.txt | 2 +- .../selling_settings/selling_settings.txt | 4 +++- .../shopping_cart_price_list.txt | 2 +- .../shopping_cart_settings.txt | 4 +++- .../shopping_cart_shipping_rule.txt | 2 +- .../shopping_cart_taxes_and_charges_master.txt | 2 +- .../applicable_territory.txt | 2 +- .../authorization_control.txt | 2 +- .../authorization_rule/authorization_rule.txt | 5 ++++- setup/doctype/backup_manager/backup_manager.txt | 4 +++- setup/doctype/brand/brand.txt | 5 ++++- setup/doctype/company/company.txt | 5 ++++- .../doctype/contact_control/contact_control.txt | 4 +++- setup/doctype/country/country.txt | 5 ++++- setup/doctype/currency/currency.txt | 4 +++- .../currency_exchange/currency_exchange.txt | 4 +++- setup/doctype/customer_group/customer_group.txt | 9 ++++++--- setup/doctype/email_digest/email_digest.txt | 4 +++- setup/doctype/features_setup/features_setup.txt | 4 +++- setup/doctype/item_group/item_group.txt | 9 ++++++--- .../jobs_email_settings/jobs_email_settings.txt | 4 +++- setup/doctype/naming_series/naming_series.txt | 4 +++- setup/doctype/print_heading/print_heading.txt | 5 ++++- .../quotation_lost_reason.txt | 5 ++++- .../sales_email_settings.txt | 4 +++- setup/doctype/sales_partner/sales_partner.txt | 5 ++++- setup/doctype/sales_person/sales_person.txt | 7 +++++-- setup/doctype/sms_parameter/sms_parameter.txt | 2 +- setup/doctype/supplier_type/supplier_type.txt | 5 ++++- setup/doctype/target_detail/target_detail.txt | 2 +- .../terms_and_conditions.txt | 5 ++++- setup/doctype/territory/territory.txt | 9 ++++++--- setup/doctype/uom/uom.txt | 5 ++++- .../website_item_group/website_item_group.txt | 2 +- stock/doctype/batch/batch.txt | 5 ++++- stock/doctype/bin/bin.txt | 4 +++- stock/doctype/delivery_note/delivery_note.txt | 6 ++++-- .../delivery_note_item/delivery_note_item.txt | 2 +- stock/doctype/item/item.txt | 6 +++++- .../item_customer_detail.txt | 2 +- stock/doctype/item_price/item_price.txt | 5 ++++- .../item_quality_inspection_parameter.txt | 2 +- stock/doctype/item_reorder/item_reorder.txt | 2 +- stock/doctype/item_supplier/item_supplier.txt | 2 +- stock/doctype/item_tax/item_tax.txt | 2 +- .../item_website_specification.txt | 2 +- .../landed_cost_item/landed_cost_item.txt | 2 +- .../landed_cost_purchase_receipt.txt | 2 +- .../landed_cost_wizard/landed_cost_wizard.txt | 4 +++- .../material_request/material_request.txt | 6 ++++-- .../material_request_item.txt | 2 +- stock/doctype/packed_item/packed_item.txt | 2 +- stock/doctype/packing_slip/packing_slip.txt | 5 ++++- .../packing_slip_item/packing_slip_item.txt | 2 +- stock/doctype/price_list/price_list.txt | 5 ++--- .../purchase_receipt/purchase_receipt.txt | 6 ++++-- .../purchase_receipt_item.txt | 2 +- stock/doctype/serial_no/serial_no.txt | 5 ++++- stock/doctype/stock_entry/stock_entry.txt | 7 ++++--- .../stock_entry_detail/stock_entry_detail.txt | 2 +- .../stock_reconciliation.txt | 5 ++--- stock/doctype/stock_settings/stock_settings.txt | 4 +++- .../stock_uom_replace_utility.txt | 4 +++- .../uom_conversion_detail.txt | 2 +- stock/doctype/warehouse/warehouse.txt | 9 +++++---- stock/doctype/warehouse_user/warehouse_user.txt | 2 +- .../doctype/customer_issue/customer_issue.txt | 5 ++++- .../maintenance_schedule.txt | 5 ++++- .../maintenance_schedule_detail.txt | 2 +- .../maintenance_schedule_item.txt | 2 +- .../maintenance_visit/maintenance_visit.txt | 5 ++++- .../maintenance_visit_purpose.txt | 2 +- support/doctype/newsletter/newsletter.txt | 10 ++++++---- .../doctype/support_ticket/support_ticket.txt | 5 +++-- utilities/doctype/address/address.txt | 5 ++++- utilities/doctype/contact/contact.txt | 5 ++++- utilities/doctype/note/note.txt | 5 +++-- utilities/doctype/note_user/note_user.txt | 2 +- utilities/doctype/sms_control/sms_control.txt | 8 ++++++-- utilities/doctype/sms_log/sms_log.txt | 4 +++- 192 files changed, 543 insertions(+), 236 deletions(-) diff --git a/accounts/doctype/account/account.txt b/accounts/doctype/account/account.txt index c76a41023b..50a6d6da37 100644 --- a/accounts/doctype/account/account.txt +++ b/accounts/doctype/account/account.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-30 12:49:46", "docstatus": 0, - "modified": "2013-11-26 17:35:12", + "modified": "2013-12-20 19:23:54", "modified_by": "Administrator", "owner": "Administrator" }, @@ -138,7 +138,7 @@ "doctype": "DocField", "fieldname": "parent_account", "fieldtype": "Link", - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "Parent Account", "oldfieldname": "parent_account", "oldfieldtype": "Link", @@ -257,7 +257,9 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "role": "Accounts User", "write": 1 }, @@ -265,7 +267,9 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "role": "Auditor", "write": 0 }, @@ -273,7 +277,9 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "role": "Sales User", "write": 0 }, @@ -281,7 +287,9 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "role": "Purchase User", "write": 0 }, @@ -297,7 +305,12 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, + "export": 0, + "import": 0, "permlevel": 0, + "print": 1, + "restrict": 1, "role": "Accounts Manager", "write": 1 }, diff --git a/accounts/doctype/accounts_settings/accounts_settings.txt b/accounts/doctype/accounts_settings/accounts_settings.txt index 026cf613f7..f36e21840d 100644 --- a/accounts/doctype/accounts_settings/accounts_settings.txt +++ b/accounts/doctype/accounts_settings/accounts_settings.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-24 15:49:57", "docstatus": 0, - "modified": "2013-09-24 11:52:58", + "modified": "2013-12-20 19:22:52", "modified_by": "Administrator", "owner": "Administrator" }, @@ -25,11 +25,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Accounts Settings", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "Accounts Manager", "write": 1 diff --git a/accounts/doctype/bank_reconciliation_detail/bank_reconciliation_detail.txt b/accounts/doctype/bank_reconciliation_detail/bank_reconciliation_detail.txt index 9905398d3f..47ff4f1344 100644 --- a/accounts/doctype/bank_reconciliation_detail/bank_reconciliation_detail.txt +++ b/accounts/doctype/bank_reconciliation_detail/bank_reconciliation_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:37", "docstatus": 0, - "modified": "2013-11-03 14:11:31", + "modified": "2013-12-20 19:22:55", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/budget_detail/budget_detail.txt b/accounts/doctype/budget_detail/budget_detail.txt index f53ff52e58..31312c9208 100644 --- a/accounts/doctype/budget_detail/budget_detail.txt +++ b/accounts/doctype/budget_detail/budget_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 11:55:04", "docstatus": 0, - "modified": "2013-08-22 17:27:59", + "modified": "2013-12-20 19:22:59", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/budget_distribution/budget_distribution.txt b/accounts/doctype/budget_distribution/budget_distribution.txt index ae668abe8d..992c8bec81 100644 --- a/accounts/doctype/budget_distribution/budget_distribution.txt +++ b/accounts/doctype/budget_distribution/budget_distribution.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:05", "docstatus": 0, - "modified": "2013-07-22 15:30:37", + "modified": "2013-12-20 19:23:58", "modified_by": "Administrator", "owner": "Administrator" }, @@ -82,7 +82,9 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "write": 1 }, { diff --git a/accounts/doctype/budget_distribution_detail/budget_distribution_detail.txt b/accounts/doctype/budget_distribution_detail/budget_distribution_detail.txt index c8207bda58..a171bf69cc 100644 --- a/accounts/doctype/budget_distribution_detail/budget_distribution_detail.txt +++ b/accounts/doctype/budget_distribution_detail/budget_distribution_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:38", "docstatus": 0, - "modified": "2013-07-10 14:54:06", + "modified": "2013-12-20 19:22:59", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/c_form/c_form.txt b/accounts/doctype/c_form/c_form.txt index 21d655026a..d5ff32b33b 100644 --- a/accounts/doctype/c_form/c_form.txt +++ b/accounts/doctype/c_form/c_form.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 11:55:06", "docstatus": 0, - "modified": "2013-11-02 14:05:25", + "modified": "2013-12-20 19:23:58", "modified_by": "Administrator", "owner": "Administrator" }, @@ -157,6 +157,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "options": "C-Form", @@ -166,14 +167,18 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "role": "Accounts User", "write": 1 }, { "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "role": "Accounts Manager", "write": 1 }, diff --git a/accounts/doctype/c_form_invoice_detail/c_form_invoice_detail.txt b/accounts/doctype/c_form_invoice_detail/c_form_invoice_detail.txt index 99335b7023..77dfa72430 100644 --- a/accounts/doctype/c_form_invoice_detail/c_form_invoice_detail.txt +++ b/accounts/doctype/c_form_invoice_detail/c_form_invoice_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:38", "docstatus": 0, - "modified": "2013-11-02 16:58:31", + "modified": "2013-12-20 19:23:00", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/cost_center/cost_center.txt b/accounts/doctype/cost_center/cost_center.txt index 2c6a5e6748..3f1fab279d 100644 --- a/accounts/doctype/cost_center/cost_center.txt +++ b/accounts/doctype/cost_center/cost_center.txt @@ -2,12 +2,13 @@ { "creation": "2013-01-23 19:57:17", "docstatus": 0, - "modified": "2013-11-26 17:34:50", + "modified": "2013-12-20 19:24:00", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_copy": 1, + "allow_import": 1, "allow_rename": 1, "autoname": "field:cost_center_name", "description": "Track separate Income and Expense for product verticals or divisions.", @@ -30,11 +31,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Cost Center", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 @@ -74,7 +77,7 @@ "doctype": "DocField", "fieldname": "parent_cost_center", "fieldtype": "Link", - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "Parent Cost Center", "oldfieldname": "parent_cost_center", "oldfieldtype": "Link", @@ -172,7 +175,7 @@ "fieldname": "old_parent", "fieldtype": "Link", "hidden": 1, - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "old_parent", "no_copy": 1, "oldfieldname": "old_parent", diff --git a/accounts/doctype/fiscal_year/fiscal_year.txt b/accounts/doctype/fiscal_year/fiscal_year.txt index 1cf98fb278..afa4858969 100644 --- a/accounts/doctype/fiscal_year/fiscal_year.txt +++ b/accounts/doctype/fiscal_year/fiscal_year.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-22 16:50:25", "docstatus": 0, - "modified": "2013-11-25 11:40:02", + "modified": "2013-12-20 19:24:08", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:year", "description": "**Fiscal Year** represents a Financial Year. All accounting entries and other major transactions are tracked against **Fiscal Year**.", "doctype": "DocType", @@ -25,11 +26,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Fiscal Year", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1 }, { diff --git a/accounts/doctype/gl_entry/gl_entry.txt b/accounts/doctype/gl_entry/gl_entry.txt index 5740579088..3ec5ec6c74 100644 --- a/accounts/doctype/gl_entry/gl_entry.txt +++ b/accounts/doctype/gl_entry/gl_entry.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:06", "docstatus": 0, - "modified": "2013-11-03 14:14:09", + "modified": "2013-12-20 19:24:08", "modified_by": "Administrator", "owner": "Administrator" }, @@ -26,11 +26,13 @@ { "create": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "GL Entry", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, diff --git a/accounts/doctype/journal_voucher/journal_voucher.txt b/accounts/doctype/journal_voucher/journal_voucher.txt index b47d7ed4c1..9de2abb642 100644 --- a/accounts/doctype/journal_voucher/journal_voucher.txt +++ b/accounts/doctype/journal_voucher/journal_voucher.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-25 10:53:52", "docstatus": 0, - "modified": "2013-11-03 14:11:33", + "modified": "2013-12-20 19:24:11", "modified_by": "Administrator", "owner": "Administrator" }, @@ -27,11 +27,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Journal Voucher", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -459,6 +461,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/accounts/doctype/journal_voucher_detail/journal_voucher_detail.txt b/accounts/doctype/journal_voucher_detail/journal_voucher_detail.txt index aea5d1256d..53a56aa507 100644 --- a/accounts/doctype/journal_voucher_detail/journal_voucher_detail.txt +++ b/accounts/doctype/journal_voucher_detail/journal_voucher_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:39", "docstatus": 0, - "modified": "2013-08-02 18:15:56", + "modified": "2013-12-20 19:23:18", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/mis_control/mis_control.txt b/accounts/doctype/mis_control/mis_control.txt index ed0bedb12a..28a0df4d72 100644 --- a/accounts/doctype/mis_control/mis_control.txt +++ b/accounts/doctype/mis_control/mis_control.txt @@ -2,7 +2,7 @@ { "creation": "2012-03-27 14:35:49", "docstatus": 0, - "modified": "2013-07-10 14:54:11", + "modified": "2013-12-20 19:23:21", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/mode_of_payment/mode_of_payment.txt b/accounts/doctype/mode_of_payment/mode_of_payment.txt index 5d004e3422..58300306f1 100644 --- a/accounts/doctype/mode_of_payment/mode_of_payment.txt +++ b/accounts/doctype/mode_of_payment/mode_of_payment.txt @@ -2,11 +2,12 @@ { "creation": "2012-12-04 17:49:20", "docstatus": 0, - "modified": "2013-07-05 14:46:28", + "modified": "2013-12-20 19:24:14", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:mode_of_payment", "doctype": "DocType", @@ -27,11 +28,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Mode of Payment", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Accounts Manager", diff --git a/accounts/doctype/payment_to_invoice_matching_tool/payment_to_invoice_matching_tool.txt b/accounts/doctype/payment_to_invoice_matching_tool/payment_to_invoice_matching_tool.txt index accf51595d..bc4e0f7d92 100644 --- a/accounts/doctype/payment_to_invoice_matching_tool/payment_to_invoice_matching_tool.txt +++ b/accounts/doctype/payment_to_invoice_matching_tool/payment_to_invoice_matching_tool.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-30 12:49:46", "docstatus": 0, - "modified": "2013-07-22 15:31:00", + "modified": "2013-12-20 19:23:24", "modified_by": "Administrator", "owner": "Administrator" }, @@ -26,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Payment to Invoice Matching Tool", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 0, "submit": 0, diff --git a/accounts/doctype/payment_to_invoice_matching_tool_detail/payment_to_invoice_matching_tool_detail.txt b/accounts/doctype/payment_to_invoice_matching_tool_detail/payment_to_invoice_matching_tool_detail.txt index 5259f74667..1017a98ef5 100644 --- a/accounts/doctype/payment_to_invoice_matching_tool_detail/payment_to_invoice_matching_tool_detail.txt +++ b/accounts/doctype/payment_to_invoice_matching_tool_detail/payment_to_invoice_matching_tool_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:39", "docstatus": 0, - "modified": "2013-07-10 14:54:11", + "modified": "2013-12-20 19:23:24", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/period_closing_voucher/period_closing_voucher.txt b/accounts/doctype/period_closing_voucher/period_closing_voucher.txt index 6c3fadd304..37a22a0497 100644 --- a/accounts/doctype/period_closing_voucher/period_closing_voucher.txt +++ b/accounts/doctype/period_closing_voucher/period_closing_voucher.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:07", "docstatus": 0, - "modified": "2013-08-12 17:13:23", + "modified": "2013-12-20 19:24:15", "modified_by": "Administrator", "owner": "jai@webnotestech.com" }, @@ -28,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Period Closing Voucher", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -80,6 +82,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/accounts/doctype/pos_setting/pos_setting.txt b/accounts/doctype/pos_setting/pos_setting.txt index 09a3757985..22edcddea3 100755 --- a/accounts/doctype/pos_setting/pos_setting.txt +++ b/accounts/doctype/pos_setting/pos_setting.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-24 12:15:51", "docstatus": 0, - "modified": "2013-11-02 16:58:38", + "modified": "2013-12-20 19:24:16", "modified_by": "Administrator", "owner": "Administrator" }, @@ -23,11 +23,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "POS Setting", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/accounts/doctype/purchase_invoice/purchase_invoice.txt b/accounts/doctype/purchase_invoice/purchase_invoice.txt index af0eb8e559..6df4df40d3 100755 --- a/accounts/doctype/purchase_invoice/purchase_invoice.txt +++ b/accounts/doctype/purchase_invoice/purchase_invoice.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-21 16:16:39", "docstatus": 0, - "modified": "2013-11-22 17:15:27", + "modified": "2013-12-20 19:24:18", "modified_by": "Administrator", "owner": "Administrator" }, @@ -28,11 +28,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Purchase Invoice", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -181,6 +183,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -787,7 +790,6 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", - "match": "supplier", "role": "Supplier", "submit": 0, "write": 0 diff --git a/accounts/doctype/purchase_invoice_advance/purchase_invoice_advance.txt b/accounts/doctype/purchase_invoice_advance/purchase_invoice_advance.txt index 49aa68887b..f10d30e88b 100644 --- a/accounts/doctype/purchase_invoice_advance/purchase_invoice_advance.txt +++ b/accounts/doctype/purchase_invoice_advance/purchase_invoice_advance.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-08 15:36:46", "docstatus": 0, - "modified": "2013-07-10 14:54:12", + "modified": "2013-12-20 19:23:29", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/purchase_invoice_item/purchase_invoice_item.txt b/accounts/doctype/purchase_invoice_item/purchase_invoice_item.txt index 1a79636183..3f1ae05bd4 100755 --- a/accounts/doctype/purchase_invoice_item/purchase_invoice_item.txt +++ b/accounts/doctype/purchase_invoice_item/purchase_invoice_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-22 12:43:10", "docstatus": 0, - "modified": "2013-11-02 19:41:17", + "modified": "2013-12-20 19:23:29", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/purchase_taxes_and_charges/purchase_taxes_and_charges.txt b/accounts/doctype/purchase_taxes_and_charges/purchase_taxes_and_charges.txt index 5ea7fc09ff..9a2a75d4d7 100644 --- a/accounts/doctype/purchase_taxes_and_charges/purchase_taxes_and_charges.txt +++ b/accounts/doctype/purchase_taxes_and_charges/purchase_taxes_and_charges.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-21 16:16:04", "docstatus": 0, - "modified": "2013-07-10 14:54:18", + "modified": "2013-12-20 19:23:38", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/purchase_taxes_and_charges_master/purchase_taxes_and_charges_master.txt b/accounts/doctype/purchase_taxes_and_charges_master/purchase_taxes_and_charges_master.txt index f902ade3d1..1430c43d2e 100644 --- a/accounts/doctype/purchase_taxes_and_charges_master/purchase_taxes_and_charges_master.txt +++ b/accounts/doctype/purchase_taxes_and_charges_master/purchase_taxes_and_charges_master.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:08", "docstatus": 0, - "modified": "2013-07-22 15:22:25", + "modified": "2013-12-20 19:24:24", "modified_by": "Administrator", "owner": "wasim@webnotestech.com" }, { + "allow_import": 1, "autoname": "field:title", "description": "Standard tax template that can be applied to all Purchase Transactions. This template can contain list of tax heads and also other expense heads like \"Shipping\", \"Insurance\", \"Handling\" etc.\n\n#### Note\n\nThe tax rate you define here will be the standard tax rate for all **Items**. If there are **Items** that have different rates, they must be added in the **Item Tax** table in the **Item** master.\n\n#### Description of Columns\n\n1. Calculation Type: \n - This can be on **Net Total** (that is the sum of basic amount).\n - **On Previous Row Total / Amount** (for cumulative taxes or charges). If you select this option, the tax will be applied as a percentage of the previous row (in the tax table) amount or total.\n - **Actual** (as mentioned).\n2. Account Head: The Account ledger under which this tax will be booked\n3. Cost Center: If the tax / charge is an income (like shipping) or expense it needs to be booked against a Cost Center.\n4. Description: Description of the tax (that will be printed in invoices / quotes).\n5. Rate: Tax rate.\n6. Amount: Tax amount.\n7. Total: Cumulative total to this point.\n8. Enter Row: If based on \"Previous Row Total\" you can select the row number which will be taken as a base for this calculation (default is the previous row).\n9. Consider Tax or Charge for: In this section you can specify if the tax / charge is only for valuation (not a part of total) or only for total (does not add value to the item) or for both.\n10. Add or Deduct: Whether you want to add or deduct the tax.", "doctype": "DocType", @@ -25,11 +26,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Purchase Taxes and Charges Master", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/accounts/doctype/sales_invoice/sales_invoice.txt b/accounts/doctype/sales_invoice/sales_invoice.txt index 99bfe5cdf0..7de68a06ed 100644 --- a/accounts/doctype/sales_invoice/sales_invoice.txt +++ b/accounts/doctype/sales_invoice/sales_invoice.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-24 19:29:05", "docstatus": 0, - "modified": "2013-11-18 15:16:50", + "modified": "2013-12-20 19:24:29", "modified_by": "Administrator", "owner": "Administrator" }, @@ -30,11 +30,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Sales Invoice", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -141,6 +143,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -1219,7 +1222,6 @@ }, { "doctype": "DocPerm", - "match": "customer", "role": "Customer" } ] \ No newline at end of file diff --git a/accounts/doctype/sales_invoice_advance/sales_invoice_advance.txt b/accounts/doctype/sales_invoice_advance/sales_invoice_advance.txt index b82f4acabd..ad1a9eb8fb 100644 --- a/accounts/doctype/sales_invoice_advance/sales_invoice_advance.txt +++ b/accounts/doctype/sales_invoice_advance/sales_invoice_advance.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:41", "docstatus": 0, - "modified": "2013-07-10 14:54:19", + "modified": "2013-12-20 19:21:40", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/sales_invoice_item/sales_invoice_item.txt b/accounts/doctype/sales_invoice_item/sales_invoice_item.txt index d7dac74343..339115d25e 100644 --- a/accounts/doctype/sales_invoice_item/sales_invoice_item.txt +++ b/accounts/doctype/sales_invoice_item/sales_invoice_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-04 11:02:19", "docstatus": 0, - "modified": "2013-11-02 19:41:24", + "modified": "2013-12-20 19:21:40", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/sales_taxes_and_charges/sales_taxes_and_charges.txt b/accounts/doctype/sales_taxes_and_charges/sales_taxes_and_charges.txt index b006c1d85c..ab4da2aa4f 100644 --- a/accounts/doctype/sales_taxes_and_charges/sales_taxes_and_charges.txt +++ b/accounts/doctype/sales_taxes_and_charges/sales_taxes_and_charges.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-24 11:39:32", "docstatus": 0, - "modified": "2013-12-17 12:38:08", + "modified": "2013-12-20 19:21:45", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/accounts/doctype/sales_taxes_and_charges_master/sales_taxes_and_charges_master.txt b/accounts/doctype/sales_taxes_and_charges_master/sales_taxes_and_charges_master.txt index cddf10ec85..485aa94ac1 100644 --- a/accounts/doctype/sales_taxes_and_charges_master/sales_taxes_and_charges_master.txt +++ b/accounts/doctype/sales_taxes_and_charges_master/sales_taxes_and_charges_master.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:09", "docstatus": 0, - "modified": "2013-10-31 19:25:09", + "modified": "2013-12-20 19:24:34", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:title", "description": "Standard tax template that can be applied to all Sales Transactions. This template can contain list of tax heads and also other expense / income heads like \"Shipping\", \"Insurance\", \"Handling\" etc.\n\n#### Note\n\nThe tax rate you define here will be the standard tax rate for all **Items**. If there are **Items** that have different rates, they must be added in the **Item Tax** table in the **Item** master.\n\n#### Description of Columns\n\n1. Calculation Type: \n - This can be on **Net Total** (that is the sum of basic amount).\n - **On Previous Row Total / Amount** (for cumulative taxes or charges). If you select this option, the tax will be applied as a percentage of the previous row (in the tax table) amount or total.\n - **Actual** (as mentioned).\n2. Account Head: The Account ledger under which this tax will be booked\n3. Cost Center: If the tax / charge is an income (like shipping) or expense it needs to be booked against a Cost Center.\n4. Description: Description of the tax (that will be printed in invoices / quotes).\n5. Rate: Tax rate.\n6. Amount: Tax amount.\n7. Total: Cumulative total to this point.\n8. Enter Row: If based on \"Previous Row Total\" you can select the row number which will be taken as a base for this calculation (default is the previous row).\n9. Is this Tax included in Basic Rate?: If you check this, it means that this tax will not be shown below the item table, but will be included in the Basic Rate in your main item table. This is useful where you want give a flat price (inclusive of all taxes) price to customers.", "doctype": "DocType", @@ -26,11 +27,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Sales Taxes and Charges Master", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/accounts/doctype/shipping_rule/shipping_rule.txt b/accounts/doctype/shipping_rule/shipping_rule.txt index 27aaa70115..082cddcaeb 100644 --- a/accounts/doctype/shipping_rule/shipping_rule.txt +++ b/accounts/doctype/shipping_rule/shipping_rule.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-25 11:48:03", "docstatus": 0, - "modified": "2013-10-31 19:24:50", + "modified": "2013-12-20 19:24:35", "modified_by": "Administrator", "owner": "Administrator" }, @@ -24,11 +24,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Shipping Rule", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, diff --git a/accounts/doctype/shipping_rule_condition/shipping_rule_condition.txt b/accounts/doctype/shipping_rule_condition/shipping_rule_condition.txt index 3784ecbfb2..22af554466 100644 --- a/accounts/doctype/shipping_rule_condition/shipping_rule_condition.txt +++ b/accounts/doctype/shipping_rule_condition/shipping_rule_condition.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-25 11:54:50", "docstatus": 0, - "modified": "2013-07-10 14:54:22", + "modified": "2013-12-20 19:21:46", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/buying/doctype/buying_settings/buying_settings.txt b/buying/doctype/buying_settings/buying_settings.txt index 2b0c6ad0f0..b91a3557b5 100644 --- a/buying/doctype/buying_settings/buying_settings.txt +++ b/buying/doctype/buying_settings/buying_settings.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-25 11:04:03", "docstatus": 0, - "modified": "2013-08-09 14:38:46", + "modified": "2013-12-20 19:22:59", "modified_by": "Administrator", "owner": "Administrator" }, @@ -26,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Buying Settings", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "System Manager", "write": 1 diff --git a/buying/doctype/purchase_common/purchase_common.txt b/buying/doctype/purchase_common/purchase_common.txt index 40f5756f25..c796c042a9 100644 --- a/buying/doctype/purchase_common/purchase_common.txt +++ b/buying/doctype/purchase_common/purchase_common.txt @@ -2,7 +2,7 @@ { "creation": "2012-03-27 14:35:51", "docstatus": 0, - "modified": "2013-07-10 14:54:12", + "modified": "2013-12-20 19:23:27", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/buying/doctype/purchase_order/purchase_order.txt b/buying/doctype/purchase_order/purchase_order.txt index 3f3937cd12..0266b80e32 100644 --- a/buying/doctype/purchase_order/purchase_order.txt +++ b/buying/doctype/purchase_order/purchase_order.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-21 16:16:39", "docstatus": 0, - "modified": "2013-11-22 17:20:58", + "modified": "2013-12-20 19:24:20", "modified_by": "Administrator", "owner": "Administrator" }, @@ -29,11 +29,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Purchase Order", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -141,6 +143,7 @@ "fieldname": "amended_from", "fieldtype": "Data", "hidden": 0, + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -694,7 +697,6 @@ }, { "doctype": "DocPerm", - "match": "supplier", "role": "Supplier" } ] \ No newline at end of file diff --git a/buying/doctype/purchase_order_item/purchase_order_item.txt b/buying/doctype/purchase_order_item/purchase_order_item.txt index 4145a7fb38..a78c485f89 100755 --- a/buying/doctype/purchase_order_item/purchase_order_item.txt +++ b/buying/doctype/purchase_order_item/purchase_order_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-24 19:29:06", "docstatus": 0, - "modified": "2013-11-02 19:41:27", + "modified": "2013-12-20 19:23:32", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/buying/doctype/purchase_order_item_supplied/purchase_order_item_supplied.txt b/buying/doctype/purchase_order_item_supplied/purchase_order_item_supplied.txt index 05ea4e2863..f2860cde54 100644 --- a/buying/doctype/purchase_order_item_supplied/purchase_order_item_supplied.txt +++ b/buying/doctype/purchase_order_item_supplied/purchase_order_item_supplied.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:42", "docstatus": 0, - "modified": "2013-07-25 16:33:05", + "modified": "2013-12-20 19:23:33", "modified_by": "Administrator", "owner": "dhanalekshmi@webnotestech.com" }, diff --git a/buying/doctype/purchase_receipt_item_supplied/purchase_receipt_item_supplied.txt b/buying/doctype/purchase_receipt_item_supplied/purchase_receipt_item_supplied.txt index 15225103cd..c1ace7ceff 100644 --- a/buying/doctype/purchase_receipt_item_supplied/purchase_receipt_item_supplied.txt +++ b/buying/doctype/purchase_receipt_item_supplied/purchase_receipt_item_supplied.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:42", "docstatus": 0, - "modified": "2013-07-25 16:34:11", + "modified": "2013-12-20 19:23:37", "modified_by": "Administrator", "owner": "wasim@webnotestech.com" }, diff --git a/buying/doctype/quality_inspection/quality_inspection.txt b/buying/doctype/quality_inspection/quality_inspection.txt index d4a2d8fd79..aa8aa18394 100644 --- a/buying/doctype/quality_inspection/quality_inspection.txt +++ b/buying/doctype/quality_inspection/quality_inspection.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-30 13:13:03", "docstatus": 0, - "modified": "2013-11-02 14:05:38", + "modified": "2013-12-20 19:24:24", "modified_by": "Administrator", "owner": "Administrator" }, @@ -28,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Quality Inspection", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Quality Manager", @@ -206,6 +208,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/buying/doctype/quality_inspection_reading/quality_inspection_reading.txt b/buying/doctype/quality_inspection_reading/quality_inspection_reading.txt index 0c68cc74c7..f08e7cd5d2 100644 --- a/buying/doctype/quality_inspection_reading/quality_inspection_reading.txt +++ b/buying/doctype/quality_inspection_reading/quality_inspection_reading.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:43", "docstatus": 0, - "modified": "2013-07-10 14:54:18", + "modified": "2013-12-20 19:23:39", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/buying/doctype/supplier/supplier.txt b/buying/doctype/supplier/supplier.txt index 5c722f1c31..c76eb653cf 100644 --- a/buying/doctype/supplier/supplier.txt +++ b/buying/doctype/supplier/supplier.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:11", "docstatus": 0, - "modified": "2013-11-19 11:31:28", + "modified": "2013-12-20 19:24:36", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "naming_series:", "description": "Supplier of Goods or Services.", @@ -28,11 +29,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Supplier", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/buying/doctype/supplier_quotation/supplier_quotation.txt b/buying/doctype/supplier_quotation/supplier_quotation.txt index e532aa6dd1..f3bc30c738 100644 --- a/buying/doctype/supplier_quotation/supplier_quotation.txt +++ b/buying/doctype/supplier_quotation/supplier_quotation.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-21 16:16:45", "docstatus": 0, - "modified": "2013-12-14 17:27:47", + "modified": "2013-12-20 19:24:36", "modified_by": "Administrator", "owner": "Administrator" }, @@ -29,11 +29,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Supplier Quotation", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -141,6 +143,7 @@ "fieldname": "amended_from", "fieldtype": "Data", "hidden": 1, + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -632,7 +635,6 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", - "match": "supplier", "role": "Supplier", "submit": 0, "write": 0 diff --git a/buying/doctype/supplier_quotation_item/supplier_quotation_item.txt b/buying/doctype/supplier_quotation_item/supplier_quotation_item.txt index f09f5a82e2..f0810ff449 100644 --- a/buying/doctype/supplier_quotation_item/supplier_quotation_item.txt +++ b/buying/doctype/supplier_quotation_item/supplier_quotation_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-22 12:43:10", "docstatus": 0, - "modified": "2013-11-02 19:41:29", + "modified": "2013-12-20 19:21:50", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/home/doctype/feed/feed.txt b/home/doctype/feed/feed.txt index 8dde5f953d..8821b7d36f 100644 --- a/home/doctype/feed/feed.txt +++ b/home/doctype/feed/feed.txt @@ -2,7 +2,7 @@ { "creation": "2012-07-03 13:29:42", "docstatus": 0, - "modified": "2013-11-15 10:16:00", + "modified": "2013-12-20 19:24:07", "modified_by": "Administrator", "owner": "Administrator" }, @@ -23,11 +23,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Feed", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "System Manager" diff --git a/hr/doctype/appraisal/appraisal.txt b/hr/doctype/appraisal/appraisal.txt index 8aaa7e109c..c7d9aafbbb 100644 --- a/hr/doctype/appraisal/appraisal.txt +++ b/hr/doctype/appraisal/appraisal.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:12", "docstatus": 0, - "modified": "2013-07-05 14:24:59", + "modified": "2013-12-20 19:23:55", "modified_by": "Administrator", "owner": "ashwini@webnotestech.com" }, @@ -26,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Appraisal", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "write": 1 @@ -217,6 +219,7 @@ "fieldname": "amended_from", "fieldtype": "Data", "hidden": 1, + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/hr/doctype/appraisal_goal/appraisal_goal.txt b/hr/doctype/appraisal_goal/appraisal_goal.txt index 794a879734..5c15ac6edc 100644 --- a/hr/doctype/appraisal_goal/appraisal_goal.txt +++ b/hr/doctype/appraisal_goal/appraisal_goal.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:44", "docstatus": 0, - "modified": "2013-07-10 14:54:03", + "modified": "2013-12-20 19:22:53", "modified_by": "Administrator", "owner": "ashwini@webnotestech.com" }, diff --git a/hr/doctype/appraisal_template/appraisal_template.txt b/hr/doctype/appraisal_template/appraisal_template.txt index 63c14f0889..ff887c449a 100644 --- a/hr/doctype/appraisal_template/appraisal_template.txt +++ b/hr/doctype/appraisal_template/appraisal_template.txt @@ -2,11 +2,12 @@ { "creation": "2012-07-03 13:30:39", "docstatus": 0, - "modified": "2013-07-05 14:25:14", + "modified": "2013-12-20 19:23:55", "modified_by": "Administrator", "owner": "ashwini@webnotestech.com" }, { + "allow_import": 1, "autoname": "field:kra_title", "doctype": "DocType", "document_type": "Master", @@ -25,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Appraisal Template", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR User", diff --git a/hr/doctype/appraisal_template_goal/appraisal_template_goal.txt b/hr/doctype/appraisal_template_goal/appraisal_template_goal.txt index 074c247cca..0657f64e1c 100644 --- a/hr/doctype/appraisal_template_goal/appraisal_template_goal.txt +++ b/hr/doctype/appraisal_template_goal/appraisal_template_goal.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:44", "docstatus": 0, - "modified": "2013-07-10 14:54:03", + "modified": "2013-12-20 19:22:54", "modified_by": "Administrator", "owner": "ashwini@webnotestech.com" }, diff --git a/hr/doctype/attendance/attendance.txt b/hr/doctype/attendance/attendance.txt index 5186a8dbe6..7d383fb9e4 100644 --- a/hr/doctype/attendance/attendance.txt +++ b/hr/doctype/attendance/attendance.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:13", "docstatus": 0, - "modified": "2013-11-02 14:05:42", + "modified": "2013-12-20 19:23:55", "modified_by": "Administrator", "owner": "ashwini@webnotestech.com" }, { + "allow_import": 1, "autoname": "naming_series:", "doctype": "DocType", "document_type": "Master", @@ -28,11 +29,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Attendance", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -154,6 +157,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "options": "Attendance", diff --git a/hr/doctype/branch/branch.txt b/hr/doctype/branch/branch.txt index 3df2cd666d..13aa087b24 100644 --- a/hr/doctype/branch/branch.txt +++ b/hr/doctype/branch/branch.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:13", "docstatus": 0, - "modified": "2013-07-22 15:30:08", + "modified": "2013-12-20 19:23:57", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:branch", "doctype": "DocType", @@ -27,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Branch", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, diff --git a/hr/doctype/deduction_type/deduction_type.txt b/hr/doctype/deduction_type/deduction_type.txt index 1e38f0b79e..e24064e14d 100644 --- a/hr/doctype/deduction_type/deduction_type.txt +++ b/hr/doctype/deduction_type/deduction_type.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-22 16:50:30", "docstatus": 0, - "modified": "2013-07-22 15:25:14", + "modified": "2013-12-20 19:24:02", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:deduction_name", "doctype": "DocType", @@ -27,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Deduction Type", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR User", diff --git a/hr/doctype/department/department.txt b/hr/doctype/department/department.txt index 1f4e4207d8..4cfdcaf8ca 100644 --- a/hr/doctype/department/department.txt +++ b/hr/doctype/department/department.txt @@ -2,11 +2,12 @@ { "creation": "2013-02-05 11:48:26", "docstatus": 0, - "modified": "2013-07-22 15:25:03", + "modified": "2013-12-20 19:24:04", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:department_name", "doctype": "DocType", "document_type": "Master", @@ -26,11 +27,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Department", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR User", diff --git a/hr/doctype/designation/designation.txt b/hr/doctype/designation/designation.txt index 75110c2123..f9b48e46c2 100644 --- a/hr/doctype/designation/designation.txt +++ b/hr/doctype/designation/designation.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:13", "docstatus": 0, - "modified": "2013-07-05 14:35:42", + "modified": "2013-12-20 19:24:04", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:designation_name", "doctype": "DocType", @@ -27,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Designation", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR User", diff --git a/hr/doctype/earning_type/earning_type.txt b/hr/doctype/earning_type/earning_type.txt index 902a4ed85b..c5ead6366e 100644 --- a/hr/doctype/earning_type/earning_type.txt +++ b/hr/doctype/earning_type/earning_type.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-24 11:03:32", "docstatus": 0, - "modified": "2013-12-09 16:24:07", + "modified": "2013-12-20 19:24:05", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:earning_name", "doctype": "DocType", @@ -27,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Earning Type", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR User", diff --git a/hr/doctype/employee/employee.txt b/hr/doctype/employee/employee.txt index c5b5018ac7..225b4850c2 100644 --- a/hr/doctype/employee/employee.txt +++ b/hr/doctype/employee/employee.txt @@ -2,12 +2,13 @@ { "creation": "2013-03-07 09:04:18", "docstatus": 0, - "modified": "2013-11-26 16:36:34", + "modified": "2013-12-20 19:24:06", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 1, + "allow_import": 1, "allow_rename": 1, "autoname": "naming_series:", "doctype": "DocType", @@ -28,11 +29,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Employee", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 @@ -415,7 +418,7 @@ "doctype": "DocField", "fieldname": "reports_to", "fieldtype": "Link", - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "Reports to", "oldfieldname": "reports_to", "oldfieldtype": "Link", diff --git a/hr/doctype/employee_education/employee_education.txt b/hr/doctype/employee_education/employee_education.txt index 69bbbdeace..9204c63779 100644 --- a/hr/doctype/employee_education/employee_education.txt +++ b/hr/doctype/employee_education/employee_education.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:45", "docstatus": 0, - "modified": "2013-07-10 14:54:08", + "modified": "2013-12-20 19:23:12", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/employee_external_work_history/employee_external_work_history.txt b/hr/doctype/employee_external_work_history/employee_external_work_history.txt index 2d5472927a..962c98194e 100644 --- a/hr/doctype/employee_external_work_history/employee_external_work_history.txt +++ b/hr/doctype/employee_external_work_history/employee_external_work_history.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:45", "docstatus": 0, - "modified": "2013-07-10 14:54:08", + "modified": "2013-12-20 19:23:12", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/employee_internal_work_history/employee_internal_work_history.txt b/hr/doctype/employee_internal_work_history/employee_internal_work_history.txt index 9cd03ceea2..2c964faba8 100644 --- a/hr/doctype/employee_internal_work_history/employee_internal_work_history.txt +++ b/hr/doctype/employee_internal_work_history/employee_internal_work_history.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:45", "docstatus": 0, - "modified": "2013-07-10 14:54:08", + "modified": "2013-12-20 19:23:12", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/employee_leave_approver/employee_leave_approver.txt b/hr/doctype/employee_leave_approver/employee_leave_approver.txt index d51d6a128b..4b176d1c0f 100644 --- a/hr/doctype/employee_leave_approver/employee_leave_approver.txt +++ b/hr/doctype/employee_leave_approver/employee_leave_approver.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-12 06:56:15", "docstatus": 0, - "modified": "2013-08-05 14:15:44", + "modified": "2013-12-20 19:23:12", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/employment_type/employment_type.txt b/hr/doctype/employment_type/employment_type.txt index cabfbd7a9b..a13fd872b7 100644 --- a/hr/doctype/employment_type/employment_type.txt +++ b/hr/doctype/employment_type/employment_type.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:14", "docstatus": 0, - "modified": "2013-07-22 15:31:58", + "modified": "2013-12-20 19:24:07", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:employee_type_name", "doctype": "DocType", "document_type": "Master", @@ -26,11 +27,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Employment Type", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, diff --git a/hr/doctype/expense_claim/expense_claim.txt b/hr/doctype/expense_claim/expense_claim.txt index 45ff19b377..5e65aa8ba6 100644 --- a/hr/doctype/expense_claim/expense_claim.txt +++ b/hr/doctype/expense_claim/expense_claim.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:14", "docstatus": 0, - "modified": "2013-09-25 11:36:11", + "modified": "2013-12-20 19:24:07", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, @@ -26,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Expense Claim", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "write": 1 @@ -208,6 +210,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -226,7 +229,6 @@ "amend": 1, "cancel": 1, "doctype": "DocPerm", - "match": "exp_approver:user", "role": "Expense Approver", "submit": 1 }, diff --git a/hr/doctype/expense_claim_detail/expense_claim_detail.txt b/hr/doctype/expense_claim_detail/expense_claim_detail.txt index e9c5a99693..18b8036b33 100644 --- a/hr/doctype/expense_claim_detail/expense_claim_detail.txt +++ b/hr/doctype/expense_claim_detail/expense_claim_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:46", "docstatus": 0, - "modified": "2013-07-10 14:54:09", + "modified": "2013-12-20 19:23:13", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, diff --git a/hr/doctype/expense_claim_type/expense_claim_type.txt b/hr/doctype/expense_claim_type/expense_claim_type.txt index 4d7035063d..689da6eb48 100644 --- a/hr/doctype/expense_claim_type/expense_claim_type.txt +++ b/hr/doctype/expense_claim_type/expense_claim_type.txt @@ -2,11 +2,12 @@ { "creation": "2012-03-27 14:35:55", "docstatus": 0, - "modified": "2013-07-05 14:37:47", + "modified": "2013-12-20 19:24:07", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, { + "allow_import": 1, "autoname": "field:expense_type", "doctype": "DocType", "document_type": "Master", @@ -25,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Expense Claim Type", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR Manager", diff --git a/hr/doctype/grade/grade.txt b/hr/doctype/grade/grade.txt index fdfa5c737c..4743bf1ccc 100644 --- a/hr/doctype/grade/grade.txt +++ b/hr/doctype/grade/grade.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:14", "docstatus": 0, - "modified": "2013-07-26 15:24:31", + "modified": "2013-12-20 19:24:08", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:grade_name", "doctype": "DocType", "document_type": "Master", @@ -32,11 +33,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Grade", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR User", diff --git a/hr/doctype/holiday/holiday.txt b/hr/doctype/holiday/holiday.txt index 3b87bb08c7..ad8ddb07d3 100644 --- a/hr/doctype/holiday/holiday.txt +++ b/hr/doctype/holiday/holiday.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:46", "docstatus": 0, - "modified": "2013-07-10 14:54:09", + "modified": "2013-12-20 19:23:14", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/holiday_list/holiday_list.txt b/hr/doctype/holiday_list/holiday_list.txt index 5978f1457b..8f0832b130 100644 --- a/hr/doctype/holiday_list/holiday_list.txt +++ b/hr/doctype/holiday_list/holiday_list.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:14", "docstatus": 0, - "modified": "2013-07-05 14:40:02", + "modified": "2013-12-20 19:24:08", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "doctype": "DocType", "document_type": "Master", "icon": "icon-calendar", @@ -25,11 +26,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Holiday List", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR Manager", diff --git a/hr/doctype/hr_settings/hr_settings.txt b/hr/doctype/hr_settings/hr_settings.txt index bf4b0119aa..cd1cf05d05 100644 --- a/hr/doctype/hr_settings/hr_settings.txt +++ b/hr/doctype/hr_settings/hr_settings.txt @@ -2,7 +2,7 @@ { "creation": "2013-08-02 13:45:23", "docstatus": 0, - "modified": "2013-10-02 15:44:38", + "modified": "2013-12-20 19:23:14", "modified_by": "Administrator", "owner": "Administrator" }, @@ -25,11 +25,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "HR Settings", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "System Manager", "write": 1 diff --git a/hr/doctype/job_applicant/job_applicant.txt b/hr/doctype/job_applicant/job_applicant.txt index d795fa83bc..8f0d41ae3a 100644 --- a/hr/doctype/job_applicant/job_applicant.txt +++ b/hr/doctype/job_applicant/job_applicant.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-29 19:25:37", "docstatus": 0, - "modified": "2013-09-10 10:51:51", + "modified": "2013-12-20 19:24:10", "modified_by": "Administrator", "owner": "Administrator" }, @@ -28,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Job Applicant", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR User", diff --git a/hr/doctype/job_opening/job_opening.txt b/hr/doctype/job_opening/job_opening.txt index a507547d6e..dcf76ddb3a 100644 --- a/hr/doctype/job_opening/job_opening.txt +++ b/hr/doctype/job_opening/job_opening.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-15 16:13:36", "docstatus": 0, - "modified": "2013-07-05 14:43:35", + "modified": "2013-12-20 19:24:11", "modified_by": "Administrator", "owner": "Administrator" }, @@ -27,11 +27,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Job Opening", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "HR User", diff --git a/hr/doctype/leave_allocation/leave_allocation.txt b/hr/doctype/leave_allocation/leave_allocation.txt index 38e3eb57c9..6e5fe64019 100644 --- a/hr/doctype/leave_allocation/leave_allocation.txt +++ b/hr/doctype/leave_allocation/leave_allocation.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-20 19:10:38", "docstatus": 0, - "modified": "2013-12-12 17:41:52", + "modified": "2013-12-20 19:24:12", "modified_by": "Administrator", "owner": "Administrator" }, @@ -29,11 +29,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Leave Allocation", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -158,6 +160,7 @@ "fieldname": "amended_from", "fieldtype": "Data", "hidden": 0, + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/hr/doctype/leave_application/leave_application.txt b/hr/doctype/leave_application/leave_application.txt index d5feb57a9e..10c0429077 100644 --- a/hr/doctype/leave_application/leave_application.txt +++ b/hr/doctype/leave_application/leave_application.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-20 11:18:11", "docstatus": 0, - "modified": "2013-07-05 14:44:37", + "modified": "2013-12-20 19:24:12", "modified_by": "Administrator", "owner": "Administrator" }, @@ -220,6 +220,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "options": "Leave Application", @@ -230,8 +231,9 @@ { "create": 1, "doctype": "DocPerm", - "match": "employee", + "email": 1, "permlevel": 0, + "print": 1, "report": 1, "role": "Employee", "write": 1 @@ -250,7 +252,9 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "report": 1, "role": "HR User", "submit": 1, @@ -261,8 +265,9 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", - "match": "leave_approver:user", + "email": 1, "permlevel": 0, + "print": 1, "report": 1, "role": "Leave Approver", "submit": 1, diff --git a/hr/doctype/leave_block_list/leave_block_list.txt b/hr/doctype/leave_block_list/leave_block_list.txt index 770bfeecfa..6f331b0c53 100644 --- a/hr/doctype/leave_block_list/leave_block_list.txt +++ b/hr/doctype/leave_block_list/leave_block_list.txt @@ -2,11 +2,12 @@ { "creation": "2013-02-18 17:43:12", "docstatus": 0, - "modified": "2013-07-05 14:44:45", + "modified": "2013-12-20 19:24:13", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:leave_block_list_name", "description": "Block Holidays on important days.", "doctype": "DocType", @@ -26,11 +27,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Leave Block List", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "HR User", "write": 1 diff --git a/hr/doctype/leave_block_list_allow/leave_block_list_allow.txt b/hr/doctype/leave_block_list_allow/leave_block_list_allow.txt index 1e8c86b8c1..94fd3de796 100644 --- a/hr/doctype/leave_block_list_allow/leave_block_list_allow.txt +++ b/hr/doctype/leave_block_list_allow/leave_block_list_allow.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:47", "docstatus": 0, - "modified": "2013-07-10 14:54:10", + "modified": "2013-12-20 19:23:19", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/leave_block_list_date/leave_block_list_date.txt b/hr/doctype/leave_block_list_date/leave_block_list_date.txt index c13e2d57c2..138c9e47b5 100644 --- a/hr/doctype/leave_block_list_date/leave_block_list_date.txt +++ b/hr/doctype/leave_block_list_date/leave_block_list_date.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:47", "docstatus": 0, - "modified": "2013-07-10 14:54:10", + "modified": "2013-12-20 19:23:19", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/leave_type/leave_type.txt b/hr/doctype/leave_type/leave_type.txt index dd339dc53c..adae0d9836 100644 --- a/hr/doctype/leave_type/leave_type.txt +++ b/hr/doctype/leave_type/leave_type.txt @@ -2,11 +2,12 @@ { "creation": "2013-02-21 09:55:58", "docstatus": 0, - "modified": "2013-07-22 15:32:07", + "modified": "2013-12-20 19:24:13", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:leave_type_name", "doctype": "DocType", "document_type": "Master", @@ -26,11 +27,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Leave Type", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, diff --git a/hr/doctype/salary_slip/salary_slip.txt b/hr/doctype/salary_slip/salary_slip.txt index 641adae946..1f94aa83e0 100644 --- a/hr/doctype/salary_slip/salary_slip.txt +++ b/hr/doctype/salary_slip/salary_slip.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:15", "docstatus": 0, - "modified": "2013-08-02 19:23:13", + "modified": "2013-12-20 19:24:27", "modified_by": "Administrator", "owner": "Administrator" }, @@ -24,11 +24,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Salary Slip", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -248,6 +250,7 @@ "fieldname": "amended_from", "fieldtype": "Data", "hidden": 0, + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/hr/doctype/salary_slip_deduction/salary_slip_deduction.txt b/hr/doctype/salary_slip_deduction/salary_slip_deduction.txt index d0a4f47192..2b2909038c 100644 --- a/hr/doctype/salary_slip_deduction/salary_slip_deduction.txt +++ b/hr/doctype/salary_slip_deduction/salary_slip_deduction.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:48", "docstatus": 0, - "modified": "2013-07-22 15:27:44", + "modified": "2013-12-20 19:23:42", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/salary_slip_earning/salary_slip_earning.txt b/hr/doctype/salary_slip_earning/salary_slip_earning.txt index 3fc25facb2..3375ab55d1 100644 --- a/hr/doctype/salary_slip_earning/salary_slip_earning.txt +++ b/hr/doctype/salary_slip_earning/salary_slip_earning.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:48", "docstatus": 0, - "modified": "2013-07-22 15:27:56", + "modified": "2013-12-20 19:23:43", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/salary_structure/salary_structure.txt b/hr/doctype/salary_structure/salary_structure.txt index 1c6a86b94b..e54ebd7e59 100644 --- a/hr/doctype/salary_structure/salary_structure.txt +++ b/hr/doctype/salary_structure/salary_structure.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 18:50:29", "docstatus": 0, - "modified": "2013-08-06 17:15:53", + "modified": "2013-12-20 19:24:28", "modified_by": "Administrator", "owner": "Administrator" }, @@ -25,11 +25,13 @@ "amend": 0, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Salary Structure", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, diff --git a/hr/doctype/salary_structure_deduction/salary_structure_deduction.txt b/hr/doctype/salary_structure_deduction/salary_structure_deduction.txt index 0af263274d..845a70fde7 100644 --- a/hr/doctype/salary_structure_deduction/salary_structure_deduction.txt +++ b/hr/doctype/salary_structure_deduction/salary_structure_deduction.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:48", "docstatus": 0, - "modified": "2013-08-06 17:11:40", + "modified": "2013-12-20 19:23:43", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/salary_structure_earning/salary_structure_earning.txt b/hr/doctype/salary_structure_earning/salary_structure_earning.txt index 609fd6c156..d90c3cdd3b 100644 --- a/hr/doctype/salary_structure_earning/salary_structure_earning.txt +++ b/hr/doctype/salary_structure_earning/salary_structure_earning.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:48", "docstatus": 0, - "modified": "2013-08-06 17:11:31", + "modified": "2013-12-20 19:23:43", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/hr/doctype/upload_attendance/upload_attendance.txt b/hr/doctype/upload_attendance/upload_attendance.txt index ea861be185..5c727619ed 100644 --- a/hr/doctype/upload_attendance/upload_attendance.txt +++ b/hr/doctype/upload_attendance/upload_attendance.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-25 11:34:53", "docstatus": 0, - "modified": "2013-07-05 15:02:09", + "modified": "2013-12-20 19:21:54", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, @@ -26,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Upload Attendance", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 0, "submit": 0, diff --git a/manufacturing/doctype/bom/bom.txt b/manufacturing/doctype/bom/bom.txt index a5ff125293..505d8d75aa 100644 --- a/manufacturing/doctype/bom/bom.txt +++ b/manufacturing/doctype/bom/bom.txt @@ -2,15 +2,14 @@ { "creation": "2013-01-22 15:11:38", "docstatus": 0, - "modified": "2013-12-09 16:25:50", + "modified": "2013-12-20 19:23:57", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 0, "allow_copy": 0, - "allow_email": 0, - "allow_print": 0, + "allow_import": 1, "allow_rename": 0, "doctype": "DocType", "document_type": "Master", @@ -38,11 +37,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "BOM", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -239,6 +240,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "options": "BOM", diff --git a/manufacturing/doctype/bom_explosion_item/bom_explosion_item.txt b/manufacturing/doctype/bom_explosion_item/bom_explosion_item.txt index abc74cd35b..55342aa59f 100644 --- a/manufacturing/doctype/bom_explosion_item/bom_explosion_item.txt +++ b/manufacturing/doctype/bom_explosion_item/bom_explosion_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 11:42:57", "docstatus": 0, - "modified": "2013-07-10 14:54:04", + "modified": "2013-12-20 19:22:57", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/manufacturing/doctype/bom_item/bom_item.txt b/manufacturing/doctype/bom_item/bom_item.txt index e498c71270..b7017f487c 100644 --- a/manufacturing/doctype/bom_item/bom_item.txt +++ b/manufacturing/doctype/bom_item/bom_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:49", "docstatus": 0, - "modified": "2013-07-25 16:34:42", + "modified": "2013-12-20 19:22:58", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/manufacturing/doctype/bom_operation/bom_operation.txt b/manufacturing/doctype/bom_operation/bom_operation.txt index cffdf4c9f0..6ace745c14 100644 --- a/manufacturing/doctype/bom_operation/bom_operation.txt +++ b/manufacturing/doctype/bom_operation/bom_operation.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:49", "docstatus": 0, - "modified": "2013-12-04 11:18:59", + "modified": "2013-12-20 19:22:58", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/manufacturing/doctype/production_order/production_order.txt b/manufacturing/doctype/production_order/production_order.txt index 5e76c0e18f..ed1c66886b 100644 --- a/manufacturing/doctype/production_order/production_order.txt +++ b/manufacturing/doctype/production_order/production_order.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:16", "docstatus": 0, - "modified": "2013-12-18 13:22:14", + "modified": "2013-12-20 19:24:16", "modified_by": "Administrator", "owner": "Administrator" }, @@ -29,11 +29,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Production Order", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Manufacturing User", @@ -251,6 +253,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/manufacturing/doctype/production_plan_item/production_plan_item.txt b/manufacturing/doctype/production_plan_item/production_plan_item.txt index 7bcaaca298..20681881c3 100644 --- a/manufacturing/doctype/production_plan_item/production_plan_item.txt +++ b/manufacturing/doctype/production_plan_item/production_plan_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:49", "docstatus": 0, - "modified": "2013-08-08 12:12:27", + "modified": "2013-12-20 19:23:25", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/manufacturing/doctype/production_plan_sales_order/production_plan_sales_order.txt b/manufacturing/doctype/production_plan_sales_order/production_plan_sales_order.txt index fab7dd0ddb..11a02a56aa 100644 --- a/manufacturing/doctype/production_plan_sales_order/production_plan_sales_order.txt +++ b/manufacturing/doctype/production_plan_sales_order/production_plan_sales_order.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:49", "docstatus": 0, - "modified": "2013-07-22 15:26:23", + "modified": "2013-12-20 19:23:25", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/manufacturing/doctype/production_planning_tool/production_planning_tool.txt b/manufacturing/doctype/production_planning_tool/production_planning_tool.txt index c3a1d8f0d5..4c3b065f4a 100644 --- a/manufacturing/doctype/production_planning_tool/production_planning_tool.txt +++ b/manufacturing/doctype/production_planning_tool/production_planning_tool.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-21 12:03:47", "docstatus": 0, - "modified": "2013-08-08 12:01:02", + "modified": "2013-12-20 19:23:25", "modified_by": "Administrator", "owner": "jai@webnotestech.com" }, @@ -27,11 +27,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Production Planning Tool", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 0, "role": "Manufacturing User", diff --git a/manufacturing/doctype/workstation/workstation.txt b/manufacturing/doctype/workstation/workstation.txt index c9114ff85f..306ca4ecef 100644 --- a/manufacturing/doctype/workstation/workstation.txt +++ b/manufacturing/doctype/workstation/workstation.txt @@ -2,12 +2,12 @@ { "creation": "2013-01-10 16:34:17", "docstatus": 0, - "modified": "2013-10-28 15:42:38", + "modified": "2013-12-20 19:24:41", "modified_by": "Administrator", "owner": "Administrator" }, { - "allow_email": 0, + "allow_import": 1, "autoname": "field:workstation_name", "doctype": "DocType", "document_type": "Master", @@ -27,11 +27,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Workstation", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Manufacturing User", diff --git a/projects/doctype/activity_type/activity_type.txt b/projects/doctype/activity_type/activity_type.txt index 94fffe7eb6..d8a50c519d 100644 --- a/projects/doctype/activity_type/activity_type.txt +++ b/projects/doctype/activity_type/activity_type.txt @@ -2,11 +2,12 @@ { "creation": "2013-03-05 10:14:59", "docstatus": 0, - "modified": "2013-07-05 14:23:55", + "modified": "2013-12-20 19:23:54", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:activity_type", "doctype": "DocType", "document_type": "Master", @@ -30,11 +31,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Activity Type", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "write": 1 diff --git a/projects/doctype/project/project.txt b/projects/doctype/project/project.txt index 9f21dce946..a1967bb310 100644 --- a/projects/doctype/project/project.txt +++ b/projects/doctype/project/project.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 11:55:07", "docstatus": 0, - "modified": "2013-11-06 15:13:55", + "modified": "2013-12-20 19:24:17", "modified_by": "Administrator", "owner": "Administrator" }, @@ -292,7 +292,9 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "role": "Projects User", "write": 1 }, diff --git a/projects/doctype/project_milestone/project_milestone.txt b/projects/doctype/project_milestone/project_milestone.txt index 31722d6359..d5be81e9d8 100644 --- a/projects/doctype/project_milestone/project_milestone.txt +++ b/projects/doctype/project_milestone/project_milestone.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:50", "docstatus": 0, - "modified": "2013-07-10 14:54:12", + "modified": "2013-12-20 19:23:27", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/projects/doctype/task/task.txt b/projects/doctype/task/task.txt index 1c12c8a534..7ddd51a494 100644 --- a/projects/doctype/task/task.txt +++ b/projects/doctype/task/task.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-29 19:25:50", "docstatus": 0, - "modified": "2013-10-02 14:25:00", + "modified": "2013-12-20 19:24:38", "modified_by": "Administrator", "owner": "Administrator" }, @@ -29,11 +29,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Task", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Projects User", diff --git a/projects/doctype/time_log/time_log.txt b/projects/doctype/time_log/time_log.txt index 1c8e00f4f2..2ad9d647b9 100644 --- a/projects/doctype/time_log/time_log.txt +++ b/projects/doctype/time_log/time_log.txt @@ -2,12 +2,13 @@ { "creation": "2013-04-03 16:38:41", "docstatus": 0, - "modified": "2013-11-02 14:05:45", + "modified": "2013-12-20 19:24:39", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 1, + "allow_import": 1, "autoname": "naming_series:", "description": "Log of Activities performed by users against Tasks that can be used for tracking time, billing.", "doctype": "DocType", @@ -28,11 +29,13 @@ "amend": 1, "cancel": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Time Log", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -190,6 +193,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "options": "Time Log", diff --git a/projects/doctype/time_log_batch/time_log_batch.txt b/projects/doctype/time_log_batch/time_log_batch.txt index 74bcc4dc8a..458f0ed31b 100644 --- a/projects/doctype/time_log_batch/time_log_batch.txt +++ b/projects/doctype/time_log_batch/time_log_batch.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-28 17:57:33", "docstatus": 0, - "modified": "2013-11-02 14:05:45", + "modified": "2013-12-20 19:24:39", "modified_by": "Administrator", "owner": "Administrator" }, @@ -29,11 +29,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Time Log Batch", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Projects User", @@ -110,6 +112,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "options": "Time Log Batch", diff --git a/projects/doctype/time_log_batch_detail/time_log_batch_detail.txt b/projects/doctype/time_log_batch_detail/time_log_batch_detail.txt index 98eca10092..973fc576b7 100644 --- a/projects/doctype/time_log_batch_detail/time_log_batch_detail.txt +++ b/projects/doctype/time_log_batch_detail/time_log_batch_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-05 09:11:06", "docstatus": 0, - "modified": "2013-07-10 14:54:25", + "modified": "2013-12-20 19:21:53", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/campaign/campaign.txt b/selling/doctype/campaign/campaign.txt index 7025bf5654..07cddd419f 100644 --- a/selling/doctype/campaign/campaign.txt +++ b/selling/doctype/campaign/campaign.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:18", "docstatus": 0, - "modified": "2013-07-05 14:29:57", + "modified": "2013-12-20 19:23:58", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:campaign_name", "description": "Keep Track of Sales Campaigns. Keep track of Leads, Quotations, Sales Order etc from Campaigns to gauge Return on Investment. ", "doctype": "DocType", @@ -26,13 +27,14 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Campaign", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, - "report": 1, "submit": 0 }, { @@ -77,6 +79,8 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", + "import": 0, + "report": 0, "role": "Sales Manager", "write": 0 }, @@ -84,6 +88,7 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", + "report": 1, "role": "Sales User", "write": 0 }, @@ -91,6 +96,7 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "report": 1, "role": "Sales Master Manager", "write": 1 } diff --git a/selling/doctype/customer/customer.txt b/selling/doctype/customer/customer.txt index 7a24531665..92fa62659c 100644 --- a/selling/doctype/customer/customer.txt +++ b/selling/doctype/customer/customer.txt @@ -2,12 +2,12 @@ { "creation": "2013-06-11 14:26:44", "docstatus": 0, - "modified": "2013-11-03 14:01:33", + "modified": "2013-12-20 19:24:01", "modified_by": "Administrator", "owner": "Administrator" }, { - "allow_print": 0, + "allow_import": 1, "allow_rename": 1, "autoname": "naming_series:", "description": "Buyer of Goods and Services.", @@ -346,7 +346,9 @@ "cancel": 0, "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "report": 1, "role": "Sales User", "submit": 0, @@ -362,7 +364,9 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "report": 1, "role": "Sales Master Manager", "submit": 0, diff --git a/selling/doctype/customer_discount/customer_discount.txt b/selling/doctype/customer_discount/customer_discount.txt index 135871db81..5abe3b6ac9 100644 --- a/selling/doctype/customer_discount/customer_discount.txt +++ b/selling/doctype/customer_discount/customer_discount.txt @@ -2,7 +2,7 @@ { "creation": "2013-07-22 12:43:40", "docstatus": 0, - "modified": "2013-11-02 19:41:31", + "modified": "2013-12-20 19:23:04", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/industry_type/industry_type.txt b/selling/doctype/industry_type/industry_type.txt index 3c97b3e682..e65fc3812a 100644 --- a/selling/doctype/industry_type/industry_type.txt +++ b/selling/doctype/industry_type/industry_type.txt @@ -2,11 +2,12 @@ { "creation": "2012-03-27 14:36:09", "docstatus": 0, - "modified": "2013-07-05 14:40:42", + "modified": "2013-12-20 19:24:08", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, { + "allow_import": 1, "autoname": "field:industry", "doctype": "DocType", "document_type": "Master", @@ -30,11 +31,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Industry Type", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, diff --git a/selling/doctype/installation_note/installation_note.txt b/selling/doctype/installation_note/installation_note.txt index af81d7fb5b..d23a68ac18 100644 --- a/selling/doctype/installation_note/installation_note.txt +++ b/selling/doctype/installation_note/installation_note.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-30 13:13:06", "docstatus": 0, - "modified": "2013-11-02 16:58:44", + "modified": "2013-12-20 19:24:08", "modified_by": "Administrator", "owner": "Administrator" }, @@ -219,6 +219,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -257,7 +258,9 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "submit": 1, "write": 1 }, diff --git a/selling/doctype/installation_note_item/installation_note_item.txt b/selling/doctype/installation_note_item/installation_note_item.txt index 7435d461b4..94f648e3a6 100644 --- a/selling/doctype/installation_note_item/installation_note_item.txt +++ b/selling/doctype/installation_note_item/installation_note_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:51", "docstatus": 0, - "modified": "2013-10-10 17:02:31", + "modified": "2013-12-20 19:23:14", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/lead/lead.txt b/selling/doctype/lead/lead.txt index 6e6b61af85..dc8bcdbb1a 100644 --- a/selling/doctype/lead/lead.txt +++ b/selling/doctype/lead/lead.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-10 11:45:37", "docstatus": 0, - "modified": "2013-11-25 11:38:00", + "modified": "2013-12-20 19:24:12", "modified_by": "Administrator", "owner": "Administrator" }, @@ -28,11 +28,13 @@ "amend": 0, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Lead", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, diff --git a/selling/doctype/opportunity/opportunity.txt b/selling/doctype/opportunity/opportunity.txt index fec94c8dca..d0dc0f54b6 100644 --- a/selling/doctype/opportunity/opportunity.txt +++ b/selling/doctype/opportunity/opportunity.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 18:50:30", "docstatus": 0, - "modified": "2013-11-25 11:36:40", + "modified": "2013-12-20 19:24:15", "modified_by": "Administrator", "owner": "Administrator" }, @@ -31,11 +31,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Opportunity", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -415,6 +417,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/selling/doctype/opportunity_item/opportunity_item.txt b/selling/doctype/opportunity_item/opportunity_item.txt index efa1ee90bd..94c6dd25b6 100644 --- a/selling/doctype/opportunity_item/opportunity_item.txt +++ b/selling/doctype/opportunity_item/opportunity_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:51", "docstatus": 0, - "modified": "2013-11-02 19:41:31", + "modified": "2013-12-20 19:23:22", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/quotation/quotation.txt b/selling/doctype/quotation/quotation.txt index 93346d3029..3657e4acef 100644 --- a/selling/doctype/quotation/quotation.txt +++ b/selling/doctype/quotation/quotation.txt @@ -2,13 +2,12 @@ { "creation": "2013-05-24 19:29:08", "docstatus": 0, - "modified": "2013-12-14 17:25:46", + "modified": "2013-12-20 19:24:25", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 1, - "allow_email": 0, "allow_import": 1, "autoname": "naming_series:", "doctype": "DocType", @@ -32,11 +31,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Quotation", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -178,6 +179,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -863,7 +865,6 @@ "cancel": 0, "create": 0, "doctype": "DocPerm", - "match": "customer", "role": "Customer", "submit": 0, "write": 0 diff --git a/selling/doctype/quotation_item/quotation_item.txt b/selling/doctype/quotation_item/quotation_item.txt index 37642086b8..e669937d09 100644 --- a/selling/doctype/quotation_item/quotation_item.txt +++ b/selling/doctype/quotation_item/quotation_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 11:42:57", "docstatus": 0, - "modified": "2013-11-02 19:41:32", + "modified": "2013-12-20 19:23:41", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/sales_bom/sales_bom.txt b/selling/doctype/sales_bom/sales_bom.txt index 9a9b6e67cc..cd1ea28d85 100644 --- a/selling/doctype/sales_bom/sales_bom.txt +++ b/selling/doctype/sales_bom/sales_bom.txt @@ -2,11 +2,12 @@ { "creation": "2013-06-20 11:53:21", "docstatus": 0, - "modified": "2013-07-05 14:54:08", + "modified": "2013-12-20 19:24:28", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "description": "Aggregate group of **Items** into another **Item**. This is useful if you are bundling a certain **Items** into a package and you maintain stock of the packed **Items** and not the aggregate **Item**. \n\nThe package **Item** will have \"Is Stock Item\" as \"No\" and \"Is Sales Item\" as \"Yes\".\n\nFor Example: If you are selling Laptops and Backpacks separately and have a special price if the customer buys both, then the Laptop + Backpack will be a new Sales BOM Item.\n\nNote: BOM = Bill of Materials", "doctype": "DocType", "document_type": "Master", @@ -26,11 +27,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Sales BOM", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/selling/doctype/sales_bom_item/sales_bom_item.txt b/selling/doctype/sales_bom_item/sales_bom_item.txt index 9e880bc8cd..e06d8f8241 100644 --- a/selling/doctype/sales_bom_item/sales_bom_item.txt +++ b/selling/doctype/sales_bom_item/sales_bom_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-23 16:55:51", "docstatus": 0, - "modified": "2013-09-09 15:47:56", + "modified": "2013-12-20 19:21:38", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/sales_order/sales_order.txt b/selling/doctype/sales_order/sales_order.txt index 7a1af77947..f9582fb213 100644 --- a/selling/doctype/sales_order/sales_order.txt +++ b/selling/doctype/sales_order/sales_order.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-18 12:39:59", "docstatus": 0, - "modified": "2013-11-03 14:20:16", + "modified": "2013-12-20 19:24:32", "modified_by": "Administrator", "owner": "Administrator" }, @@ -30,11 +30,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Sales Order", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1 }, { @@ -149,6 +151,7 @@ "fieldname": "amended_from", "fieldtype": "Data", "hidden": 1, + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -921,7 +924,6 @@ }, { "doctype": "DocPerm", - "match": "customer", "role": "Customer" } ] \ No newline at end of file diff --git a/selling/doctype/sales_order_item/sales_order_item.txt b/selling/doctype/sales_order_item/sales_order_item.txt index 4754aa1404..eb656a600a 100644 --- a/selling/doctype/sales_order_item/sales_order_item.txt +++ b/selling/doctype/sales_order_item/sales_order_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 11:42:58", "docstatus": 0, - "modified": "2013-11-03 14:14:17", + "modified": "2013-12-20 19:21:43", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/sales_team/sales_team.txt b/selling/doctype/sales_team/sales_team.txt index ae50814b11..9b584296e8 100644 --- a/selling/doctype/sales_team/sales_team.txt +++ b/selling/doctype/sales_team/sales_team.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-19 13:30:51", "docstatus": 0, - "modified": "2013-07-10 14:54:22", + "modified": "2013-12-20 19:21:46", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/selling_settings/selling_settings.txt b/selling/doctype/selling_settings/selling_settings.txt index a112a7cd69..2a93263de7 100644 --- a/selling/doctype/selling_settings/selling_settings.txt +++ b/selling/doctype/selling_settings/selling_settings.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-25 10:25:16", "docstatus": 0, - "modified": "2013-11-02 16:58:56", + "modified": "2013-12-20 19:21:46", "modified_by": "Administrator", "owner": "Administrator" }, @@ -26,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Selling Settings", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "System Manager", "write": 1 diff --git a/selling/doctype/shopping_cart_price_list/shopping_cart_price_list.txt b/selling/doctype/shopping_cart_price_list/shopping_cart_price_list.txt index 1737c65c90..7cd61f7370 100644 --- a/selling/doctype/shopping_cart_price_list/shopping_cart_price_list.txt +++ b/selling/doctype/shopping_cart_price_list/shopping_cart_price_list.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-20 16:00:18", "docstatus": 0, - "modified": "2013-08-09 14:47:15", + "modified": "2013-12-20 19:21:47", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/shopping_cart_settings/shopping_cart_settings.txt b/selling/doctype/shopping_cart_settings/shopping_cart_settings.txt index ffc3635660..f52cc60c7f 100644 --- a/selling/doctype/shopping_cart_settings/shopping_cart_settings.txt +++ b/selling/doctype/shopping_cart_settings/shopping_cart_settings.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-19 15:57:32", "docstatus": 0, - "modified": "2013-11-02 16:58:56", + "modified": "2013-12-20 19:21:47", "modified_by": "Administrator", "owner": "Administrator" }, @@ -25,11 +25,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Shopping Cart Settings", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "Website Manager", "write": 1 diff --git a/selling/doctype/shopping_cart_shipping_rule/shopping_cart_shipping_rule.txt b/selling/doctype/shopping_cart_shipping_rule/shopping_cart_shipping_rule.txt index 8c9c34a079..91b41c2fb4 100644 --- a/selling/doctype/shopping_cart_shipping_rule/shopping_cart_shipping_rule.txt +++ b/selling/doctype/shopping_cart_shipping_rule/shopping_cart_shipping_rule.txt @@ -2,7 +2,7 @@ { "creation": "2013-07-03 13:15:34", "docstatus": 0, - "modified": "2013-07-10 14:54:25", + "modified": "2013-12-20 19:21:47", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/selling/doctype/shopping_cart_taxes_and_charges_master/shopping_cart_taxes_and_charges_master.txt b/selling/doctype/shopping_cart_taxes_and_charges_master/shopping_cart_taxes_and_charges_master.txt index a61f8dbdf1..ba4419997b 100644 --- a/selling/doctype/shopping_cart_taxes_and_charges_master/shopping_cart_taxes_and_charges_master.txt +++ b/selling/doctype/shopping_cart_taxes_and_charges_master/shopping_cart_taxes_and_charges_master.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-20 16:57:03", "docstatus": 0, - "modified": "2013-07-10 14:54:25", + "modified": "2013-12-20 19:21:47", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/setup/doctype/applicable_territory/applicable_territory.txt b/setup/doctype/applicable_territory/applicable_territory.txt index 10d84d14c5..3a5b0f351b 100644 --- a/setup/doctype/applicable_territory/applicable_territory.txt +++ b/setup/doctype/applicable_territory/applicable_territory.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-20 12:48:38", "docstatus": 0, - "modified": "2013-11-02 16:58:57", + "modified": "2013-12-20 19:22:53", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/setup/doctype/authorization_control/authorization_control.txt b/setup/doctype/authorization_control/authorization_control.txt index 897994b732..c5628d23dd 100644 --- a/setup/doctype/authorization_control/authorization_control.txt +++ b/setup/doctype/authorization_control/authorization_control.txt @@ -2,7 +2,7 @@ { "creation": "2012-03-27 14:36:18", "docstatus": 0, - "modified": "2013-07-10 14:54:03", + "modified": "2013-12-20 19:22:54", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/setup/doctype/authorization_rule/authorization_rule.txt b/setup/doctype/authorization_rule/authorization_rule.txt index 4af3eaad67..36467f2f4f 100644 --- a/setup/doctype/authorization_rule/authorization_rule.txt +++ b/setup/doctype/authorization_rule/authorization_rule.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:22", "docstatus": 0, - "modified": "2013-08-07 14:44:52", + "modified": "2013-12-20 19:23:55", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "AR.####", "doctype": "DocType", "document_type": "Master", @@ -27,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Authorization Rule", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "System Manager", diff --git a/setup/doctype/backup_manager/backup_manager.txt b/setup/doctype/backup_manager/backup_manager.txt index cf4dbcc4f2..259bf378dd 100644 --- a/setup/doctype/backup_manager/backup_manager.txt +++ b/setup/doctype/backup_manager/backup_manager.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-30 12:58:38", "docstatus": 0, - "modified": "2013-07-05 14:26:02", + "modified": "2013-12-20 19:22:55", "modified_by": "Administrator", "owner": "Administrator" }, @@ -26,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Backup Manager", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "System Manager", "write": 1 diff --git a/setup/doctype/brand/brand.txt b/setup/doctype/brand/brand.txt index 1fd9cec210..3dcb016166 100644 --- a/setup/doctype/brand/brand.txt +++ b/setup/doctype/brand/brand.txt @@ -2,11 +2,12 @@ { "creation": "2013-02-22 01:27:54", "docstatus": 0, - "modified": "2013-07-23 12:06:41", + "modified": "2013-12-20 19:23:58", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:brand", "doctype": "DocType", "document_type": "Master", @@ -26,11 +27,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Brand", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, diff --git a/setup/doctype/company/company.txt b/setup/doctype/company/company.txt index 8c3860ab2d..1e763ea678 100644 --- a/setup/doctype/company/company.txt +++ b/setup/doctype/company/company.txt @@ -2,11 +2,12 @@ { "creation": "2013-04-10 08:35:39", "docstatus": 0, - "modified": "2013-11-02 14:24:11", + "modified": "2013-12-20 19:23:59", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:company_name", "description": "Legal Entity / Subsidiary with a separate Chart of Accounts belonging to the Organization.", @@ -26,11 +27,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Company", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1 }, { diff --git a/setup/doctype/contact_control/contact_control.txt b/setup/doctype/contact_control/contact_control.txt index 80caeae1e2..a5a0d01c27 100644 --- a/setup/doctype/contact_control/contact_control.txt +++ b/setup/doctype/contact_control/contact_control.txt @@ -2,7 +2,7 @@ { "creation": "2012-03-27 14:36:19", "docstatus": 0, - "modified": "2013-07-10 14:54:06", + "modified": "2013-12-20 19:23:02", "modified_by": "Administrator", "owner": "Administrator" }, @@ -27,11 +27,13 @@ { "create": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Contact Control", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "System Manager", "write": 1 diff --git a/setup/doctype/country/country.txt b/setup/doctype/country/country.txt index 8b811a3342..991c8a9310 100644 --- a/setup/doctype/country/country.txt +++ b/setup/doctype/country/country.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-19 10:23:30", "docstatus": 0, - "modified": "2013-07-23 12:05:08", + "modified": "2013-12-20 19:24:00", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:country_name", "doctype": "DocType", "document_type": "Master", @@ -26,11 +27,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Country", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, diff --git a/setup/doctype/currency/currency.txt b/setup/doctype/currency/currency.txt index 7476ccf435..709e360204 100644 --- a/setup/doctype/currency/currency.txt +++ b/setup/doctype/currency/currency.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-28 10:06:02", "docstatus": 0, - "modified": "2013-07-23 12:05:26", + "modified": "2013-12-20 19:24:00", "modified_by": "Administrator", "owner": "Administrator" }, @@ -26,11 +26,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Currency", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, diff --git a/setup/doctype/currency_exchange/currency_exchange.txt b/setup/doctype/currency_exchange/currency_exchange.txt index db2083910c..f0f5c39cc8 100644 --- a/setup/doctype/currency_exchange/currency_exchange.txt +++ b/setup/doctype/currency_exchange/currency_exchange.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-20 15:40:29", "docstatus": 0, - "modified": "2013-07-05 16:26:11", + "modified": "2013-12-20 19:24:00", "modified_by": "Administrator", "owner": "Administrator" }, @@ -26,11 +26,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Currency Exchange", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, diff --git a/setup/doctype/customer_group/customer_group.txt b/setup/doctype/customer_group/customer_group.txt index f90c14d336..5b7158fbf6 100644 --- a/setup/doctype/customer_group/customer_group.txt +++ b/setup/doctype/customer_group/customer_group.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:23", "docstatus": 0, - "modified": "2013-11-26 17:35:45", + "modified": "2013-12-20 19:24:01", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:customer_group_name", "doctype": "DocType", @@ -29,11 +30,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Customer Group", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 @@ -66,7 +69,7 @@ "doctype": "DocField", "fieldname": "parent_customer_group", "fieldtype": "Link", - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "Parent Customer Group", "oldfieldname": "parent_customer_group", "oldfieldtype": "Link", @@ -128,7 +131,7 @@ "fieldname": "old_parent", "fieldtype": "Link", "hidden": 1, - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "old_parent", "no_copy": 1, "oldfieldname": "old_parent", diff --git a/setup/doctype/email_digest/email_digest.txt b/setup/doctype/email_digest/email_digest.txt index b04885a4c9..ca35916437 100644 --- a/setup/doctype/email_digest/email_digest.txt +++ b/setup/doctype/email_digest/email_digest.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-21 14:15:31", "docstatus": 0, - "modified": "2013-12-16 12:37:43", + "modified": "2013-12-20 19:24:05", "modified_by": "Administrator", "owner": "Administrator" }, @@ -351,7 +351,9 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "permlevel": 0, + "print": 1, "report": 1, "write": 1 }, diff --git a/setup/doctype/features_setup/features_setup.txt b/setup/doctype/features_setup/features_setup.txt index 3f73ee2e25..2f7b67773f 100644 --- a/setup/doctype/features_setup/features_setup.txt +++ b/setup/doctype/features_setup/features_setup.txt @@ -2,7 +2,7 @@ { "creation": "2012-12-20 12:50:49", "docstatus": 0, - "modified": "2013-11-03 14:20:18", + "modified": "2013-12-20 19:23:13", "modified_by": "Administrator", "owner": "Administrator" }, @@ -25,11 +25,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Features Setup", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 0, "submit": 0, diff --git a/setup/doctype/item_group/item_group.txt b/setup/doctype/item_group/item_group.txt index 5af9e27ff5..83e32b218b 100644 --- a/setup/doctype/item_group/item_group.txt +++ b/setup/doctype/item_group/item_group.txt @@ -2,12 +2,13 @@ { "creation": "2013-03-28 10:35:29", "docstatus": 0, - "modified": "2013-11-26 17:36:08", + "modified": "2013-12-20 19:24:10", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 1, + "allow_import": 1, "allow_rename": 1, "autoname": "field:item_group_name", "description": "Item Classification", @@ -31,11 +32,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Item Group", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -71,7 +74,7 @@ "doctype": "DocField", "fieldname": "parent_item_group", "fieldtype": "Link", - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "Parent Item Group", "no_copy": 0, "oldfieldname": "parent_item_group", @@ -167,7 +170,7 @@ "fieldname": "old_parent", "fieldtype": "Link", "hidden": 1, - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "old_parent", "no_copy": 1, "oldfieldname": "old_parent", diff --git a/setup/doctype/jobs_email_settings/jobs_email_settings.txt b/setup/doctype/jobs_email_settings/jobs_email_settings.txt index 769fc27cfe..24a424054c 100644 --- a/setup/doctype/jobs_email_settings/jobs_email_settings.txt +++ b/setup/doctype/jobs_email_settings/jobs_email_settings.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-15 16:50:01", "docstatus": 0, - "modified": "2013-07-05 14:43:39", + "modified": "2013-12-20 19:23:16", "modified_by": "Administrator", "owner": "Administrator" }, @@ -25,11 +25,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Jobs Email Settings", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "System Manager", "write": 1 diff --git a/setup/doctype/naming_series/naming_series.txt b/setup/doctype/naming_series/naming_series.txt index 28d4765cb4..dd28eac340 100644 --- a/setup/doctype/naming_series/naming_series.txt +++ b/setup/doctype/naming_series/naming_series.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-25 11:35:08", "docstatus": 0, - "modified": "2013-07-05 14:46:46", + "modified": "2013-12-20 19:23:21", "modified_by": "Administrator", "owner": "Administrator" }, @@ -28,11 +28,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Naming Series", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 0, "role": "System Manager", diff --git a/setup/doctype/print_heading/print_heading.txt b/setup/doctype/print_heading/print_heading.txt index d6cbe95d63..861e5479ab 100644 --- a/setup/doctype/print_heading/print_heading.txt +++ b/setup/doctype/print_heading/print_heading.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-07-05 14:50:55", + "modified": "2013-12-20 19:24:16", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:print_heading", "doctype": "DocType", "document_type": "Master", @@ -27,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Print Heading", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "All", diff --git a/setup/doctype/quotation_lost_reason/quotation_lost_reason.txt b/setup/doctype/quotation_lost_reason/quotation_lost_reason.txt index d9174e359c..6fccf61dfb 100644 --- a/setup/doctype/quotation_lost_reason/quotation_lost_reason.txt +++ b/setup/doctype/quotation_lost_reason/quotation_lost_reason.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-07-22 15:29:22", + "modified": "2013-12-20 19:24:26", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:order_lost_reason", "doctype": "DocType", "document_type": "Master", @@ -27,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Quotation Lost Reason", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Sales Master Manager", diff --git a/setup/doctype/sales_email_settings/sales_email_settings.txt b/setup/doctype/sales_email_settings/sales_email_settings.txt index 17578128fb..f5f8a97fa1 100644 --- a/setup/doctype/sales_email_settings/sales_email_settings.txt +++ b/setup/doctype/sales_email_settings/sales_email_settings.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-16 10:25:26", "docstatus": 0, - "modified": "2013-07-05 14:54:14", + "modified": "2013-12-20 19:21:38", "modified_by": "Administrator", "owner": "Administrator" }, @@ -25,11 +25,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Sales Email Settings", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "System Manager", "write": 1 diff --git a/setup/doctype/sales_partner/sales_partner.txt b/setup/doctype/sales_partner/sales_partner.txt index 7d0750ffcd..6ab274cc77 100644 --- a/setup/doctype/sales_partner/sales_partner.txt +++ b/setup/doctype/sales_partner/sales_partner.txt @@ -2,11 +2,12 @@ { "creation": "2013-04-12 15:34:06", "docstatus": 0, - "modified": "2013-11-02 16:59:04", + "modified": "2013-12-20 19:24:34", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:partner_name", "description": "A third party distributor / dealer / commission agent / affiliate / reseller who sells the companies products for a commission.", "doctype": "DocType", @@ -28,11 +29,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Sales Partner", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/setup/doctype/sales_person/sales_person.txt b/setup/doctype/sales_person/sales_person.txt index 8f08626f3a..76d9811122 100644 --- a/setup/doctype/sales_person/sales_person.txt +++ b/setup/doctype/sales_person/sales_person.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-11-26 17:35:29", + "modified": "2013-12-20 19:24:34", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:sales_person_name", "description": "All Sales Transactions can be tagged against multiple **Sales Persons** so that you can set and monitor targets.", @@ -29,11 +30,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Sales Person", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 @@ -65,7 +68,7 @@ "doctype": "DocField", "fieldname": "parent_sales_person", "fieldtype": "Link", - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "Parent Sales Person", "oldfieldname": "parent_sales_person", "oldfieldtype": "Link", diff --git a/setup/doctype/sms_parameter/sms_parameter.txt b/setup/doctype/sms_parameter/sms_parameter.txt index 38cca31d77..c4ebb8f84f 100755 --- a/setup/doctype/sms_parameter/sms_parameter.txt +++ b/setup/doctype/sms_parameter/sms_parameter.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:58", "docstatus": 0, - "modified": "2013-07-10 14:54:23", + "modified": "2013-12-20 19:21:47", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/setup/doctype/supplier_type/supplier_type.txt b/setup/doctype/supplier_type/supplier_type.txt index 200dc8115e..c7c2b57f62 100644 --- a/setup/doctype/supplier_type/supplier_type.txt +++ b/setup/doctype/supplier_type/supplier_type.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-07-05 14:57:16", + "modified": "2013-12-20 19:24:38", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:supplier_type", "doctype": "DocType", @@ -26,11 +27,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Supplier Type", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/setup/doctype/target_detail/target_detail.txt b/setup/doctype/target_detail/target_detail.txt index 71debd37b0..3ae395fc22 100644 --- a/setup/doctype/target_detail/target_detail.txt +++ b/setup/doctype/target_detail/target_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:27:58", "docstatus": 0, - "modified": "2013-11-02 19:41:37", + "modified": "2013-12-20 19:21:51", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/setup/doctype/terms_and_conditions/terms_and_conditions.txt b/setup/doctype/terms_and_conditions/terms_and_conditions.txt index 0ddc8f5d5d..e3ff486ea9 100644 --- a/setup/doctype/terms_and_conditions/terms_and_conditions.txt +++ b/setup/doctype/terms_and_conditions/terms_and_conditions.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-07-05 14:58:02", + "modified": "2013-12-20 19:24:39", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:title", "description": "Standard Terms and Conditions that can be added to Sales and Purchases.\n\nExamples:\n\n1. Validity of the offer.\n1. Payment Terms (In Advance, On Credit, part advance etc).\n1. What is extra (or payable by the Customer).\n1. Safety / usage warning.\n1. Warranty if any.\n1. Returns Policy.\n1. Terms of shipping, if applicable.\n1. Ways of addressing disputes, indemnity, liability, etc.\n1. Address and Contact of your Company.", @@ -26,11 +27,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Terms and Conditions", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/setup/doctype/territory/territory.txt b/setup/doctype/territory/territory.txt index b764db5820..00b7aac422 100644 --- a/setup/doctype/territory/territory.txt +++ b/setup/doctype/territory/territory.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-11-26 17:36:23", + "modified": "2013-12-20 19:24:39", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "autoname": "field:territory_name", "description": "Classification of Customers by region", @@ -31,11 +32,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Territory", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 @@ -68,7 +71,7 @@ "doctype": "DocField", "fieldname": "parent_territory", "fieldtype": "Link", - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "Parent Territory", "oldfieldname": "parent_territory", "oldfieldtype": "Link", @@ -137,7 +140,7 @@ "fieldname": "old_parent", "fieldtype": "Link", "hidden": 1, - "ignore_restriction": 1, + "ignore_restrictions": 1, "label": "old_parent", "no_copy": 1, "oldfieldname": "old_parent", diff --git a/setup/doctype/uom/uom.txt b/setup/doctype/uom/uom.txt index 51d9806755..070c5a4148 100644 --- a/setup/doctype/uom/uom.txt +++ b/setup/doctype/uom/uom.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:24", "docstatus": 0, - "modified": "2013-10-10 15:06:53", + "modified": "2013-12-20 19:24:40", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "field:uom_name", "doctype": "DocType", "document_type": "Master", @@ -25,11 +26,13 @@ { "amend": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "UOM", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/setup/doctype/website_item_group/website_item_group.txt b/setup/doctype/website_item_group/website_item_group.txt index 0a8a3aacc9..a2a6e7e78f 100644 --- a/setup/doctype/website_item_group/website_item_group.txt +++ b/setup/doctype/website_item_group/website_item_group.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:09", "docstatus": 0, - "modified": "2013-11-02 19:41:38", + "modified": "2013-12-20 19:21:54", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/batch/batch.txt b/stock/doctype/batch/batch.txt index 5b7a8409ab..17145fffa7 100644 --- a/stock/doctype/batch/batch.txt +++ b/stock/doctype/batch/batch.txt @@ -2,12 +2,13 @@ { "creation": "2013-03-05 14:50:38", "docstatus": 0, - "modified": "2013-07-05 14:26:48", + "modified": "2013-12-20 19:23:55", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, { "allow_attach": 1, + "allow_import": 1, "autoname": "field:batch_id", "doctype": "DocType", "document_type": "Master", @@ -28,11 +29,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Batch", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Material Master Manager", diff --git a/stock/doctype/bin/bin.txt b/stock/doctype/bin/bin.txt index a66b5e8eb1..2775191070 100644 --- a/stock/doctype/bin/bin.txt +++ b/stock/doctype/bin/bin.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:25", "docstatus": 0, - "modified": "2013-08-07 14:45:48", + "modified": "2013-12-20 19:23:56", "modified_by": "Administrator", "owner": "Administrator" }, @@ -27,11 +27,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Bin", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/stock/doctype/delivery_note/delivery_note.txt b/stock/doctype/delivery_note/delivery_note.txt index 480d45d014..36615a28d0 100644 --- a/stock/doctype/delivery_note/delivery_note.txt +++ b/stock/doctype/delivery_note/delivery_note.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-24 19:29:09", "docstatus": 0, - "modified": "2013-12-14 17:26:12", + "modified": "2013-12-20 19:24:02", "modified_by": "Administrator", "owner": "Administrator" }, @@ -30,11 +30,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Delivery Note", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -167,6 +169,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -1058,7 +1061,6 @@ }, { "doctype": "DocPerm", - "match": "customer", "role": "Customer" } ] \ No newline at end of file diff --git a/stock/doctype/delivery_note_item/delivery_note_item.txt b/stock/doctype/delivery_note_item/delivery_note_item.txt index a118715cd3..96c01f6001 100644 --- a/stock/doctype/delivery_note_item/delivery_note_item.txt +++ b/stock/doctype/delivery_note_item/delivery_note_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-22 13:15:44", "docstatus": 0, - "modified": "2013-11-02 19:41:38", + "modified": "2013-12-20 19:23:08", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/item/item.txt b/stock/doctype/item/item.txt index 22c5dcc7cf..cc12fdaebf 100644 --- a/stock/doctype/item/item.txt +++ b/stock/doctype/item/item.txt @@ -2,12 +2,13 @@ { "creation": "2013-05-03 10:45:46", "docstatus": 0, - "modified": "2013-11-02 19:41:40", + "modified": "2013-12-20 19:24:09", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 1, + "allow_import": 1, "allow_rename": 1, "autoname": "field:item_code", "default_print_format": "Standard", @@ -30,11 +31,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Item", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 @@ -847,6 +850,7 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "import": 1, "role": "Material Master Manager", "write": 1 }, diff --git a/stock/doctype/item_customer_detail/item_customer_detail.txt b/stock/doctype/item_customer_detail/item_customer_detail.txt index def1dff230..9d9b6ca078 100644 --- a/stock/doctype/item_customer_detail/item_customer_detail.txt +++ b/stock/doctype/item_customer_detail/item_customer_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-08 15:37:16", "docstatus": 0, - "modified": "2013-07-10 14:54:09", + "modified": "2013-12-20 19:23:16", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/item_price/item_price.txt b/stock/doctype/item_price/item_price.txt index fc411eb1d6..c21f127b7a 100644 --- a/stock/doctype/item_price/item_price.txt +++ b/stock/doctype/item_price/item_price.txt @@ -2,11 +2,12 @@ { "creation": "2013-05-02 16:29:48", "docstatus": 0, - "modified": "2013-10-31 12:59:02", + "modified": "2013-12-20 19:24:10", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "autoname": "RFD/.#####", "description": "Multiple Item prices.", "doctype": "DocType", @@ -30,11 +31,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Item Price", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "write": 1 diff --git a/stock/doctype/item_quality_inspection_parameter/item_quality_inspection_parameter.txt b/stock/doctype/item_quality_inspection_parameter/item_quality_inspection_parameter.txt index df8c817de1..8ec87d7cc1 100644 --- a/stock/doctype/item_quality_inspection_parameter/item_quality_inspection_parameter.txt +++ b/stock/doctype/item_quality_inspection_parameter/item_quality_inspection_parameter.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:01", "docstatus": 0, - "modified": "2013-07-10 14:54:09", + "modified": "2013-12-20 19:23:16", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/item_reorder/item_reorder.txt b/stock/doctype/item_reorder/item_reorder.txt index ae9de1e724..74df09a0ae 100644 --- a/stock/doctype/item_reorder/item_reorder.txt +++ b/stock/doctype/item_reorder/item_reorder.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 11:42:59", "docstatus": 0, - "modified": "2013-07-10 14:54:09", + "modified": "2013-12-20 19:23:16", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/item_supplier/item_supplier.txt b/stock/doctype/item_supplier/item_supplier.txt index e0e0e6d0a4..02e0bd7cac 100644 --- a/stock/doctype/item_supplier/item_supplier.txt +++ b/stock/doctype/item_supplier/item_supplier.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:01", "docstatus": 0, - "modified": "2013-07-10 14:54:09", + "modified": "2013-12-20 19:23:16", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/item_tax/item_tax.txt b/stock/doctype/item_tax/item_tax.txt index cbc112e1f0..243ee1f31b 100644 --- a/stock/doctype/item_tax/item_tax.txt +++ b/stock/doctype/item_tax/item_tax.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:01", "docstatus": 0, - "modified": "2013-07-10 14:54:09", + "modified": "2013-12-20 19:23:16", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/item_website_specification/item_website_specification.txt b/stock/doctype/item_website_specification/item_website_specification.txt index c3c1d34751..164da81ca7 100644 --- a/stock/doctype/item_website_specification/item_website_specification.txt +++ b/stock/doctype/item_website_specification/item_website_specification.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:01", "docstatus": 0, - "modified": "2013-07-10 14:54:10", + "modified": "2013-12-20 19:23:16", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/landed_cost_item/landed_cost_item.txt b/stock/doctype/landed_cost_item/landed_cost_item.txt index bfd6216dfe..bf8af3a37b 100644 --- a/stock/doctype/landed_cost_item/landed_cost_item.txt +++ b/stock/doctype/landed_cost_item/landed_cost_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:02", "docstatus": 0, - "modified": "2013-09-02 17:36:19", + "modified": "2013-12-20 19:23:18", "modified_by": "Administrator", "owner": "wasim@webnotestech.com" }, diff --git a/stock/doctype/landed_cost_purchase_receipt/landed_cost_purchase_receipt.txt b/stock/doctype/landed_cost_purchase_receipt/landed_cost_purchase_receipt.txt index 5f0bc9079f..8d02e3a10c 100644 --- a/stock/doctype/landed_cost_purchase_receipt/landed_cost_purchase_receipt.txt +++ b/stock/doctype/landed_cost_purchase_receipt/landed_cost_purchase_receipt.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:02", "docstatus": 0, - "modified": "2013-09-02 13:44:28", + "modified": "2013-12-20 19:23:18", "modified_by": "Administrator", "owner": "wasim@webnotestech.com" }, diff --git a/stock/doctype/landed_cost_wizard/landed_cost_wizard.txt b/stock/doctype/landed_cost_wizard/landed_cost_wizard.txt index 40f2e23c90..587d0e313c 100644 --- a/stock/doctype/landed_cost_wizard/landed_cost_wizard.txt +++ b/stock/doctype/landed_cost_wizard/landed_cost_wizard.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-22 16:50:39", "docstatus": 0, - "modified": "2013-09-02 19:13:09", + "modified": "2013-12-20 19:23:18", "modified_by": "Administrator", "owner": "wasim@webnotestech.com" }, @@ -24,11 +24,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Landed Cost Wizard", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 0, "submit": 0, diff --git a/stock/doctype/material_request/material_request.txt b/stock/doctype/material_request/material_request.txt index c71d7d15c0..8762c03edd 100644 --- a/stock/doctype/material_request/material_request.txt +++ b/stock/doctype/material_request/material_request.txt @@ -2,14 +2,13 @@ { "creation": "2013-03-07 14:48:38", "docstatus": 0, - "modified": "2013-11-03 15:30:49", + "modified": "2013-12-20 19:24:14", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 1, "allow_import": 1, - "allow_print": 0, "autoname": "naming_series:", "doctype": "DocType", "icon": "icon-ticket", @@ -32,11 +31,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Material Request", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -83,6 +84,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/stock/doctype/material_request_item/material_request_item.txt b/stock/doctype/material_request_item/material_request_item.txt index e0b9330baa..6e8a0d6f98 100644 --- a/stock/doctype/material_request_item/material_request_item.txt +++ b/stock/doctype/material_request_item/material_request_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:02", "docstatus": 0, - "modified": "2013-12-18 14:52:02", + "modified": "2013-12-20 19:23:21", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/packed_item/packed_item.txt b/stock/doctype/packed_item/packed_item.txt index 8320502cf7..45a1d4d9b2 100644 --- a/stock/doctype/packed_item/packed_item.txt +++ b/stock/doctype/packed_item/packed_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:00", "docstatus": 0, - "modified": "2013-10-16 16:37:31", + "modified": "2013-12-20 19:23:23", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/packing_slip/packing_slip.txt b/stock/doctype/packing_slip/packing_slip.txt index c86e90faa3..065a056ef5 100644 --- a/stock/doctype/packing_slip/packing_slip.txt +++ b/stock/doctype/packing_slip/packing_slip.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-11 15:32:24", "docstatus": 0, - "modified": "2013-11-02 14:05:59", + "modified": "2013-12-20 19:24:15", "modified_by": "Administrator", "owner": "Administrator" }, @@ -31,11 +31,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Packing Slip", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -205,6 +207,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "options": "Packing Slip", diff --git a/stock/doctype/packing_slip_item/packing_slip_item.txt b/stock/doctype/packing_slip_item/packing_slip_item.txt index 41dd044c7c..54e69914d0 100644 --- a/stock/doctype/packing_slip_item/packing_slip_item.txt +++ b/stock/doctype/packing_slip_item/packing_slip_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-04-08 13:10:16", "docstatus": 0, - "modified": "2013-07-25 16:37:30", + "modified": "2013-12-20 19:23:23", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/price_list/price_list.txt b/stock/doctype/price_list/price_list.txt index d43076bcc8..dabc7e0dc9 100644 --- a/stock/doctype/price_list/price_list.txt +++ b/stock/doctype/price_list/price_list.txt @@ -2,15 +2,14 @@ { "creation": "2013-01-25 11:35:09", "docstatus": 0, - "modified": "2013-10-31 19:24:33", + "modified": "2013-12-20 18:28:50", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 0, "allow_copy": 0, - "allow_email": 1, - "allow_print": 1, + "allow_import": 1, "autoname": "field:price_list_name", "description": "Price List Master", "doctype": "DocType", diff --git a/stock/doctype/purchase_receipt/purchase_receipt.txt b/stock/doctype/purchase_receipt/purchase_receipt.txt index 95e254ef2f..fca3e39007 100755 --- a/stock/doctype/purchase_receipt/purchase_receipt.txt +++ b/stock/doctype/purchase_receipt/purchase_receipt.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-21 16:16:39", "docstatus": 0, - "modified": "2013-11-22 17:15:47", + "modified": "2013-12-20 19:24:23", "modified_by": "Administrator", "owner": "Administrator" }, @@ -28,11 +28,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Purchase Receipt", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -581,6 +583,7 @@ "fieldname": "amended_from", "fieldtype": "Data", "hidden": 1, + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", @@ -831,7 +834,6 @@ }, { "doctype": "DocPerm", - "match": "supplier", "role": "Supplier" } ] \ No newline at end of file diff --git a/stock/doctype/purchase_receipt_item/purchase_receipt_item.txt b/stock/doctype/purchase_receipt_item/purchase_receipt_item.txt index 9a641c2ba3..4f5004021c 100755 --- a/stock/doctype/purchase_receipt_item/purchase_receipt_item.txt +++ b/stock/doctype/purchase_receipt_item/purchase_receipt_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-24 19:29:10", "docstatus": 0, - "modified": "2013-12-18 10:38:39", + "modified": "2013-12-20 19:23:36", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/serial_no/serial_no.txt b/stock/doctype/serial_no/serial_no.txt index b29a1a8ea2..09995704fa 100644 --- a/stock/doctype/serial_no/serial_no.txt +++ b/stock/doctype/serial_no/serial_no.txt @@ -2,12 +2,13 @@ { "creation": "2013-05-16 10:59:15", "docstatus": 0, - "modified": "2013-11-02 19:41:52", + "modified": "2013-12-20 19:24:34", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 1, + "allow_import": 1, "allow_rename": 1, "autoname": "field:serial_no", "description": "Distinct unit of an Item", @@ -29,11 +30,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Serial No", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0 diff --git a/stock/doctype/stock_entry/stock_entry.txt b/stock/doctype/stock_entry/stock_entry.txt index 18a07a3550..84023ab2be 100644 --- a/stock/doctype/stock_entry/stock_entry.txt +++ b/stock/doctype/stock_entry/stock_entry.txt @@ -2,15 +2,13 @@ { "creation": "2013-04-09 11:43:55", "docstatus": 0, - "modified": "2013-12-09 16:24:10", + "modified": "2013-12-20 19:24:35", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 0, "allow_copy": 0, - "allow_email": 0, - "allow_print": 0, "allow_rename": 0, "autoname": "naming_series:", "doctype": "DocType", @@ -41,11 +39,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Stock Entry", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 1, @@ -587,6 +587,7 @@ "fieldname": "amended_from", "fieldtype": "Link", "hidden": 0, + "ignore_restrictions": 1, "in_filter": 0, "label": "Amended From", "no_copy": 1, diff --git a/stock/doctype/stock_entry_detail/stock_entry_detail.txt b/stock/doctype/stock_entry_detail/stock_entry_detail.txt index b97928b961..88c08a77b0 100644 --- a/stock/doctype/stock_entry_detail/stock_entry_detail.txt +++ b/stock/doctype/stock_entry_detail/stock_entry_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-29 18:22:12", "docstatus": 0, - "modified": "2013-11-08 16:15:44", + "modified": "2013-12-20 19:21:48", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/stock_reconciliation/stock_reconciliation.txt b/stock/doctype/stock_reconciliation/stock_reconciliation.txt index c9959d36e3..f95a1dddba 100644 --- a/stock/doctype/stock_reconciliation/stock_reconciliation.txt +++ b/stock/doctype/stock_reconciliation/stock_reconciliation.txt @@ -2,15 +2,13 @@ { "creation": "2013-03-28 10:35:31", "docstatus": 0, - "modified": "2013-09-24 15:35:12", + "modified": "2013-12-20 16:06:50", "modified_by": "Administrator", "owner": "Administrator" }, { "allow_attach": 0, "allow_copy": 1, - "allow_email": 1, - "allow_print": 1, "autoname": "SR/.######", "description": "This tool helps you to update or fix the quantity and valuation of stock in the system. It is typically used to synchronise the system values and what actually exists in your warehouses.", "doctype": "DocType", @@ -78,6 +76,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Link", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "options": "Stock Reconciliation", diff --git a/stock/doctype/stock_settings/stock_settings.txt b/stock/doctype/stock_settings/stock_settings.txt index 634ee3a60f..de8c864ebb 100644 --- a/stock/doctype/stock_settings/stock_settings.txt +++ b/stock/doctype/stock_settings/stock_settings.txt @@ -2,7 +2,7 @@ { "creation": "2013-06-24 16:37:54", "docstatus": 0, - "modified": "2013-11-02 19:41:56", + "modified": "2013-12-20 19:21:48", "modified_by": "Administrator", "owner": "Administrator" }, @@ -25,11 +25,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Stock Settings", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "Material Manager", "write": 1 diff --git a/stock/doctype/stock_uom_replace_utility/stock_uom_replace_utility.txt b/stock/doctype/stock_uom_replace_utility/stock_uom_replace_utility.txt index 6862a86ef5..a4f368efc2 100644 --- a/stock/doctype/stock_uom_replace_utility/stock_uom_replace_utility.txt +++ b/stock/doctype/stock_uom_replace_utility/stock_uom_replace_utility.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:30", "docstatus": 0, - "modified": "2013-07-25 17:39:14", + "modified": "2013-12-20 19:21:48", "modified_by": "Administrator", "owner": "Administrator" }, @@ -26,11 +26,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Stock UOM Replace Utility", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 0, "submit": 0, diff --git a/stock/doctype/uom_conversion_detail/uom_conversion_detail.txt b/stock/doctype/uom_conversion_detail/uom_conversion_detail.txt index d775513cd4..0843921150 100644 --- a/stock/doctype/uom_conversion_detail/uom_conversion_detail.txt +++ b/stock/doctype/uom_conversion_detail/uom_conversion_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:04", "docstatus": 0, - "modified": "2013-07-22 17:17:53", + "modified": "2013-12-20 19:21:53", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/stock/doctype/warehouse/warehouse.txt b/stock/doctype/warehouse/warehouse.txt index e194349947..627e9dd8f2 100644 --- a/stock/doctype/warehouse/warehouse.txt +++ b/stock/doctype/warehouse/warehouse.txt @@ -2,11 +2,12 @@ { "creation": "2013-03-07 18:50:32", "docstatus": 0, - "modified": "2013-11-19 12:12:33", + "modified": "2013-12-20 19:24:40", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "description": "A logical Warehouse against which stock entries are made.", "doctype": "DocType", @@ -25,11 +26,13 @@ }, { "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Warehouse", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1 }, @@ -75,15 +78,13 @@ "fieldname": "create_account_under", "fieldtype": "Link", "label": "Parent Account", - "options": "Account", - "permlevel": 0 + "options": "Account" }, { "doctype": "DocField", "fieldname": "column_break_4", "fieldtype": "Section Break", "label": "Allow For Users", - "permlevel": 0, "read_only": 0 }, { diff --git a/stock/doctype/warehouse_user/warehouse_user.txt b/stock/doctype/warehouse_user/warehouse_user.txt index fee6221727..c28a37f5f0 100644 --- a/stock/doctype/warehouse_user/warehouse_user.txt +++ b/stock/doctype/warehouse_user/warehouse_user.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:05", "docstatus": 0, - "modified": "2013-07-10 14:54:25", + "modified": "2013-12-20 19:21:54", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/support/doctype/customer_issue/customer_issue.txt b/support/doctype/customer_issue/customer_issue.txt index c677654ccc..ae16c2ccf7 100644 --- a/support/doctype/customer_issue/customer_issue.txt +++ b/support/doctype/customer_issue/customer_issue.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:30", "docstatus": 0, - "modified": "2013-12-11 11:14:32", + "modified": "2013-12-20 19:24:02", "modified_by": "Administrator", "owner": "harshada@webnotestech.com" }, @@ -28,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Customer Issue", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Maintenance User", @@ -410,6 +412,7 @@ "fieldname": "amended_from", "fieldtype": "Data", "hidden": 1, + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/support/doctype/maintenance_schedule/maintenance_schedule.txt b/support/doctype/maintenance_schedule/maintenance_schedule.txt index bdf14a18f7..ff97b957bf 100644 --- a/support/doctype/maintenance_schedule/maintenance_schedule.txt +++ b/support/doctype/maintenance_schedule/maintenance_schedule.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:30", "docstatus": 0, - "modified": "2013-11-02 16:59:23", + "modified": "2013-12-20 19:24:13", "modified_by": "Administrator", "owner": "Administrator" }, @@ -28,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Maintenance Schedule", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Maintenance Manager", @@ -169,6 +171,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/support/doctype/maintenance_schedule_detail/maintenance_schedule_detail.txt b/support/doctype/maintenance_schedule_detail/maintenance_schedule_detail.txt index e55a69c8d5..8b52d8b671 100644 --- a/support/doctype/maintenance_schedule_detail/maintenance_schedule_detail.txt +++ b/support/doctype/maintenance_schedule_detail/maintenance_schedule_detail.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:05", "docstatus": 0, - "modified": "2013-07-10 14:54:10", + "modified": "2013-12-20 19:23:20", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/support/doctype/maintenance_schedule_item/maintenance_schedule_item.txt b/support/doctype/maintenance_schedule_item/maintenance_schedule_item.txt index 648a328913..f42b48bf55 100644 --- a/support/doctype/maintenance_schedule_item/maintenance_schedule_item.txt +++ b/support/doctype/maintenance_schedule_item/maintenance_schedule_item.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:05", "docstatus": 0, - "modified": "2013-07-10 14:54:10", + "modified": "2013-12-20 19:23:20", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/support/doctype/maintenance_visit/maintenance_visit.txt b/support/doctype/maintenance_visit/maintenance_visit.txt index f68a1f4ffa..2b2986edc2 100644 --- a/support/doctype/maintenance_visit/maintenance_visit.txt +++ b/support/doctype/maintenance_visit/maintenance_visit.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:31", "docstatus": 0, - "modified": "2013-11-02 16:59:24", + "modified": "2013-12-20 19:24:13", "modified_by": "Administrator", "owner": "ashwini@webnotestech.com" }, @@ -28,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Maintenance Visit", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "Maintenance User", @@ -230,6 +232,7 @@ "doctype": "DocField", "fieldname": "amended_from", "fieldtype": "Data", + "ignore_restrictions": 1, "label": "Amended From", "no_copy": 1, "oldfieldname": "amended_from", diff --git a/support/doctype/maintenance_visit_purpose/maintenance_visit_purpose.txt b/support/doctype/maintenance_visit_purpose/maintenance_visit_purpose.txt index 53fa0a2e19..6a45e55c4e 100644 --- a/support/doctype/maintenance_visit_purpose/maintenance_visit_purpose.txt +++ b/support/doctype/maintenance_visit_purpose/maintenance_visit_purpose.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-22 01:28:06", "docstatus": 0, - "modified": "2013-07-10 14:54:10", + "modified": "2013-12-20 19:23:20", "modified_by": "Administrator", "owner": "ashwini@webnotestech.com" }, diff --git a/support/doctype/newsletter/newsletter.txt b/support/doctype/newsletter/newsletter.txt index 123eeedeff..9482ed712e 100644 --- a/support/doctype/newsletter/newsletter.txt +++ b/support/doctype/newsletter/newsletter.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:31", "docstatus": 0, - "modified": "2013-11-02 14:06:04", + "modified": "2013-12-20 19:24:14", "modified_by": "Administrator", "owner": "Administrator" }, @@ -24,18 +24,20 @@ "permlevel": 0 }, { - "cancel": 1, - "create": 1, + "cancel": 0, + "create": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Newsletter", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, - "write": 1 + "write": 0 }, { "doctype": "DocType", diff --git a/support/doctype/support_ticket/support_ticket.txt b/support/doctype/support_ticket/support_ticket.txt index 4fa4874a9c..59093f772f 100644 --- a/support/doctype/support_ticket/support_ticket.txt +++ b/support/doctype/support_ticket/support_ticket.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-01 10:36:25", "docstatus": 0, - "modified": "2013-12-14 17:27:02", + "modified": "2013-12-20 19:24:38", "modified_by": "Administrator", "owner": "Administrator" }, @@ -27,11 +27,13 @@ "amend": 0, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Support Ticket", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, @@ -278,7 +280,6 @@ { "cancel": 0, "doctype": "DocPerm", - "match": "customer", "role": "Customer" }, { diff --git a/utilities/doctype/address/address.txt b/utilities/doctype/address/address.txt index 5b4ada995e..669da2b1c0 100644 --- a/utilities/doctype/address/address.txt +++ b/utilities/doctype/address/address.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:32", "docstatus": 0, - "modified": "2013-12-12 12:17:46", + "modified": "2013-12-20 19:23:54", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "doctype": "DocType", "document_type": "Master", @@ -27,11 +28,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Address", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, diff --git a/utilities/doctype/contact/contact.txt b/utilities/doctype/contact/contact.txt index 1c8a5cf94a..65c22b32a0 100644 --- a/utilities/doctype/contact/contact.txt +++ b/utilities/doctype/contact/contact.txt @@ -2,11 +2,12 @@ { "creation": "2013-01-10 16:34:32", "docstatus": 0, - "modified": "2013-12-12 12:18:19", + "modified": "2013-12-20 19:23:59", "modified_by": "Administrator", "owner": "Administrator" }, { + "allow_import": 1, "allow_rename": 1, "doctype": "DocType", "document_type": "Master", @@ -27,11 +28,13 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Contact", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "submit": 0, diff --git a/utilities/doctype/note/note.txt b/utilities/doctype/note/note.txt index 5c6b7713bb..055619a550 100644 --- a/utilities/doctype/note/note.txt +++ b/utilities/doctype/note/note.txt @@ -2,12 +2,11 @@ { "creation": "2013-05-24 13:41:00", "docstatus": 0, - "modified": "2013-07-05 14:47:11", + "modified": "2013-12-20 19:24:14", "modified_by": "Administrator", "owner": "Administrator" }, { - "allow_print": 0, "allow_rename": 1, "description": "Note is a free page where users can share documents / notes", "doctype": "DocType", @@ -29,11 +28,13 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "Note", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "role": "All", "write": 1 diff --git a/utilities/doctype/note_user/note_user.txt b/utilities/doctype/note_user/note_user.txt index fcc1d1168f..86fdc44a9f 100644 --- a/utilities/doctype/note_user/note_user.txt +++ b/utilities/doctype/note_user/note_user.txt @@ -2,7 +2,7 @@ { "creation": "2013-05-24 14:24:48", "docstatus": 0, - "modified": "2013-07-10 14:54:11", + "modified": "2013-12-20 19:23:22", "modified_by": "Administrator", "owner": "Administrator" }, diff --git a/utilities/doctype/sms_control/sms_control.txt b/utilities/doctype/sms_control/sms_control.txt index bd63dab3d2..f8e0fae9dc 100644 --- a/utilities/doctype/sms_control/sms_control.txt +++ b/utilities/doctype/sms_control/sms_control.txt @@ -2,7 +2,7 @@ { "creation": "2013-01-10 16:34:32", "docstatus": 0, - "modified": "2013-07-05 14:55:40", + "modified": "2013-12-20 19:21:47", "modified_by": "Administrator", "owner": "Administrator" }, @@ -17,13 +17,17 @@ { "create": 1, "doctype": "DocPerm", + "email": 1, + "export": 0, + "import": 0, "name": "__common__", "parent": "SMS Control", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, - "report": 1, + "report": 0, "role": "System Manager", "submit": 0, "write": 1 diff --git a/utilities/doctype/sms_log/sms_log.txt b/utilities/doctype/sms_log/sms_log.txt index 094adfd660..43cb1ffbcd 100644 --- a/utilities/doctype/sms_log/sms_log.txt +++ b/utilities/doctype/sms_log/sms_log.txt @@ -2,7 +2,7 @@ { "creation": "2012-03-27 14:36:47", "docstatus": 0, - "modified": "2013-07-05 14:55:45", + "modified": "2013-12-20 19:24:35", "modified_by": "Administrator", "owner": "Administrator" }, @@ -24,11 +24,13 @@ { "create": 0, "doctype": "DocPerm", + "email": 1, "name": "__common__", "parent": "SMS Log", "parentfield": "permissions", "parenttype": "DocType", "permlevel": 0, + "print": 1, "read": 1, "report": 1, "role": "System Manager", From 9b67f4344bf05902cfc17548970ec314c82e6411 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Fri, 20 Dec 2013 19:33:11 +0530 Subject: [PATCH 11/12] Patch to migrate allow_print and allow_email to print and email rights of DocPerm --- patches/1312/p02_update_user_properties.py | 3 +-- patches/1312/p04_new_permissions.py | 13 ++++++++++++- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/patches/1312/p02_update_user_properties.py b/patches/1312/p02_update_user_properties.py index 51da19f1ba..4ac1ab9615 100644 --- a/patches/1312/p02_update_user_properties.py +++ b/patches/1312/p02_update_user_properties.py @@ -33,10 +33,9 @@ def update_user_match(): doctype_matches.setdefault(doctype, []).append(match) for doctype, user_matches in doctype_matches.items(): - # get permissions of this doctype perms = webnotes.conn.sql("""select role, `match` from `tabDocPerm` - where parent=%s and permlevel=0 and read=1""", doctype, as_dict=True) + where parent=%s and permlevel=0 and `read`=1""", doctype, as_dict=True) # for each user with roles of this doctype, check if match condition applies for profile in webnotes.conn.sql_list("""select name from `tabProfile` diff --git a/patches/1312/p04_new_permissions.py b/patches/1312/p04_new_permissions.py index 301c15e7f0..e6042f4db5 100644 --- a/patches/1312/p04_new_permissions.py +++ b/patches/1312/p04_new_permissions.py @@ -8,6 +8,17 @@ def execute(): # reset Page perms from core.page.permission_manager.permission_manager import reset reset("Page") + reset("Report") # patch to move print, email into DocPerm - \ No newline at end of file + for doctype, hide_print, hide_email in webnotes.conn.sql("""select name, ifnull(allow_print, 0), ifnull(allow_email, 0) + from `tabDocType` where ifnull(issingle, 0)=0 and ifnull(istable, 0)=0 and + (ifnull(allow_print, 0)=0 or ifnull(allow_email, 0)=0)"""): + + if not hide_print: + webnotes.conn.sql("""update `tabDocPerm` set `print`=1 + where permlevel=0 and `read`=1 and parent=%s""", doctype) + + if not hide_email: + webnotes.conn.sql("""update `tabDocPerm` set `email`=1 + where permlevel=0 and `read`=1 and parent=%s""", doctype) From 2926651e1ca7d324f5a9e0b72b28b5e9e3137130 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Mon, 23 Dec 2013 19:59:29 +0530 Subject: [PATCH 12/12] Restrict Employee and Leave Approver to relevant Employee and Leave Application records --- hr/doctype/employee/employee.py | 53 ++++++++------- hr/doctype/employee/employee.txt | 4 +- .../leave_application/leave_application.txt | 3 +- patches/1312/p02_update_user_properties.py | 67 +++++++++++++------ 4 files changed, 78 insertions(+), 49 deletions(-) diff --git a/hr/doctype/employee/employee.py b/hr/doctype/employee/employee.py index 46f46da80f..6684951a93 100644 --- a/hr/doctype/employee/employee.py +++ b/hr/doctype/employee/employee.py @@ -7,13 +7,11 @@ import webnotes from webnotes.utils import getdate, validate_email_add, cstr, cint from webnotes.model.doc import make_autoname from webnotes import msgprint, _ +import webnotes.permissions +from webnotes.defaults import get_restrictions +from webnotes.model.controller import DocListController - -class DocType: - def __init__(self,doc,doclist=[]): - self.doc = doc - self.doclist = doclist - +class DocType(DocListController): def autoname(self): naming_method = webnotes.conn.get_value("HR Settings", None, "emp_created_by") if not naming_method: @@ -39,33 +37,36 @@ class DocType: def on_update(self): if self.doc.user_id: + self.restrict_user() self.update_user_default() self.update_profile() + + self.restrict_leave_approver() - def update_user_default(self): - from webnotes.defaults import get_restrictions - if not "HR User" in webnotes.local.user.get_roles(): - if not self.doc.user_id in get_restrictions().get("Employee", []): - webnotes.conn.set_default("Employee", self.doc.name, self.doc.user_id, "Restriction") + def restrict_user(self): + """restrict to this employee for user""" + self.add_restriction_if_required("Employee", self.doc.user_id) - webnotes.conn.set_default("employee", self.doc.name, self.doc.user_id) + def update_user_default(self): webnotes.conn.set_default("employee_name", self.doc.employee_name, self.doc.user_id) webnotes.conn.set_default("company", self.doc.company, self.doc.user_id) - self.set_default_leave_approver() - def set_default_leave_approver(self): - employee_leave_approvers = self.doclist.get({"parentfield": "employee_leave_approvers"}) - - if len(employee_leave_approvers): - webnotes.conn.set_default("leave_approver", employee_leave_approvers[0].leave_approver, - self.doc.user_id) - - elif self.doc.reports_to: - from webnotes.profile import Profile - reports_to_user = webnotes.conn.get_value("Employee", self.doc.reports_to, "user_id") - if "Leave Approver" in Profile(reports_to_user).get_roles(): - webnotes.conn.set_default("leave_approver", reports_to_user, self.doc.user_id) - + def restrict_leave_approver(self): + """restrict to this employee for leave approver""" + employee_leave_approvers = [d.leave_approver for d in self.doclist.get({"parentfield": "employee_leave_approvers"})] + if self.doc.reports_to and self.doc.reports_to not in employee_leave_approvers: + employee_leave_approvers.append(webnotes.conn.get_value("Employee", self.doc.reports_to, "user_id")) + + for user in employee_leave_approvers: + self.add_restriction_if_required("Employee", user) + self.add_restriction_if_required("Leave Application", user) + + def add_restriction_if_required(self, doctype, user): + if webnotes.permissions.has_only_non_restrict_role(webnotes.get_doctype(doctype), user) \ + and self.doc.name not in get_restrictions(user).get("Employee", []): + + webnotes.defaults.add_default("Employee", self.doc.name, user, "Restriction") + def update_profile(self): # add employee role if missing if not "Employee" in webnotes.conn.sql_list("""select role from tabUserRole diff --git a/hr/doctype/employee/employee.txt b/hr/doctype/employee/employee.txt index 225b4850c2..f8b08e08d4 100644 --- a/hr/doctype/employee/employee.txt +++ b/hr/doctype/employee/employee.txt @@ -2,7 +2,7 @@ { "creation": "2013-03-07 09:04:18", "docstatus": 0, - "modified": "2013-12-20 19:24:06", + "modified": "2013-12-23 19:35:27", "modified_by": "Administrator", "owner": "Administrator" }, @@ -760,6 +760,7 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "restrict": 0, "role": "HR User", "write": 1 }, @@ -767,6 +768,7 @@ "cancel": 1, "create": 1, "doctype": "DocPerm", + "restrict": 1, "role": "HR Manager", "write": 1 } diff --git a/hr/doctype/leave_application/leave_application.txt b/hr/doctype/leave_application/leave_application.txt index 10c0429077..24de6a82fc 100644 --- a/hr/doctype/leave_application/leave_application.txt +++ b/hr/doctype/leave_application/leave_application.txt @@ -2,7 +2,7 @@ { "creation": "2013-02-20 11:18:11", "docstatus": 0, - "modified": "2013-12-20 19:24:12", + "modified": "2013-12-23 19:53:41", "modified_by": "Administrator", "owner": "Administrator" }, @@ -256,6 +256,7 @@ "permlevel": 0, "print": 1, "report": 1, + "restrict": 1, "role": "HR User", "submit": 1, "write": 1 diff --git a/patches/1312/p02_update_user_properties.py b/patches/1312/p02_update_user_properties.py index 4ac1ab9615..70c500f277 100644 --- a/patches/1312/p02_update_user_properties.py +++ b/patches/1312/p02_update_user_properties.py @@ -3,51 +3,59 @@ from __future__ import unicode_literals import webnotes +import webnotes.permissions +import webnotes.model.doctype +import webnotes.defaults def execute(): + webnotes.reload_doc("core", "doctype", "docperm") update_user_properties() update_user_match() + add_employee_restrictions_to_leave_approver() update_permissions() remove_duplicate_restrictions() + webnotes.defaults.clear_cache() webnotes.clear_cache() def update_user_properties(): webnotes.reload_doc("core", "doctype", "docfield") - for d in webnotes.conn.sql("""select parent, defkey, defvalue from tabDefaultValue + for d in webnotes.conn.sql("""select parent, defkey, defvalue from tabDefaultValue where parent not in ('__global', 'Control Panel')""", as_dict=True): - df = webnotes.conn.sql("""select options from tabDocField + df = webnotes.conn.sql("""select options from tabDocField where fieldname=%s and fieldtype='Link'""", d.defkey, as_dict=True) if df: - webnotes.conn.sql("""update tabDefaultValue - set defkey=%s, parenttype='Restriction' - where defkey=%s and + webnotes.conn.sql("""update tabDefaultValue + set defkey=%s, parenttype='Restriction' + where defkey=%s and parent not in ('__global', 'Control Panel')""", (df[0].options, d.defkey)) - + def update_user_match(): import webnotes.defaults doctype_matches = {} for doctype, match in webnotes.conn.sql("""select parent, `match` from `tabDocPerm` - where `match` like %s""", "%:user"): + where `match` like %s and ifnull(`match`, '')!="leave_approver:user" """, "%:user"): doctype_matches.setdefault(doctype, []).append(match) for doctype, user_matches in doctype_matches.items(): - # get permissions of this doctype - perms = webnotes.conn.sql("""select role, `match` from `tabDocPerm` - where parent=%s and permlevel=0 and `read`=1""", doctype, as_dict=True) + meta = webnotes.get_doctype(doctype) # for each user with roles of this doctype, check if match condition applies for profile in webnotes.conn.sql_list("""select name from `tabProfile` where enabled=1 and user_type='System User'"""): - roles = webnotes.get_roles(profile) + perms = webnotes.permissions.get_user_perms(meta, "read", profile) + # user does not have required roles + if not perms: + continue - user_match = False + # assume match + user_match = True for perm in perms: - if perm.role in roles and (perm.match and \ - (perm.match.endswith(":user") or perm.match.endswith(":profile"))): - user_match = True + if not perm.match: + # aha! non match found + user_match = False break if not user_match: @@ -60,18 +68,35 @@ def update_user_match(): where `{field}`=%s""".format(doctype=doctype, field=match.split(":")[0]), profile): webnotes.defaults.add_default(doctype, name, profile, "Restriction") + +def add_employee_restrictions_to_leave_approver(): + from core.page.user_properties import user_properties + + # add restrict rights to HR User and HR Manager + webnotes.conn.sql("""update `tabDocPerm` set `restrict`=1 where parent in ('Employee', 'Leave Application') + and role in ('HR User', 'HR Manager') and permlevel=0 and `read`=1""") + webnotes.model.doctype.clear_cache() + + # add Employee restrictions (in on_update method) + for employee in webnotes.conn.sql_list("""select name from `tabEmployee` + where exists(select leave_approver from `tabEmployee Leave Approver` + where `tabEmployee Leave Approver`.parent=`tabEmployee`.name) + or ifnull(`reports_to`, '')!=''"""): + + webnotes.bean("Employee", employee).save() def update_permissions(): # clear match conditions other than owner webnotes.conn.sql("""update tabDocPerm set `match`='' where ifnull(`match`,'') not in ('', 'owner')""") - + def remove_duplicate_restrictions(): # remove duplicate restrictions (if they exist) - for d in webnotes.conn.sql("""select parent, defkey, defvalue, - count(*) as cnt from tabDefaultValue - where parent not in ('__global', 'Control Panel') + for d in webnotes.conn.sql("""select parent, defkey, defvalue, + count(*) as cnt from tabDefaultValue + where parent not in ('__global', 'Control Panel') group by parent, defkey, defvalue""", as_dict=1): if d.cnt > 1: - webnotes.conn.sql("""delete from tabDefaultValue where parent=%s, defkey=%s, - defvalue=%s limit %s""", (d.parent, d.defkey, d.defvalue, d.cnt-1)) \ No newline at end of file + # order by parenttype so that restriction does not get removed! + webnotes.conn.sql("""delete from tabDefaultValue where parent=%s, defkey=%s, + defvalue=%s order by parenttype limit %s""", (d.parent, d.defkey, d.defvalue, d.cnt-1))