diff --git a/sale_timesheet_line_exclude/README.rst b/sale_timesheet_line_exclude/README.rst
index df46c65644..81e30124e4 100644
--- a/sale_timesheet_line_exclude/README.rst
+++ b/sale_timesheet_line_exclude/README.rst
@@ -54,6 +54,9 @@ or:
# Go to *Project > All Tasks*, ans open a specific Task form
# On the Task form, *Timesheets* tab, check *Non-billable* for specific timesheet entries
+To have access to this *Non-billable* field, the user must be added to the
+*Exclude timesheets from sale order* security group.
+
Bug Tracker
===========
diff --git a/sale_timesheet_line_exclude/__manifest__.py b/sale_timesheet_line_exclude/__manifest__.py
index 49859fad0d..5c13075efa 100644
--- a/sale_timesheet_line_exclude/__manifest__.py
+++ b/sale_timesheet_line_exclude/__manifest__.py
@@ -13,5 +13,9 @@
"application": False,
"summary": "Exclude Timesheet Line from Sale Order",
"depends": ["sale_timesheet"],
- "data": ["views/account_analytic_line.xml", "views/project_task.xml"],
+ "data": [
+ "security/exclude_from_sale_order.xml",
+ "views/account_analytic_line.xml",
+ "views/project_task.xml",
+ ],
}
diff --git a/sale_timesheet_line_exclude/models/account_analytic_line.py b/sale_timesheet_line_exclude/models/account_analytic_line.py
index b6aca3782a..de0514f48c 100644
--- a/sale_timesheet_line_exclude/models/account_analytic_line.py
+++ b/sale_timesheet_line_exclude/models/account_analytic_line.py
@@ -11,6 +11,7 @@ class AccountAnalyticLine(models.Model):
exclude_from_sale_order = fields.Boolean(
string="Non-billable",
help="Checking this would exclude this timesheet entry from Sale Order",
+ groups="sale_timesheet_line_exclude.group_exclude_from_sale_order",
)
@api.constrains("exclude_from_sale_order")
diff --git a/sale_timesheet_line_exclude/readme/USAGE.rst b/sale_timesheet_line_exclude/readme/USAGE.rst
index 48431ba103..eff18f5e14 100644
--- a/sale_timesheet_line_exclude/readme/USAGE.rst
+++ b/sale_timesheet_line_exclude/readme/USAGE.rst
@@ -7,3 +7,6 @@ or:
# Go to *Project > All Tasks*, ans open a specific Task form
# On the Task form, *Timesheets* tab, check *Non-billable* for specific timesheet entries
+
+To have access to this *Non-billable* field, the user must be added to the
+*Exclude timesheets from sale order* security group.
diff --git a/sale_timesheet_line_exclude/security/exclude_from_sale_order.xml b/sale_timesheet_line_exclude/security/exclude_from_sale_order.xml
new file mode 100644
index 0000000000..9011d88f63
--- /dev/null
+++ b/sale_timesheet_line_exclude/security/exclude_from_sale_order.xml
@@ -0,0 +1,14 @@
+
+
+
# Go to Project > All Tasks, ans open a specific Task form # On the Task form, Timesheets tab, check Non-billable for specific timesheet entries+
To have access to this Non-billable field, the user must be added to the +Exclude timesheets from sale order security group.