[fix] Ignore permissions and made Customer warehouse field hidden in selling cycle
diff --git a/erpnext/accounts/doctype/sales_invoice_item/sales_invoice_item.json b/erpnext/accounts/doctype/sales_invoice_item/sales_invoice_item.json
index 8e9be7e..79f5f55 100644
--- a/erpnext/accounts/doctype/sales_invoice_item/sales_invoice_item.json
+++ b/erpnext/accounts/doctype/sales_invoice_item/sales_invoice_item.json
@@ -7,6 +7,7 @@
"custom": 0,
"docstatus": 0,
"doctype": "DocType",
+ "document_type": "Document",
"fields": [
{
"allow_on_submit": 0,
@@ -972,13 +973,13 @@
"collapsible": 0,
"fieldname": "target_warehouse",
"fieldtype": "Link",
- "hidden": 0,
- "ignore_user_permissions": 0,
+ "hidden": 1,
+ "ignore_user_permissions": 1,
"in_filter": 0,
"in_list_view": 0,
- "label": "Target Warehouse",
+ "label": "Customer Warehouse (Optional)",
"length": 0,
- "no_copy": 0,
+ "no_copy": 1,
"options": "Warehouse",
"permlevel": 0,
"precision": "",
@@ -1444,7 +1445,7 @@
"issingle": 0,
"istable": 1,
"max_attachments": 0,
- "modified": "2016-01-06 02:23:06.432442",
+ "modified": "2016-02-01 11:16:58.288462",
"modified_by": "Administrator",
"module": "Accounts",
"name": "Sales Invoice Item",
diff --git a/erpnext/selling/doctype/sales_order_item/sales_order_item.json b/erpnext/selling/doctype/sales_order_item/sales_order_item.json
index 823b805..184a4f4 100644
--- a/erpnext/selling/doctype/sales_order_item/sales_order_item.json
+++ b/erpnext/selling/doctype/sales_order_item/sales_order_item.json
@@ -7,6 +7,7 @@
"custom": 0,
"docstatus": 0,
"doctype": "DocType",
+ "document_type": "Document",
"fields": [
{
"allow_on_submit": 0,
@@ -874,13 +875,13 @@
"depends_on": "eval:doc.delivered_by_supplier!=1",
"fieldname": "target_warehouse",
"fieldtype": "Link",
- "hidden": 0,
+ "hidden": 1,
"ignore_user_permissions": 1,
"in_filter": 0,
"in_list_view": 0,
- "label": "Target Warehouse",
+ "label": "Customer Warehouse (Optional)",
"length": 0,
- "no_copy": 0,
+ "no_copy": 1,
"options": "Warehouse",
"permlevel": 0,
"precision": "",
@@ -1289,7 +1290,7 @@
"istable": 1,
"max_attachments": 0,
"menu_index": 0,
- "modified": "2015-12-11 14:53:24.444343",
+ "modified": "2016-02-01 11:16:40.514399",
"modified_by": "Administrator",
"module": "Selling",
"name": "Sales Order Item",
diff --git a/erpnext/stock/doctype/delivery_note/delivery_note.json b/erpnext/stock/doctype/delivery_note/delivery_note.json
index f001f85..5f85c01 100644
--- a/erpnext/stock/doctype/delivery_note/delivery_note.json
+++ b/erpnext/stock/doctype/delivery_note/delivery_note.json
@@ -2696,18 +2696,58 @@
"istable": 0,
"max_attachments": 0,
"menu_index": 0,
- "modified": "2015-12-25 16:20:39.014291",
+ "modified": "2016-01-31 14:06:52.136821",
"modified_by": "Administrator",
"module": "Stock",
"name": "Delivery Note",
"owner": "Administrator",
"permissions": [
{
+ "amend": 0,
+ "apply_user_permissions": 0,
+ "cancel": 0,
+ "create": 1,
+ "delete": 1,
+ "email": 1,
+ "export": 1,
+ "if_owner": 0,
+ "import": 0,
+ "permlevel": 1,
+ "print": 1,
+ "read": 1,
+ "report": 1,
+ "role": "All",
+ "set_user_permissions": 0,
+ "share": 1,
+ "submit": 0,
+ "write": 0
+ },
+ {
"amend": 1,
"apply_user_permissions": 0,
"cancel": 1,
"create": 1,
- "delete": 1,
+ "delete": 0,
+ "email": 1,
+ "export": 1,
+ "if_owner": 0,
+ "import": 0,
+ "permlevel": 0,
+ "print": 1,
+ "read": 1,
+ "report": 1,
+ "role": "Office Coordinator",
+ "set_user_permissions": 0,
+ "share": 1,
+ "submit": 1,
+ "write": 1
+ },
+ {
+ "amend": 1,
+ "apply_user_permissions": 0,
+ "cancel": 1,
+ "create": 1,
+ "delete": 0,
"email": 1,
"export": 0,
"if_owner": 0,
@@ -2723,6 +2763,27 @@
"write": 1
},
{
+ "amend": 0,
+ "apply_user_permissions": 1,
+ "cancel": 1,
+ "create": 1,
+ "delete": 0,
+ "email": 1,
+ "export": 1,
+ "if_owner": 0,
+ "import": 0,
+ "permlevel": 0,
+ "print": 1,
+ "read": 1,
+ "report": 1,
+ "role": "Store Keeper",
+ "set_user_permissions": 0,
+ "share": 1,
+ "submit": 1,
+ "user_permission_doctypes": "[\"Warehouse\"]",
+ "write": 1
+ },
+ {
"amend": 1,
"apply_user_permissions": 0,
"cancel": 1,
@@ -2744,10 +2805,10 @@
},
{
"amend": 1,
- "apply_user_permissions": 0,
+ "apply_user_permissions": 1,
"cancel": 1,
"create": 1,
- "delete": 1,
+ "delete": 0,
"email": 1,
"export": 0,
"if_owner": 0,
@@ -2760,6 +2821,7 @@
"set_user_permissions": 0,
"share": 1,
"submit": 1,
+ "user_permission_doctypes": "[\"Warehouse\"]",
"write": 1
},
{
@@ -2801,26 +2863,6 @@
"share": 0,
"submit": 0,
"write": 0
- },
- {
- "amend": 0,
- "apply_user_permissions": 0,
- "cancel": 0,
- "create": 0,
- "delete": 0,
- "email": 0,
- "export": 0,
- "if_owner": 0,
- "import": 0,
- "permlevel": 1,
- "print": 0,
- "read": 1,
- "report": 0,
- "role": "Stock Manager",
- "set_user_permissions": 0,
- "share": 0,
- "submit": 0,
- "write": 1
}
],
"read_only": 0,
diff --git a/erpnext/stock/doctype/delivery_note_item/delivery_note_item.json b/erpnext/stock/doctype/delivery_note_item/delivery_note_item.json
index dcafc1e..6ed16ce 100644
--- a/erpnext/stock/doctype/delivery_note_item/delivery_note_item.json
+++ b/erpnext/stock/doctype/delivery_note_item/delivery_note_item.json
@@ -7,6 +7,7 @@
"custom": 0,
"docstatus": 0,
"doctype": "DocType",
+ "document_type": "Document",
"fields": [
{
"allow_on_submit": 0,
@@ -823,13 +824,13 @@
"description": "",
"fieldname": "target_warehouse",
"fieldtype": "Link",
- "hidden": 0,
+ "hidden": 1,
"ignore_user_permissions": 1,
"in_filter": 0,
"in_list_view": 0,
- "label": "To Warehouse (Optional)",
+ "label": "Customer Warehouse (Optional)",
"length": 0,
- "no_copy": 0,
+ "no_copy": 1,
"options": "Warehouse",
"permlevel": 0,
"precision": "",
@@ -1286,7 +1287,7 @@
"issingle": 0,
"istable": 1,
"max_attachments": 0,
- "modified": "2016-01-07 05:59:56.448357",
+ "modified": "2016-02-01 11:16:23.749244",
"modified_by": "Administrator",
"module": "Stock",
"name": "Delivery Note Item",