diff --git a/htdocs/langs/en_US/margins.lang b/htdocs/langs/en_US/margins.lang index 680a303a245..e8d5fed1af9 100644 --- a/htdocs/langs/en_US/margins.lang +++ b/htdocs/langs/en_US/margins.lang @@ -18,12 +18,11 @@ MarginDetails=Margin details ProductMargins=Product margins CustomerMargins=Customer margins -AgentMargins=Agent margins +SalesRepresentativeMargins=Sales representative margins ProductService=Product or Service AllProducts=All products and services ChooseProduct/Service=Choose product or service -CommercialAgent=Commercial agent StartDate=Start date EndDate=End date diff --git a/htdocs/margin/agentMargins.php b/htdocs/margin/agentMargins.php index 5bfa61cc7b6..b7c5b8d4701 100644 --- a/htdocs/margin/agentMargins.php +++ b/htdocs/margin/agentMargins.php @@ -84,7 +84,7 @@ dol_fiche_head($head, 'agentMargins', $titre, 0, $picto); print '
'; print ''; -print ''; +print ''; print ''; @@ -155,7 +155,7 @@ if ($result) if ($agentid > 0) print_liste_field_titre($langs->trans("Customer"),$_SERVER["PHP_SELF"],"s.nom","","&agentid=".$agentid,'',$sortfield,$sortorder); else - print_liste_field_titre($langs->trans("CommercialAgent"),$_SERVER["PHP_SELF"],"u.lastname","","&agentid=".$agentid,'',$sortfield,$sortorder); + print_liste_field_titre($langs->trans("SalesRepresentative"),$_SERVER["PHP_SELF"],"u.lastname","","&agentid=".$agentid,'',$sortfield,$sortorder); print_liste_field_titre($langs->trans("SellingPrice"),$_SERVER["PHP_SELF"],"selling_price","","&agentid=".$agentid,'align="right"',$sortfield,$sortorder); print_liste_field_titre($langs->trans("BuyingPrice"),$_SERVER["PHP_SELF"],"buying_price","","&agentid=".$agentid,'align="right"',$sortfield,$sortorder); diff --git a/htdocs/margin/lib/margins.lib.php b/htdocs/margin/lib/margins.lib.php index 2dadd9500f2..a47b0a5d21f 100644 --- a/htdocs/margin/lib/margins.lib.php +++ b/htdocs/margin/lib/margins.lib.php @@ -73,7 +73,7 @@ function marges_prepare_head() $h++; $head[$h][0] = DOL_URL_ROOT."/margin/agentMargins.php"; - $head[$h][1] = $langs->trans("AgentMargins"); + $head[$h][1] = $langs->trans("SalesRepresentativeMargins"); $head[$h][2] = 'agentMargins'; $h++; @@ -102,7 +102,7 @@ function getMarginInfos($pvht, $remise_percent, $tva_tx, $localtax1_tx, $localta if ($fk_pa > 0) { require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.product.class.php'; $product = new ProductFournisseur($db); - if ($product->fetch_product_fournisseur_price($fk_pa)) + if ($product->fetch_product_fournisseur_price($fk_pa)) { $paht_ret = $product->fourn_unitprice * (1 - $product->fourn_remise_percent / 100); if ($conf->global->MARGIN_TYPE == "2" && $product->fourn_unitcharges > 0) @@ -113,11 +113,11 @@ function getMarginInfos($pvht, $remise_percent, $tva_tx, $localtax1_tx, $localta $paht_ret = $paht; } } - else + else { $paht_ret = $paht; } - + // Calculate selling unit price including line discount // We don't use calculate_price, because this function is dedicated to calculation of total with accuracy of total. We need an accuracy of a unit price. // Also we must not apply rounding on non decimal rule defined by option MAIN_ROUNDING_RULE_TOT
'.$langs->trans('CommercialAgent').'
'.$langs->trans('SalesRepresentative').''; print $form->select_dolusers($agentid,'agentid',1); print '