NEW : Add column "Total HT" to products array on document creation card

This commit is contained in:
Gauthier PC portable 024 2022-01-10 17:02:15 +01:00
parent b23b82bd6f
commit 04cc0a0480
2 changed files with 3 additions and 0 deletions

View File

@ -4441,6 +4441,7 @@ abstract class CommonObject
print '<td class="left">'.$langs->trans('Unit').'</td>';
}
print '<td class="right">'.$langs->trans('ReductionShort').'</td>';
print '<td class="right">'.$langs->trans('TotalHT').'</td>';
print '<td class="center">'.$form->showCheckAddButtons('checkforselect', 1).'</td>';
print '</tr>';
$i = 0;
@ -4593,6 +4594,7 @@ abstract class CommonObject
if (!empty($line->vat_src_code) && !preg_match('/\(/', $this->tpl['vat_rate'])) $this->tpl['vat_rate'] .= ' ('.$line->vat_src_code.')';
$this->tpl['price'] = price($line->subprice);
$this->tpl['total_ht'] = price($line->total_ht);
$this->tpl['multicurrency_price'] = price($line->multicurrency_subprice);
$this->tpl['qty'] = (($line->info_bits & 2) != 2) ? $line->qty : '&nbsp;';
if ($conf->global->PRODUCT_USE_UNITS) $this->tpl['unit'] = $langs->transnoentities($line->getLabelOfUnit('long'));

View File

@ -40,6 +40,7 @@ if ($conf->global->PRODUCT_USE_UNITS)
print '<td class="left">'.$langs->trans($this->tpl['unit']).'</td>';
print '<td class="right">'.$this->tpl['remise_percent'].'</td>';
print '<td class="right">'.$this->tpl['total_ht'].'</td>';
$selected = 1;
if (!empty($selectedLines) && !in_array($this->tpl['id'], $selectedLines)) $selected = 0;