';
print img_object('','generic').' ';
diff --git a/htdocs/compta/salaries/class/paymentsalary.class.php b/htdocs/compta/salaries/class/paymentsalary.class.php
index 0e4f1210419..ecf4b16212b 100644
--- a/htdocs/compta/salaries/class/paymentsalary.class.php
+++ b/htdocs/compta/salaries/class/paymentsalary.class.php
@@ -359,20 +359,12 @@ class PaymentSalary extends CommonObject
$result = $this->db->query($sql);
if ($result)
{
- $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX."payment_salary"); // TODO should be called payment_salary
+ $ok=1;
- // Start triggers
- include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
- $interface=new Interfaces($this->db);
- $result=$interface->run_triggers('PAYMENT_SALARY_CREATE',$this,$user,$langs,$conf);
- if ($result < 0) {
- $error++; $this->errors=$interface->errors;
- }
- // End triggers
+ $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX."payment_salary");
if ($this->id > 0)
{
- $ok=1;
if (! empty($conf->banque->enabled) && ! empty($this->amount))
{
// Insert into llx_bank
@@ -406,42 +398,53 @@ class PaymentSalary extends CommonObject
$ok=0;
}
- // Add link 'payment_salary' in bank_url between payment and bank transaction
- $url=DOL_URL_ROOT.'/compta/salaries/fiche.php?id=';
+ if ($ok)
+ {
+ // Add link 'payment_salary' in bank_url between payment and bank transaction
+ $url=DOL_URL_ROOT.'/compta/salaries/fiche.php?id=';
+
+ $result=$acc->add_url_line($bank_line_id, $this->id, $url, "(SalaryPayment)", "payment_salary");
+ if ($result <= 0)
+ {
+ $this->error=$acc->error;
+ $ok=0;
+ }
+ }
+
+ $fuser=new User($this->db);
+ $fuser->fetch($this->fk_user);
+
+ // Add link 'user' in bank_url between operation and bank transaction
+ $result=$acc->add_url_line(
+ $bank_line_id,
+ $this->fk_user,
+ DOL_URL_ROOT.'/user/fiche.php?id=',
+ $langs->trans("SalaryPayment").' '.$fuser->getFullName($langs).' '.dol_print_date($this->datesp,'dayrfc').' '.dol_print_date($this->dateep,'dayrfc'),
+ '(User)',
+ 'user'
+ );
- $result=$acc->add_url_line($bank_line_id, $this->id, $url, "(SalaryPayment)", "payment_salary");
if ($result <= 0)
{
$this->error=$acc->error;
$ok=0;
}
-
- // Add link 'user' in bank_url between operation and bank transaction
- $linkaddedforthirdparty=array();
- foreach ($this->amounts as $key => $value)
- {
- $sal = new PaymentSalary($this->db);
-
- $sal->fetch($key);
- $sal->fetch_user($this->fk_user);
-
- if (! in_array($sal->user->id,$linkaddedforthirdparty)) // Not yet done for this thirdparty
- {
- $result=$acc->add_url_line(
- $bank_line_id,
- $sal->user->id,
- DOL_URL_ROOT.'/user/fiche.php?id=',
- $sal->user->lastname,
- 'user'
- );
-
- if ($result <= 0) dol_print_error($this->db);
- $linkaddedforthirdparty[$sal->user->id]=$sal->user->id; // Mark as done for this thirdparty
- }
-
- }
}
+ // Start triggers
+ include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
+ $interface=new Interfaces($this->db);
+ $result=$interface->run_triggers('PAYMENT_SALARY_CREATE',$this,$user,$langs,$conf);
+ if ($result < 0) {
+ $error++; $this->errors=$interface->errors;
+ }
+ // End triggers
+
+ }
+ else $ok=0;
+
+ if ($ok)
+ {
if ($ok)
{
$this->db->commit();
diff --git a/htdocs/compta/salaries/fiche.php b/htdocs/compta/salaries/fiche.php
index b4816b10c61..ae74344ccf8 100644
--- a/htdocs/compta/salaries/fiche.php
+++ b/htdocs/compta/salaries/fiche.php
@@ -78,6 +78,7 @@ if ($action == 'add' && $_POST["cancel"] <> $langs->trans("Cancel"))
$sal->note=GETPOST("note");
$sal->type_payment=GETPOST("paymenttype");
$sal->num_payment=GETPOST("num_payment");
+ $sal->fk_user_creat=$user->id;
if (empty($datep) || empty($datesp) || empty($dateep))
{
@@ -215,11 +216,11 @@ if ($action == 'create')
print "";
print '| '.$langs->trans("DatePayment").' | ';
- print $form->select_date((empty($datep)?-1:$datep),"datep",'','','','add');
+ print $form->select_date((empty($datep)?-1:$datep),"datep",'','','','add',1,1);
print ' |
';
print '| '.$langs->trans("DateValue").' | ';
- print $form->select_date((empty($datev)?-1:$datev),"datev",'','','','add');
+ print $form->select_date((empty($datev)?-1:$datev),"datev",'','','','add',1,1);
print ' |
';
// Employee
diff --git a/htdocs/core/modules/modProduct.class.php b/htdocs/core/modules/modProduct.class.php
index 19d9ca50031..dbdfed9003b 100644
--- a/htdocs/core/modules/modProduct.class.php
+++ b/htdocs/core/modules/modProduct.class.php
@@ -206,6 +206,32 @@ class modProduct extends DolibarrModules
if (! empty($conf->fournisseur->enabled)) $this->export_sql_end[$r] .=' LEFT JOIN '.MAIN_DB_PREFIX.'product_fournisseur_price as pf ON pf.fk_product = p.rowid LEFT JOIN '.MAIN_DB_PREFIX.'societe s ON s.rowid = pf.fk_soc';
$this->export_sql_end[$r] .=' WHERE p.fk_product_type = 0 AND p.entity IN ('.getEntity("product", 1).')';
+ if (! empty($conf->global->PRODUIT_MULTIPRICES))
+ {
+ // Exports product multiprice
+ $r++;
+ $this->export_code[$r]=$this->rights_class.'_'.$key;
+ $this->export_label[$r]="ProductsMultiPrice"; // Translation key (used only if key ExportDataset_xxx_z not found)
+ $this->export_permission[$r]=array(array("produit","export"));
+ $this->export_fields_array[$r]=array('p.rowid'=>"Id",'p.ref'=>"Ref",
+ 'pr.price_base_type'=>"PriceLevelPriceBase",'pr.price_level'=>"PriceLevel",
+ 'pr.price'=>"PriceLevelUnitPriceHT",'pr.price_ttc'=>"PriceLevelUnitPriceTTC",
+ 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
+ 'pr.tva_tx'=>'PriceLevelVATRate',
+ 'pr.date_price'=>'DateCreation');
+ $this->export_entities_array[$r]=array('p.rowid'=>"product",'p.ref'=>"product",
+ 'pr.price_base_type'=>"product",'pr.price_level'=>"product",'pr.price'=>"product",
+ 'pr.price_ttc'=>"product",
+ 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
+ 'pr.tva_tx'=>'product',
+ 'pr.date_price'=>"product");
+ $this->export_sql_start[$r]='SELECT DISTINCT ';
+ $this->export_sql_end[$r] =' FROM '.MAIN_DB_PREFIX.'product as p';
+ $this->export_sql_end[$r] .=' LEFT JOIN '.MAIN_DB_PREFIX.'product_price as pr ON p.rowid = pr.fk_product';
+ $this->export_sql_end[$r] .=' WHERE p.fk_product_type = 0 AND p.entity IN ('.getEntity("product", 1).')';
+ }
+
+
// Imports
//--------
@@ -239,15 +265,15 @@ class modProduct extends DolibarrModules
if (! empty($conf->fournisseur->enabled))
{
- // Import product suppliers
+ // Import suppliers prices (note: this code is duplicated into module service)
$r++;
- $this->import_code[$r]=$this->rights_class.'_'.$r;
- $this->import_label[$r]="SuppliersPrices"; // Translation key
- $this->import_icon[$r]='product';
+ $this->import_code[$r]=$this->rights_class.'_supplierprices';
+ $this->import_label[$r]="SuppliersPricesOfProductsOrServices"; // Translation key
+ $this->import_icon[$r]=$this->picto;
$this->import_entities_array[$r]=array(); // We define here only fields that use another icon that the one defined into import_icon
$this->import_tables_array[$r]=array('sp'=>MAIN_DB_PREFIX.'product_fournisseur_price');
$this->import_tables_creator_array[$r]=array('sp'=>'fk_user');
- $this->import_fields_array[$r]=array('sp.fk_product'=>"Product*",
+ $this->import_fields_array[$r]=array('sp.fk_product'=>"ProductOrService*",
'sp.fk_soc'=>"Supplier*", 'sp.ref_fourn'=>'SupplierRef', 'sp.quantity'=>"QtyMin*", 'sp.tva_tx'=>'VATRate',
'sp.price'=>"PriceQtyMinHT*",
'sp.unitprice'=>'UnitPriceHT*', // TODO Make this file not required and calculate it from price and qty
@@ -266,55 +292,29 @@ class modProduct extends DolibarrModules
);
}
- if (! empty($conf->global->PRODUIT_MULTIPRICES)) {
- // Exports product multiprice
- //--------
- $r++;
- $this->export_code[$r]=$this->rights_class.'_'.$r;
- $this->export_label[$r]="ProductsMultiPrice"; // Translation key (used only if key ExportDataset_xxx_z not found)
- $this->export_permission[$r]=array(array("produit","export"));
- $this->export_fields_array[$r]=array('p.rowid'=>"Id",'p.ref'=>"Ref",
- 'pr.price_base_type'=>"PriceLevelPriceBase",'pr.price_level'=>"PriceLevel",
- 'pr.price'=>"PriceLevelUnitPriceHT",'pr.price_ttc'=>"PriceLevelUnitPriceTTC",
- 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
- 'pr.tva_tx'=>'PriceLevelVATRate',
- 'pr.date_price'=>'DateCreation');
- $this->export_entities_array[$r]=array('p.rowid'=>"product",'p.ref'=>"product",
- 'pr.price_base_type'=>"product",'pr.price_level'=>"product",'pr.price'=>"product",
- 'pr.price_ttc'=>"product",
- 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
- 'pr.tva_tx'=>'product',
- 'pr.date_price'=>"product");
- $this->export_sql_start[$r]='SELECT DISTINCT ';
- $this->export_sql_end[$r] =' FROM '.MAIN_DB_PREFIX.'product as p';
- $this->export_sql_end[$r] .=' LEFT JOIN '.MAIN_DB_PREFIX.'product_price as pr ON p.rowid = pr.fk_product';
- $this->export_sql_end[$r] .=' WHERE p.fk_product_type = 0 AND p.entity IN ('.getEntity("product", 1).')';
-
-
- // Import product multiprice
- //--------
- $r=0;
-
- $r++;
- $this->import_code[$r]=$this->rights_class.'_'.$r;
- $this->import_label[$r]="ProductsMultiPrice"; // Translation key
- $this->import_icon[$r]=$this->picto;
- $this->import_entities_array[$r]=array(); // We define here only fields that use another icon that the one defined into import_icon
- $this->import_tables_array[$r]=array('pr'=>MAIN_DB_PREFIX.'product_price');
- $this->import_tables_creator_array[$r]=array('pr'=>'fk_user_author'); // Fields to store import user id
- $this->import_fields_array[$r]=array('pr.fk_product'=>"ProductRowid*",
- 'pr.price_base_type'=>"PriceLevelPriceBase",'pr.price_level'=>"PriceLevel",
- 'pr.price'=>"PriceLevelUnitPriceHT",'pr.price_ttc'=>"PriceLevelUnitPriceTTC",
- 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
- 'pr.tva_tx'=>'PriceLevelVATRate',
- 'pr.date_price'=>'DateCreation*');
- $this->import_regex_array[$r]=array('pr.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$');
- $this->import_examplevalues_array[$r]=array('pr.fk_product'=>"1",
- 'pr.price_base_type'=>"HT",'pr.price_level'=>"1",
- 'pr.price'=>"100",'pr.price_ttc'=>"110",
- 'pr.price_min'=>"100",'pr.price_min_ttc'=>"110",
- 'pr.tva_tx'=>'19.6',
- 'pr.date_price'=>'2013-04-10');
+ if (! empty($conf->global->PRODUIT_MULTIPRICES))
+ {
+ // Import product multiprice
+ $r++;
+ $this->import_code[$r]=$this->rights_class.'_multiprice';
+ $this->import_label[$r]="ProductsOrServiceMultiPrice"; // Translation key
+ $this->import_icon[$r]=$this->picto;
+ $this->import_entities_array[$r]=array(); // We define here only fields that use another icon that the one defined into import_icon
+ $this->import_tables_array[$r]=array('pr'=>MAIN_DB_PREFIX.'product_price');
+ $this->import_tables_creator_array[$r]=array('pr'=>'fk_user_author'); // Fields to store import user id
+ $this->import_fields_array[$r]=array('pr.fk_product'=>"ProductRowid*",
+ 'pr.price_base_type'=>"PriceLevelPriceBase",'pr.price_level'=>"PriceLevel",
+ 'pr.price'=>"PriceLevelUnitPriceHT",'pr.price_ttc'=>"PriceLevelUnitPriceTTC",
+ 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
+ 'pr.tva_tx'=>'PriceLevelVATRate',
+ 'pr.date_price'=>'DateCreation*');
+ $this->import_regex_array[$r]=array('pr.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$');
+ $this->import_examplevalues_array[$r]=array('pr.fk_product'=>"1",
+ 'pr.price_base_type'=>"HT",'pr.price_level'=>"1",
+ 'pr.price'=>"100",'pr.price_ttc'=>"110",
+ 'pr.price_min'=>"100",'pr.price_min_ttc'=>"110",
+ 'pr.tva_tx'=>'19.6',
+ 'pr.date_price'=>'2013-04-10');
}
}
diff --git a/htdocs/core/modules/modService.class.php b/htdocs/core/modules/modService.class.php
index 2309bd7f06b..a998f41298e 100644
--- a/htdocs/core/modules/modService.class.php
+++ b/htdocs/core/modules/modService.class.php
@@ -168,6 +168,35 @@ class modService extends DolibarrModules
$this->export_sql_end[$r] .=' WHERE p.fk_product_type = 1 AND p.entity IN ('.getEntity("product", 1).')';
+ if (empty($conf->product->enabled)) // We enable next import templates only if module product not already enabled (to avoid duplicate entries)
+ {
+ if (! empty($conf->global->PRODUIT_MULTIPRICES))
+ {
+ // Exports product multiprice
+ $r++;
+ $this->export_code[$r]=$this->rights_class.'_'.$r;
+ $this->export_label[$r]="ProductsMultiPrice"; // Translation key (used only if key ExportDataset_xxx_z not found)
+ $this->export_permission[$r]=array(array("produit","export"));
+ $this->export_fields_array[$r]=array('p.rowid'=>"Id",'p.ref'=>"Ref",
+ 'pr.price_base_type'=>"PriceLevelPriceBase",'pr.price_level'=>"PriceLevel",
+ 'pr.price'=>"PriceLevelUnitPriceHT",'pr.price_ttc'=>"PriceLevelUnitPriceTTC",
+ 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
+ 'pr.tva_tx'=>'PriceLevelVATRate',
+ 'pr.date_price'=>'DateCreation');
+ $this->export_entities_array[$r]=array('p.rowid'=>"product",'p.ref'=>"product",
+ 'pr.price_base_type'=>"product",'pr.price_level'=>"product",'pr.price'=>"product",
+ 'pr.price_ttc'=>"product",
+ 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
+ 'pr.tva_tx'=>'product',
+ 'pr.date_price'=>"product");
+ $this->export_sql_start[$r]='SELECT DISTINCT ';
+ $this->export_sql_end[$r] =' FROM '.MAIN_DB_PREFIX.'product as p';
+ $this->export_sql_end[$r] .=' LEFT JOIN '.MAIN_DB_PREFIX.'product_price as pr ON p.rowid = pr.fk_product';
+ $this->export_sql_end[$r] .=' WHERE p.fk_product_type = 0 AND p.entity IN ('.getEntity("product", 1).')';
+ }
+ }
+
+
// Imports
//--------
$r=0;
@@ -196,6 +225,64 @@ class modService extends DolibarrModules
$this->import_fieldshidden_array[$r]=array('extra.fk_object'=>'lastrowid-'.MAIN_DB_PREFIX.'product'); // aliastable.field => ('user->id' or 'lastrowid-'.tableparent)
$this->import_regex_array[$r]=array('p.ref'=>'[^ ]','p.tosell'=>'^[0|1]$','p.tobuy'=>'^[0|1]$','p.fk_product_type'=>'^[0|1]$','p.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$');
$this->import_examplevalues_array[$r]=array('p.ref'=>"PR123456",'p.label'=>"My product",'p.description'=>"This is a description example for record",'p.note'=>"Some note",'p.price'=>"100",'p.price_ttc'=>"110",'p.tva_tx'=>'10','p.tosell'=>"0 or 1",'p.tobuy'=>"0 or 1",'p.fk_product_type'=>"0 for product/1 for service",'p.finished'=>'','p.duration'=>"1y",'p.datec'=>'2008-12-31');
+
+
+ if (empty($conf->product->enabled)) // We enable next import templates only if module product not already enabled (to avoid duplicate entries)
+ {
+ if (! empty($conf->fournisseur->enabled))
+ {
+ // Import suppliers prices (note: this code is duplicated into module product)
+ $r++;
+ $this->import_code[$r]=$this->rights_class.'_supplierprices';
+ $this->import_label[$r]="SuppliersPricesOfProductsOrServices"; // Translation key
+ $this->import_icon[$r]=$this->picto;
+ $this->import_entities_array[$r]=array(); // We define here only fields that use another icon that the one defined into import_icon
+ $this->import_tables_array[$r]=array('sp'=>MAIN_DB_PREFIX.'product_fournisseur_price');
+ $this->import_tables_creator_array[$r]=array('sp'=>'fk_user');
+ $this->import_fields_array[$r]=array('sp.fk_product'=>"ProductOrService*",
+ 'sp.fk_soc'=>"Supplier*", 'sp.ref_fourn'=>'SupplierRef', 'sp.quantity'=>"QtyMin*", 'sp.tva_tx'=>'VATRate',
+ 'sp.price'=>"PriceQtyMinHT*",
+ 'sp.unitprice'=>'UnitPriceHT*', // TODO Make this file not required and calculate it from price and qty
+ 'sp.remise_percent'=>'DiscountQtyMin'
+ );
+
+ $this->import_convertvalue_array[$r]=array(
+ 'sp.fk_soc'=>array('rule'=>'fetchidfromref','classfile'=>'/societe/class/societe.class.php','class'=>'Societe','method'=>'fetch','element'=>'ThirdParty'),
+ 'sp.fk_product'=>array('rule'=>'fetchidfromref','classfile'=>'/product/class/product.class.php','class'=>'Product','method'=>'fetch','element'=>'Product')
+ );
+ $this->import_examplevalues_array[$r]=array('sp.fk_product'=>"PREF123456",
+ 'sp.fk_soc'=>"My Supplier",'sp.ref_fourn'=>"SupplierRef", 'sp.quantity'=>"1", 'sp.tva_tx'=>'21',
+ 'sp.price'=>"50",
+ 'sp.unitprice'=>'50',
+ 'sp.remise_percent'=>'0'
+ );
+ }
+
+ if (! empty($conf->global->PRODUIT_MULTIPRICES))
+ {
+ // Import product multiprice
+ $r++;
+ $this->import_code[$r]=$this->rights_class.'_multiprice';
+ $this->import_label[$r]="ProductsOrServiceMultiPrice"; // Translation key
+ $this->import_icon[$r]=$this->picto;
+ $this->import_entities_array[$r]=array(); // We define here only fields that use another icon that the one defined into import_icon
+ $this->import_tables_array[$r]=array('pr'=>MAIN_DB_PREFIX.'product_price');
+ $this->import_tables_creator_array[$r]=array('pr'=>'fk_user_author'); // Fields to store import user id
+ $this->import_fields_array[$r]=array('pr.fk_product'=>"ProductRowid*",
+ 'pr.price_base_type'=>"PriceLevelPriceBase",'pr.price_level'=>"PriceLevel",
+ 'pr.price'=>"PriceLevelUnitPriceHT",'pr.price_ttc'=>"PriceLevelUnitPriceTTC",
+ 'pr.price_min'=>"MinPriceLevelUnitPriceHT",'pr.price_min_ttc'=>"MinPriceLevelUnitPriceTTC",
+ 'pr.tva_tx'=>'PriceLevelVATRate',
+ 'pr.date_price'=>'DateCreation*');
+ $this->import_regex_array[$r]=array('pr.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$');
+ $this->import_examplevalues_array[$r]=array('pr.fk_product'=>"1",
+ 'pr.price_base_type'=>"HT",'pr.price_level'=>"1",
+ 'pr.price'=>"100",'pr.price_ttc'=>"110",
+ 'pr.price_min'=>"100",'pr.price_min_ttc'=>"110",
+ 'pr.tva_tx'=>'19.6',
+ 'pr.date_price'=>'2013-04-10');
+ }
+ }
}
diff --git a/htdocs/imports/import.php b/htdocs/imports/import.php
index b7fc38eaa4c..41a82de36b1 100644
--- a/htdocs/imports/import.php
+++ b/htdocs/imports/import.php
@@ -352,10 +352,13 @@ if ($step == 1 || ! $datatoimport)
{
foreach ($objimport->array_import_code as $key => $value)
{
+ //var_dump($objimport->array_import_code[$key]);
$val=!$val;
print '| ';
- //print img_object($objimport->array_import_module[$key]->getName(),$import->array_import_module[$key]->picto).' ';
- print $objimport->array_import_module[$key]->getName();
+ $titleofmodule=$objimport->array_import_module[$key]->getName();
+ // Special cas for import common to module/services
+ if (in_array($objimport->array_import_code[$key], array('produit_supplierprices','produit_multiprice'))) $titleofmodule=$langs->trans("ProductOrService");
+ print $titleofmodule;
print ' | ';
//print $value;
print img_object($objimport->array_import_module[$key]->getName(),$objimport->array_import_icon[$key]).' ';
@@ -407,8 +410,10 @@ if ($step == 2 && $datatoimport)
// Module
print ' |
| '.$langs->trans("Module").' | ';
print '';
- //print img_object($objimport->array_import_module[0]->getName(),$objimport->array_import_module[0]->picto).' ';
- print $objimport->array_import_module[0]->getName();
+ $titleofmodule=$objimport->array_import_module[0]->getName();
+ // Special cas for import common to module/services
+ if (in_array($objimport->array_import_code[0], array('produit_supplierprices','produit_multiprice'))) $titleofmodule=$langs->trans("ProductOrService");
+ print $titleofmodule;
print ' |
';
// Lot de donnees a importer
@@ -490,8 +495,10 @@ if ($step == 3 && $datatoimport)
// Module
print '| '.$langs->trans("Module").' | ';
print '';
- //print img_object($objimport->array_import_module[0]->getName(),$objimport->array_import_module[0]->picto).' ';
- print $objimport->array_import_module[0]->getName();
+ $titleofmodule=$objimport->array_import_module[0]->getName();
+ // Special cas for import common to module/services
+ if (in_array($objimport->array_import_code[0], array('produit_supplierprices','produit_multiprice'))) $titleofmodule=$langs->trans("ProductOrService");
+ print $titleofmodule;
print ' |
';
// Lot de donnees a importer
@@ -695,8 +702,10 @@ if ($step == 4 && $datatoimport)
// Module
print '| '.$langs->trans("Module").' | ';
print '';
- //print img_object($objimport->array_import_module[0]->getName(),$objimport->array_import_module[0]->picto).' ';
- print $objimport->array_import_module[0]->getName();
+ $titleofmodule=$objimport->array_import_module[0]->getName();
+ // Special cas for import common to module/services
+ if (in_array($objimport->array_import_code[0], array('produit_supplierprices','produit_multiprice'))) $titleofmodule=$langs->trans("ProductOrService");
+ print $titleofmodule;
print ' |
';
// Lot de donnees a importer
@@ -1144,8 +1153,10 @@ if ($step == 5 && $datatoimport)
// Module
print '| '.$langs->trans("Module").' | ';
print '';
- //print img_object($objimport->array_import_module[0]->getName(),$objimport->array_import_module[0]->picto).' ';
- print $objimport->array_import_module[0]->getName();
+ $titleofmodule=$objimport->array_import_module[0]->getName();
+ // Special cas for import common to module/services
+ if (in_array($objimport->array_import_code[0], array('produit_supplierprices','produit_multiprice'))) $titleofmodule=$langs->trans("ProductOrService");
+ print $titleofmodule;
print ' |
';
// Lot de donnees a importer
@@ -1487,8 +1498,10 @@ if ($step == 6 && $datatoimport)
// Module
print '| '.$langs->trans("Module").' | ';
print '';
- //print img_object($objimport->array_import_module[0]->getName(),$objimport->array_import_module[0]->picto).' ';
- print $objimport->array_import_module[0]->getName();
+ $titleofmodule=$objimport->array_import_module[0]->getName();
+ // Special cas for import common to module/services
+ if (in_array($objimport->array_import_code[0], array('produit_supplierprices','produit_multiprice'))) $titleofmodule=$langs->trans("ProductOrService");
+ print $titleofmodule;
print ' |
';
// Lot de donnees a importer
diff --git a/htdocs/langs/en_US/products.lang b/htdocs/langs/en_US/products.lang
index f7696ea8ecf..fea1d7afbb6 100644
--- a/htdocs/langs/en_US/products.lang
+++ b/htdocs/langs/en_US/products.lang
@@ -179,6 +179,7 @@ ProductIsUsed=This product is used
NewRefForClone=Ref. of new product/service
CustomerPrices=Customers prices
SuppliersPrices=Suppliers prices
+SuppliersPricesOfProductsOrServices=Suppliers prices (of products or services)
CustomCode=Customs code
CountryOrigin=Origin country
HiddenIntoCombo=Hidden into select lists
@@ -208,6 +209,7 @@ CostPmpHT=Net total VWAP
ProductUsedForBuild=Auto consumed by production
ProductBuilded=Production completed
ProductsMultiPrice=Product multi-price
+ProductsOrServiceMultiPrice=Customers prices (of products or services, multi-prices)
ProductSellByQuarterHT=Products turnover quarterly VWAP
ServiceSellByQuarterHT=Services turnover quarterly VWAP
Quarter1=1st. Quarter