2
0
forked from Wavyzz/dolibarr

ADD: Allow import and export of customer prices and price level together

This commit is contained in:
Mélina JOUM
2025-02-20 16:32:36 +01:00
parent de8a55fa9d
commit 7c20c7a7c0
3 changed files with 8 additions and 8 deletions

View File

@@ -285,7 +285,7 @@ class modService extends DolibarrModules
}
if (!isModEnabled("product")) { // We enable next import templates only if module product not already enabled (to avoid duplicate entries)
if (getDolGlobalString('PRODUIT_MULTIPRICES')) {
if (getDolGlobalString('PRODUIT_MULTIPRICES') || getDolGlobalString('PRODUIT_CUSTOMER_PRICES_AND_MULTIPRICES')) {
// Exports product multiprice
$r++;
$this->export_code[$r] = $this->rights_class.'_'.$r;
@@ -319,7 +319,7 @@ class modService extends DolibarrModules
$this->export_sql_end[$r] .= ' WHERE p.entity IN ('.getEntity('product').')'; // For product and service profile
}
if (getDolGlobalString('PRODUIT_CUSTOMER_PRICES')) {
if (getDolGlobalString('PRODUIT_CUSTOMER_PRICES') || getDolGlobalString('PRODUIT_CUSTOMER_PRICES_AND_MULTIPRICES')) {
// Exports product multiprice
$r++;
$this->export_code[$r] = $this->rights_class.'_'.$r;
@@ -801,7 +801,7 @@ class modService extends DolibarrModules
$this->import_updatekeys_array[$r] = array('sp.fk_product' => 'ProductOrService', 'sp.ref_fourn' => 'SupplierRef', 'sp.fk_soc' => 'Supplier');
}
if (getDolGlobalString('PRODUIT_MULTIPRICES')) {
if (getDolGlobalString('PRODUIT_MULTIPRICES') || getDolGlobalString('PRODUIT_CUSTOMER_PRICES_AND_MULTIPRICES')) {
// Import products multiprices
$r++;
$this->import_code[$r] = $this->rights_class.'_multiprice';