Xavier ALT 308c5b38e2 [FIX] sale_purchase: cancel order wizard warn about PO when there's none
To reproduce on runbot:

- edit the access rights of internal user 'lauriepoiret' and grant she
  the group "Sales / User: own document only" (and ensure she does not
  have the group  "Purchase / User")

- as 'lauriepoiret', create a sale order for a product without
  'service subcontracting' (ex. Bacon Burger) and confirm it

- click on "Cancel" button

In the wizard and warning is shown:

```
There are active purchase orders linked to this sale order that are
not cancelled automatically!
```

As the user is not a member of `Purchase / User`, he has no right
to read the `display_purchase_orders_alert` field which prevent
the invisible attrs to be correctly evaluated, showing the warning
in all cases even when there is no purchase order linked

This commit restrict the PO warning to the same `Purchase / User`
group to ensure that warning information is coherent

closes odoo/odoo#151968

X-original-commit: 6086d6fcc87128a72bad055a9a749c5329c6e901
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2024-01-31 17:13:58 +00:00
2023-11-02 21:02:44 +00:00
…
…

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%