Skip to content
Snippets Groups Projects
Commit c3b74e66 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

Fix: Add constant to hide an obscur feature

parent bde5a5d3
No related branches found
No related tags found
No related merge requests found
...@@ -34,7 +34,6 @@ require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.product.class.php'; ...@@ -34,7 +34,6 @@ require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.product.class.php';
$langs->load("products"); $langs->load("products");
$langs->load("suppliers"); $langs->load("suppliers");
$langs->load("bills"); $langs->load("bills");
// Charges ????
if (! empty($conf->margin->enabled)) $langs->load("margins"); if (! empty($conf->margin->enabled)) $langs->load("margins");
$id = GETPOST('id', 'int'); $id = GETPOST('id', 'int');
...@@ -383,6 +382,8 @@ if ($id || $ref) ...@@ -383,6 +382,8 @@ if ($id || $ref)
print '</tr>'; print '</tr>';
// Charges ???? // Charges ????
if ($conf->global->PRODUCT_CHARGES)
{
if (! empty($conf->margin->enabled)) if (! empty($conf->margin->enabled))
{ {
print '<tr>'; print '<tr>';
...@@ -391,6 +392,7 @@ if ($id || $ref) ...@@ -391,6 +392,7 @@ if ($id || $ref)
print '</td>'; print '</td>';
print '</tr>'; print '</tr>';
} }
}
if (is_object($hookmanager)) if (is_object($hookmanager))
{ {
...@@ -444,11 +446,17 @@ if ($id || $ref) ...@@ -444,11 +446,17 @@ if ($id || $ref)
print '<td class="liste_titre" align="right">'.$langs->trans("VATRate").'</td>'; print '<td class="liste_titre" align="right">'.$langs->trans("VATRate").'</td>';
print '<td class="liste_titre" align="right">'.$langs->trans("PriceQtyMinHT").'</td>'; print '<td class="liste_titre" align="right">'.$langs->trans("PriceQtyMinHT").'</td>';
// Charges ???? // Charges ????
if ($conf->global->PRODUCT_CHARGES)
{
if (! empty($conf->margin->enabled)) print '<td align="right">'.$langs->trans("Charges").'</td>'; if (! empty($conf->margin->enabled)) print '<td align="right">'.$langs->trans("Charges").'</td>';
}
print_liste_field_titre($langs->trans("UnitPriceHT"),$_SERVER["PHP_SELF"],"pfp.unitprice","",$param,'align="right"',$sortfield,$sortorder); print_liste_field_titre($langs->trans("UnitPriceHT"),$_SERVER["PHP_SELF"],"pfp.unitprice","",$param,'align="right"',$sortfield,$sortorder);
print '<td class="liste_titre" align="right">'.$langs->trans("DiscountQtyMin").'</td>'; print '<td class="liste_titre" align="right">'.$langs->trans("DiscountQtyMin").'</td>';
// Charges ???? // Charges ????
if ($conf->global->PRODUCT_CHARGES)
{
if (! empty($conf->margin->enabled)) print '<td align="right">'.$langs->trans("UnitCharges").'</td>'; if (! empty($conf->margin->enabled)) print '<td align="right">'.$langs->trans("UnitCharges").'</td>';
}
print '<td class="liste_titre"></td>'; print '<td class="liste_titre"></td>';
print "</tr>\n"; print "</tr>\n";
...@@ -494,12 +502,15 @@ if ($id || $ref) ...@@ -494,12 +502,15 @@ if ($id || $ref)
print '</td>'; print '</td>';
// Charges ???? // Charges ????
if ($conf->global->PRODUCT_CHARGES)
{
if (! empty($conf->margin->enabled)) if (! empty($conf->margin->enabled))
{ {
print '<td align="right">'; print '<td align="right">';
print $productfourn->fourn_charges?price($productfourn->fourn_charges):""; print $productfourn->fourn_charges?price($productfourn->fourn_charges):"";
print '</td>'; print '</td>';
} }
}
// Unit price // Unit price
print '<td align="right">'; print '<td align="right">';
...@@ -512,13 +523,16 @@ if ($id || $ref) ...@@ -512,13 +523,16 @@ if ($id || $ref)
print price2num($productfourn->fourn_remise_percent).'%'; print price2num($productfourn->fourn_remise_percent).'%';
print '</td>'; print '</td>';
// Unit Charges ??? // Charges ????
if ($conf->global->PRODUCT_CHARGES)
{
if (! empty($conf->margin->enabled)) if (! empty($conf->margin->enabled))
{ {
print '<td align="right">'; print '<td align="right">';
print $productfourn->fourn_unitcharges?price($productfourn->fourn_unitcharges) : ($productfourn->fourn_qty?price($productfourn->fourn_charges/$productfourn->fourn_qty):"&nbsp;"); print $productfourn->fourn_unitcharges?price($productfourn->fourn_unitcharges) : ($productfourn->fourn_qty?price($productfourn->fourn_charges/$productfourn->fourn_qty):"&nbsp;");
print '</td>'; print '</td>';
} }
}
if (is_object($hookmanager)) if (is_object($hookmanager))
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment