From 71acce0afb2473b652d9abd6b8be3c402ee5891a Mon Sep 17 00:00:00 2001 From: Christophe Battarel Date: Tue, 25 Mar 2025 19:33:30 +0100 Subject: [PATCH] NEW : add new permissions to read supplier prices (#33598) * add new permissions to read supplier prices * Update modProduct.class.php * Update modProduct.class.php * Update modService.class.php --------- Co-authored-by: Christophe Battarel Co-authored-by: Laurent Destailleur --- htdocs/core/modules/modProduct.class.php | 8 ++++++++ htdocs/core/modules/modService.class.php | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/htdocs/core/modules/modProduct.class.php b/htdocs/core/modules/modProduct.class.php index e0ac6624281..c23a4ebe421 100644 --- a/htdocs/core/modules/modProduct.class.php +++ b/htdocs/core/modules/modProduct.class.php @@ -138,6 +138,14 @@ class modProduct extends DolibarrModules $this->rights[$r][5] = 'read_prices'; $r++; + $this->rights[$r][0] = 35; // id de la permission + $this->rights[$r][1] = 'Read supplier prices'; // libelle de la permission + $this->rights[$r][2] = 'w'; // type de la permission (deprecated) + $this->rights[$r][3] = 0; // La permission est-elle une permission par default + $this->rights[$r][4] = 'product_advance'; + $this->rights[$r][5] = 'read_supplier_prices'; + $r++; + $this->rights[$r][0] = 34; // id de la permission $this->rights[$r][1] = 'Delete products'; // libelle de la permission $this->rights[$r][2] = 'd'; // type de la permission (deprecated) diff --git a/htdocs/core/modules/modService.class.php b/htdocs/core/modules/modService.class.php index 498509861a7..d7e21bad862 100644 --- a/htdocs/core/modules/modService.class.php +++ b/htdocs/core/modules/modService.class.php @@ -110,6 +110,14 @@ class modService extends DolibarrModules $this->rights[$r][5] = 'read_prices'; $r++; + $this->rights[$r][0] = 535; // id de la permission + $this->rights[$r][1] = 'Read supplier prices'; // libelle de la permission + $this->rights[$r][2] = 'w'; // type de la permission (deprecated) + $this->rights[$r][3] = 0; // La permission est-elle une permission par default + $this->rights[$r][4] = 'product_advance'; + $this->rights[$r][5] = 'read_supplier_prices'; + $r++; + $this->rights[$r][0] = 534; // id de la permission $this->rights[$r][1] = 'Delete les services'; // libelle de la permission $this->rights[$r][2] = 'd'; // type de la permission (deprecated)