Commit Graph
147686 Commits
Author SHA1 Message Date
Francois (fge) 4500a72c1c [IMP] mail: add empty message (@ and #)
closes odoo/odoo#74933

Task-id: 2622240
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
2021-08-26 13:56:14 +00:00
Francois (fge) dca9ca6464 [IMP] web: refactor debug commands
Rename `Debug Menu` => `Debug tools...`
Remove `Debug tools...` hotkey

The commands in the debug category need to have a search value
to be displayed.

Task-id: 2622240
Part-of: odoo/odoo#74933
2021-08-26 13:56:14 +00:00
Francois (fge) 8b856c6699 [IMP] web: refactor command palette
This commit is a refactoring of the command palette. It aims to improve
its design and make it very easily configurable. For this, we added the
config props allowing the command palette to know what to display.

The config of a palette command is composed of:
- categoriesByNamespace?: list containing all categories according
  to their namespace;
- emptyMessageByNamespace?: dictionary having for key a namespace and
  for value the message to display if there is no choice available;
- footerTemplate?: template to display in the footer;
- namespace?: namespace to add in the search bar;
- placeholder?: placeholder of the searcher;
- providers: list containing all the providers generating the commands
  to display;
The providers are the only information needed in the config. The rest of
the config is optional.

This commit also adds the possibility to open a custom command palette
using the command service. For this, you just have to call openPalette
and give it the required config.

If the command action returns a config, the command palette  will
not be close and will use this new config.

Task-id: 2622240
Part-of: odoo/odoo#74933
2021-08-26 13:56:14 +00:00
Xavier BOL (xbo) 0de3f3ace5 [IMP] project: allow portal user to see only active tasks
Before this commit, the portal user could see archived tasks by filtering the
tasks with the search view.

This commit adds a condition in the domain of the `ir.rule` for this user
to allow him to see only the active tasks.

task-2379518

closes #73341
2021-08-26 14:59:34 +02:00
Xavier BOL (xbo) 7ed6e9e16b [IMP] project: detect if the user changes the access rights
Before this commit, the user cannot remove all access rights for project
sharing feature of a project with allow_project_sharing enabled.

This commit checks if the user has made a change in the access rights if
yes then the 'Confirm Access' button appears otherwise only 'Send'
button appears.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 57b8eb7e3b [IMP] project: not allow portal user to archive tasks
Before this commit, the portal can archive tasks via the kanban views

This commit removes the buttons thanks to the `archivable` option set to
false.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Yannick Tivisse 82b522ce3b [IMP] project: protect orm methods
Before this commit, the portal user could use the public orm methods to
get more information than he allowed.

This commit checks in the orm methods if the fields used in those
methods can be accessed by this user.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) ed0a5ea431 [IMP] web: allow no open in x2m list view in form view
Before this commit, when we set `no_open` in list view for x2m record in
form view, the no_open is not take into account. Either the list is
editable and then the form dialog is no displayed and the user can edit
in the list or the list view is readonly and when the user clicks on a
row in this list view, the form view dialog appears.

This commit changes the condition in the `no_open` to force to set to true
when the no_open is set to true. So, when the no_open=True even if the
list view of x2m record is in readonly, the form view dialog is not
called and thus it will no longer appear in this case.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 768c63b15e [IMP] project: add unit test for project sharing feature
task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) a55de1e0a1 [FIX] sale_timesheet: cannot create task in billable project
Before this commit, the portal user cannot create task in billable
project because he has no access rights to employee mappings model.
Indeed, this model is used to know the pricing type of the project and
also to search the default partner of the new task. If the user cannot
access we need to do it in sudo.

This commit adds a sudo to search correctly the default partner of the
task.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 19a8bf9527 [IMP] project: check portal user can access to project sharing chatter
Before this commit, when we change the access right to the portal user
and this user is in task form view with chatter. He can send message
even we remove the access right.

This commit checks if the user has the access before sending the
message.

task-2379518
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) a60aaa3910 [IMP] project: use project sharings in portal route
Before this commit, when the portal user can access to project sharing
and click on the shared link of the project. He is redirected to the
`/project_sharing/<int:project_id>` route. Since only the portal user
can access and no public users, we could directly redirect to the portal
route and display project sharing views.

This commit removes the `/project_sharing/<int:project_id>` route.
The main route will always be the `/my/project/<int:project_id>` and
we check if the user can access project before rendering.

If the user can access to the project via the shared link:

1. If he is a public user then we render the classic portal view.
2. If he is a portal user then
    - we check if he is an access to project sharing, if yes then we
      render project sharing views otherwise we display the classic
      portal views.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 5fcf6dee66 [FIX] hr_timesheet: add sudo to _apply_timesheet_label method
Before this commit, the portal user has no access to uom.uom model.
Therefore, this user has an access error when we want to see task form
view.

This commit adds a sudo to use this method to correctly display the
label for the unit_amount of timesheets shown in the task form view.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) c0e569dd90 [FIX] hr_timesheet: add compute_sudo for analytic_account_active compute
Before this commit, the portal user cannot access to the task form view
since he does not have any access to `account.analytic.account` model.

This commit adds `compute_sudo=True` in field definition of
`analytic_account_active` to bypass the access rights in its compute
method.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 4c5edbd0fc [IMP] hr_timesheet: add read access to timesheets for portal users
Before this commit, the portal could not access to timesheets of the
task in project sharing views.

This commit adds the access to give him the read access to the
timesheets in the tasks of the shared project.
Moreover, this commit adds a `ir.rule` to limit the access to this
portal user and we keep the default values to True on all perms,
that way if someone modifies the ACL to give C/W/U permissions,
this rule will still give some protection.

task-2379518

closes #73341

Co-authored: Yannick Tivisse (yti) <yti@odoo.com>
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo)andYannick Tivisse 5ea5ddafea [IMP] project: select access rights in project sharing
Before this commit, when the portal user can access to project sharing
views, he can just read. If we just add ir.rule to allow the edition,
the portal could create/edit. We have to allow the project manager to
define the access rights of portal users when he want to share them a
project with the project sharing feature.

This commit adds 3 access modes portal users in project sharing views.
1. **Readonly**: the portal can only see the tasks in the different views.
2. **Comment**: the portal can use the chatter in task form view.
3. **Edit**: the portal user can create and edit tasks.

task-2379518

closes #73341

Co-Authored-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 716f47d14b [IMP] project: give create/write access right to portal user
Before this commit, the portal users can only see the tasks in the
project sharing views.

This commit allows these users can also create tasks and edit some
fields in task.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) bad706d34c [IMP] project: check if the chatter is visible before mounting it
Before this commit, if we put an invisible in attrs of div tag for the
chatter, the attrs is not taken into account because when the chatter
is mounting this div is replaced.

This commit changes the class for the chatter in project sharing and
check if the div is visible before mounting the chatter.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo)andYannick Tivisse a8af1361e5 [IMP] project: limit access to portal user in project sharing
Before this commit, the portal user can read all fields in the
`project.task` model.

This commit checks when the portal user wants to read task record(s) if
this user can see all fields given in parameters. When the portal user
edits or creates a task, we check if this user can edit fields and
create/edit the task based on his access rights and the ir.rules.

task-2379518

closes #73341

Co-Authored-by: Yannick Tivisse (yti) <yti@odoo.com>
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) d3ecc4962e [IMP] project: update chatter when create/change task
Before this commit, when the user changes the task, the chatter is not
updated so we keep the messages of the previous task. Same thing when
the portal user wants to create a new task.

This commit updates the chatter to allow to fetch the messages when the
user changes the task and also disables the chatter when the user is
creating a new task.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 0c7b99987a [IMP] project,portal: allow portal user not follow task to use chatter
Before this commit, if the portal user is a follower of the project he
can use the chatter of new tasks in the project sharing feature since
the follower of the project is automatically the follower of new tasks.
But if he is not a follower of the task (for instance, old task in the
project) then we have to check if the
access token is the one of the shared project to give the access to
the chatter.

This commit checks the `access_token` of the project when we are in the
project sharing form view to allow the portal user to use the chatter.

task-2379518

closes #73341

Co-authored: Yannick Tivisse (yti) <yti@odoo.com>
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 60e97e4ffb [IMP] project: add chatter in project sharing form view
Before this commit, the chatter is not available in form view of project
sharing even for portal user. Since the portal views, we have a chatter
for the portal users, we need a chatter for those users in project
sharing.

This commit integrates the portal chatter in the form view for only the
portal users.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 2bbb038f22 [IMP] project: replace the basic portal views when project selected
Before this commit, when the portal user is connected and selects a project
in the list when he is in `/my/projects` route, we redirect him in the
task list of this project.

This commit replaces the basic portal view by the project sharing views
if the Project Sharing feature is enabled for this project.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 36f5982e18 [IMP] project: remove the action contextual menu in project sharing
Before this commit, the user in the project sharing views can
Archive/Unarchive the record via the action menu. He can also click on
the share button in the action menu.

This commit removes the default action buttons defined in the action
menu for form and kanban views.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 0e1961b1dd [IMP] project,mail: disable click on avatar
Before this commit, there is no options to disable the click on the
avatar to open the chat in `Many2OneAvatarUser` widget.

This commit adds an option called `no_open_chat` set by default to false
and this option allow to disable the click when it is true. This option
is useful for the project sharing views.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 0748caa97c [IMP] sale_timesheet: add project sharing views
task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 31d943666f [IMP] sale_project: add project sharing views
task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 0e659dc4d7 [IMP] hr_timesheet,project: override project sharing views
This commit override the project_sharing views to add fields defined in
`hr_timesheet` module.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 58a12e03ab [FIX] project: remove duplicate field in project task kanban view
task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) 45c96edae7 [IMP] project: remove the longpolling for project sharing views
Before this commit, the longpolling is active in the project sharing
views but it is not necessary for these views, since the chat is
disabled and the goal of these views is to give access to external
users to `project.task` views.

This commit removes the files about the longpolling for the bundle used
for project sharing.

task-2379518

closes #73341
2021-08-26 14:59:33 +02:00
Xavier BOL (xbo) e50bc12002 [IMP] project: add Project Sharing feature
Purpose:
=======

This commit adds the project sharing feature. This feature consists to
share the backend views about project.task to portal users.

About the access rights:
- The project manager can share a project with project sharing feature.
  To do this, he need to give access to portal users that we want their access in project sharing views.
  He can choose between 3 differents accesses:
    1. Readonly: the portal with this access right will only have read access to the project
        sharing views of the project shared.
    2. Comment: the portal with this access right will can use the chatter in task form view.
    3. Edit: the portal with this access right will can edit some fields of `project.task` model.

The difference between the classic backend views and the project sharing
views is in the project sharing views, we list the fields that the user
can read/write, so the portal users can see only the fields in
our list.
Moreover, the actions and the contextual menu (actions dropdown) are not
available in the project sharing views and the stat buttons are visible
but the click on these buttons are disabled.

Implementation details:
======================

This commit is realized in many steps:

- create the webclient and routes.
- create own qweb bundle.
- add project sharing views.
- use the session to define the action and active_id
- create public fields for project sharing: in this step, we lists all field
names of the `project.task` model that we want to display for the
portal user. Two lists are created, one for only readable field names
and the other one for the writable field names.
Moreover, two properties are defined in the `project.task` model to use the
both lists.
- use `access_token` and check model in project sharing route: in this
step we check if the model is `project.project` and the `access_token`
is the one set in the project since we have the id of the project in the
params url.
- allow only `GET` method to enter project_sharing routes: the
`/my/project/<int:project_id>/project_sharing` route must only be
called with a `GET` method because this route is only used to have the template
to render the project sharing webclient.

task-2379518

closes #73341
2021-08-26 14:59:32 +02:00
std-odoo 61d9cb8098 [IMP] mail_plugin: add translations for 404 error management
Purpose
=======

Currently the application will display a 404 error message, if the mail
plugin module is not installed or if the user made an error in the URL
of his Odoo database, which is confusing for end users.

So, we show an error message during the authentication process if the
database is not reachable and we should add the translations related to
those changes.

Task-2577531
See odoo/mail-client-extensions/pull/17

closes odoo/odoo#75637

X-original-commit: 3c00fddb99091b96259eed1e45ef9de53c53f795
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2021-08-26 12:46:55 +00:00
Sébastien Theys b1f3340042 [IMP] mail, hr_holidays: add member list on channels
task-2368906

closes odoo/odoo#75605

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2021-08-26 11:34:52 +00:00
Tiffany Chang (tic) 311b6915b0 [IMP] mrp(_account): clean/add demo data
Clean up of some demo data that was referring to old demo data
names/prices. Also add extra demo data so we can have some
stock.valuation.layer values and some data points for enterprise
level reports.

Part 3.3 of task: 2440068
ENT PR: odoo/enterprise#20169

closes odoo/odoo#74951

Related: odoo/upgrade#2727
Signed-off-by: Rémy Voet <ryv-odoo@users.noreply.github.com>
2021-08-26 11:34:36 +00:00
Tiffany Chang (tic) 160c686fa8 [IMP] mrp: apply small UX changes to reports
Small updates:
- Rearrange order of report menu.
- Update default filters/groupings for some reports.
- Make work center "Load" smart button load graph view with filter
  defaults to match number calculated for smart button.

Part of review for task: 2440068
Related ENT PR: odoo/enterprise#20169

Part-of: odoo/odoo#74951
2021-08-26 11:34:35 +00:00
Tiffany Chang (tic) c12bb6090c [IMP] mrp,stock: add pivot/graph view for scrap
Add a pivot and graph view to scrap orders by default so users no longer
have to use studio to do scrap per products/manufacturing orders analysis.
To help support this, groupby picking/mo has also be added in.

Part 4 of Task: 2440068
Related ENT PR: odoo/enterprise#20169

Part-of: odoo/odoo#74951
2021-08-26 11:34:35 +00:00
Tiffany Chang (tic) fd52760266 [IMP] mrp(_account): include byproduct cost share in BoM/MO
For improved cost analysis, byproducts can now have a "cost share" (out
of 100%) indicated. This cost share will by multiplied by the total BoM
cost (i.e. components + operations costs) and reflected in the stock
valuation. The final product will also have the byproducts cost
subtracted from its final stock valuation. This is of course only
applies when costing methods are appropriate (i.e. non-standard price).

Additionally, we can now "Compute Price from BoM" for byproducts (via
its product form) and the BoMs that it is a byproduct of are now counted
towards its # BoMs smart button (we will now also see these BoMs when
clicking on the smart button). Of course when there is no cost share for
byproducts then clicking on "Compute Price for BoM" will not change the
a byproduct's cost and if there are multiple BoMs the prodcut is a
byproduct of, the calculation will only be based on the first BoM it
finds (i.e. same as current logic for manufactured products).

BoM Cost report has been updated to include byproducts with cost shares
(byproducts with cost share = 0 will not show up in report).
Additionally we update the report to display operations only costs now
that BoMs are allowed to have no components in them.

Part 1 of Task: 2440068
Upgrade PR: odoo/upgrade#2727
Related ENT PR: odoo/enterprise#20169

Part-of: odoo/odoo#74951
2021-08-26 11:34:35 +00:00
Tiffany Chang (tic) 8581700943 [IMP] mrp: store wo hourly cost
This commit adds a new field to work orders to store the hourly cost of
its work center at the time of its completion. This is to avoid
inconsistent cost calculations when a work center's hourly cost is
changed after the WO is completed.

Part 2 (fix) of task: 2440068
Enterprise PR: odoo/enterprise#20169
Upgrade PR: odoo/upgrade#2727

Part-of: odoo/odoo#74951
2021-08-26 11:34:34 +00:00
Tiffany Chang (tic) b25488144e [IMP] mrp(_account): customize measures for MO graph/pivot
Hide useless measures:
- "Backorder Sequence"
- "Extra Cost"
- "Quantity to Produce" (same as "Total Quantity", but not standardized
  to product's UoM)

Renames confusingly named measures:
- "Quantity Producing" => "Quantity Produced" (i.e. amount actually
  produced)
- "Total Quantity" => "Product Quantity" (i.e. amount scheduled to be
  produced in product's UoM)

Part 3.1 of task: 2440068
Related ENT PR: odoo/enterprise#20169

Part-of: odoo/odoo#74951
2021-08-26 11:34:34 +00:00
jbw 064edb2223 [IMP] account, sale, purchase: accrued entries from purchase & sales orders.
Accrued liabilities, or accrued expenses, occur when you incur an expense that you haven’t been billed for (aka a debt).
For example, you receive a good now and pay for it later (e.g., when you receive the invoice). The same opposite approach for sales.

Why do accountants need such entries ?
- Accounting must give a fair view of the financial situation of a company. The loss/profit must be booked regarding the effective deliveries of goods/services, not on the paperwork only.
- On a fiscal point of view, if you want to be allowed to deduct a loss from your taxable basis, it has to be in the right period. If you didn't announce it on time, the loss might be rejected by fiscal authorities. Same goes for the augmentation of the taxable basis, it has to reflect real deliveries and not only paperwork.

was Task: 2555642
was PR #73707

Signed-off-by: Quentin De Paoli (qdp) <qdp@openerp.com>
2021-08-26 11:34:14 +00:00
William Henrotin 19673b5c55 [FIX] purchase_stock: check if picking_type has a warehouse
Commit 643e093a4bc9d46973705831697036b56a89b143 adds a security on
orderpoints triggering purchase orders. But this new check fails in case
the picking type on the purchase order is not linked to a warehouse (e.g
in a subcontracting flow).

This commit ensure the check is done only if we have a warehouse linked
to the purchase order.

closes odoo/odoo#75619

Opw: 2631979
X-original-commit: 8343ce44d72c77f56937e1694606dc718497fbb8
Signed-off-by: William Henrotin <Whenrow@users.noreply.github.com>
2021-08-26 10:21:42 +00:00
Sébastien Mottet (oms) 23915c7113 [IMP] website: add saas version in calls to website.api.odoo.com
The saas version of the client is added in each call to
website.api.odoo.com. This allows the server to return
different results based on the client's saas version

task-2602521

closes odoo/odoo#75617

X-original-commit: 6e1ae856584048912cb5eaf53c0aa027b2342b5c
Signed-off-by: Sébastien Mottet <smottet@users.noreply.github.com>
Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2021-08-26 10:21:38 +00:00
qsm-odoo ea108e3910 [FIX] web_editor: review snippet drag and drop technical flow
This commit completes [1] by further reviewing the drag and drop
technical flow order:

- The content_changed event should be triggered before starting snippets
  as well as it is only useful to signal the snippet modifications made
  by onBuilt.

- The undroppable snippets update which was done first could probably be
  done anywhere -> best to put it at the end when everything in the DOM
  is done, and it is also the last thing the user expects to be done.

Note: in the new editor the role of 'content_changed' became however
unclear and should be further reviewed. This commit fixes problems with
the old flow in master though (problems around removing items in a
snippet during its onBuilt call).

[1]: https://github.com/odoo/odoo/commit/60d7bf6d7daea83db9332b4fc47a4ac6892d21d7

closes odoo/odoo#75596

X-original-commit: efdfe261afd933972869305fd3358c764f7c18c3
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2021-08-26 10:21:32 +00:00
Romain Derie 5afd3b996b [REM] base: remove dead code
This code was no more called, as there is the same-ish condition a few lines
above:
```
if (tools.config['test_enable'] or tools.config['test_file']) ...:
```

Moreover, that code was wrong and was crashing if you remove the first if
condition to test that code, as the method is expected to return a tuple.
It would just raise a traceback
```
too many values to unpack (expected 2)
```

Part of #75377

Related: odoo/enterprise#20449
Signed-off-by: Romain Derie <rdeodoo@users.noreply.github.com>
2021-08-26 10:21:29 +00:00
Romain Derie 88b19cfa92 [FIX] base, mail: _render_qweb_pdf should return a bytes-like object
`result` might be a Markup object (eg during tests) or a bytes-like object.

Step to reproduce: click on "Send by Mail" on a SO -> Traceback

Step to reproduce (2):
- Install website_sale
- Add something to the cart
- Go through checkout and click on Pay Now
- Crash, 500 error page, as this step is trying to generate the SO PDF to send
  by mail to the customer, which tries to encode a bytes-like object.

```
AttributeError: 'bytes' object has no attribute 'encode'
```

But if you do that flow during a test, eg
```
./odoo-bin -d mydb --test-tags=.test_02_admin_checkout
```
You have a Markup object, thus you had to encode it.

Now, even during test, we return a bytes-like object.

Related to #68299

Community: https://github.com/odoo/odoo/pull/75377
Enterprise: https://github.com/odoo/enterprise/pull/20449
Part-of: odoo/odoo#75377
2021-08-26 10:21:28 +00:00
Jeremy Kersten f868299d9e [FIX] website_sale_delivery_mondialrelay: avoid crash when wrong zip
Actual widget is bugged in case your type a wrong zip code.
This commit avoid (by ugly way) the exception to be raised to the end user.
It is temporary and should be reverted once Mondial Relay fixes his bug.
It is why we merge it in a second commit to be easily reverted.

closes odoo/odoo#75281

Signed-off-by: Romain Derie <rdeodoo@users.noreply.github.com>
2021-08-26 10:21:16 +00:00
Jeremy Kersten e9a33a436f [ADD] (website_sale_)delivery_mondialrelay: allow to use MondialRelay
This commit let you choose a Point Relais® as your shipping address.
It instantiates the Widget only.
It will not handle the print label.

Part-of: odoo/odoo#75281
2021-08-26 10:21:16 +00:00
Xavier-Do bd851a24ca [FIX] base: add missing nodeattr in ormcache keys
No real bug was found regarding this issue but it looks
like `nodeAttrs and nodeAttrs.get("media")` was missing from
`ormcache_context` since it is used to generate the output.

closes odoo/odoo#75248

Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2021-08-26 10:21:11 +00:00
Xavier-Do fdaee845d5 [FIX] base: remove options parameters
Regarding previous commit, the option parameter can be removed
from _get_asset_content api, followed by a nice snowball effect.

Part-of: odoo/odoo#75248
2021-08-26 10:21:10 +00:00
Xavier-Do 2921f60055 [IMP] base: remove dead code
options are not used anymore since 8cc066173d

This was discovered by @d-fence

Part-of: odoo/odoo#75248
2021-08-26 10:21:10 +00:00