Move title column on thead from td to th
This commit is contained in:
parent
8c9e5dda1b
commit
6dc17dc5a4
@ -49,19 +49,19 @@ print '<tr class="liste_titre nodrag nodrop">';
|
||||
|
||||
// Adds a line numbering column
|
||||
if (!empty($conf->global->MAIN_VIEW_LINE_NUMBER)) {
|
||||
print '<td class="linecolnum center"> </td>';
|
||||
print '<th class="linecolnum center"> </th>';
|
||||
}
|
||||
|
||||
// Description
|
||||
print '<td class="linecoldescription">'.$langs->trans('Description').'</td>';
|
||||
print '<th class="linecoldescription">'.$langs->trans('Description').'</th>';
|
||||
|
||||
// Supplier ref
|
||||
if ($this->element == 'supplier_proposal' || $this->element == 'order_supplier' || $this->element == 'invoice_supplier' || $this->element == 'invoice_supplier_rec') {
|
||||
print '<td class="linerefsupplier maxwidth125"><span id="title_fourn_ref">'.$langs->trans("SupplierRef").'</span></td>';
|
||||
print '<th class="linerefsupplier maxwidth125"><span id="title_fourn_ref">'.$langs->trans("SupplierRef").'</span></th>';
|
||||
}
|
||||
|
||||
// VAT
|
||||
print '<td class="linecolvat right nowraponall">';
|
||||
print '<th class="linecolvat right nowraponall">';
|
||||
if (!empty($conf->global->FACTURE_LOCAL_TAX1_OPTION) || !empty($conf->global->FACTURE_LOCAL_TAX2_OPTION)) {
|
||||
print $langs->trans('Taxes');
|
||||
} else {
|
||||
@ -82,30 +82,30 @@ if (in_array($object->element, array('propal', 'commande', 'facture', 'supplier_
|
||||
print '</div>';
|
||||
}
|
||||
}
|
||||
print '</td>';
|
||||
print '</th>';
|
||||
|
||||
// Price HT
|
||||
print '<td class="linecoluht right nowraponall">'.$langs->trans('PriceUHT').'</td>';
|
||||
print '<th class="linecoluht right nowraponall">'.$langs->trans('PriceUHT').'</th>';
|
||||
|
||||
// Multicurrency
|
||||
if (isModEnabled("multicurrency") && $this->multicurrency_code != $conf->currency) {
|
||||
print '<td class="linecoluht_currency right" style="width: 80px">'.$langs->trans('PriceUHTCurrency', $this->multicurrency_code).'</td>';
|
||||
print '<th class="linecoluht_currency right" style="width: 80px">'.$langs->trans('PriceUHTCurrency', $this->multicurrency_code).'</th>';
|
||||
}
|
||||
|
||||
if ($inputalsopricewithtax) {
|
||||
print '<td class="right nowraponall">'.$langs->trans('PriceUTTC').'</td>';
|
||||
print '<th class="right nowraponall">'.$langs->trans('PriceUTTC').'</th>';
|
||||
}
|
||||
|
||||
// Qty
|
||||
print '<td class="linecolqty right">'.$langs->trans('Qty').'</td>';
|
||||
print '<th class="linecolqty right">'.$langs->trans('Qty').'</th>';
|
||||
|
||||
// Unit
|
||||
if (!empty($conf->global->PRODUCT_USE_UNITS)) {
|
||||
print '<td class="linecoluseunit left">'.$langs->trans('Unit').'</td>';
|
||||
print '<th class="linecoluseunit left">'.$langs->trans('Unit').'</th>';
|
||||
}
|
||||
|
||||
// Reduction short
|
||||
print '<td class="linecoldiscount right nowraponall">';
|
||||
print '<th class="linecoldiscount right nowraponall">';
|
||||
print $langs->trans('ReductionShort');
|
||||
|
||||
if (in_array($object->element, array('propal', 'commande', 'facture')) && $object->status == $object::STATUS_DRAFT) {
|
||||
@ -122,59 +122,59 @@ if (in_array($object->element, array('propal', 'commande', 'facture')) && $objec
|
||||
print '</div>';
|
||||
}
|
||||
}
|
||||
print '</td>';
|
||||
print '</th>';
|
||||
|
||||
// Fields for situation invoice
|
||||
if (isset($this->situation_cycle_ref) && $this->situation_cycle_ref) {
|
||||
print '<td class="linecolcycleref right">'.$langs->trans('Progress').'</td>';
|
||||
print '<td class="linecolcycleref2 right">'.$form->textwithpicto($langs->trans('TotalHT100Short'), $langs->trans('UnitPriceXQtyLessDiscount')).'</td>';
|
||||
print '<th class="linecolcycleref right">'.$langs->trans('Progress').'</th>';
|
||||
print '<th class="linecolcycleref2 right">'.$form->textwithpicto($langs->trans('TotalHT100Short'), $langs->trans('UnitPriceXQtyLessDiscount')).'</th>';
|
||||
}
|
||||
|
||||
// Purchase price
|
||||
if ($usemargins && isModEnabled('margin') && empty($user->socid)) {
|
||||
if (!empty($user->rights->margins->creer)) {
|
||||
if ($conf->global->MARGIN_TYPE == "1") {
|
||||
print '<td class="linecolmargin1 margininfos right" style="width: 80px">'.$langs->trans('BuyingPrice').'</td>';
|
||||
print '<th class="linecolmargin1 margininfos right" style="width: 80px">'.$langs->trans('BuyingPrice').'</th>';
|
||||
} else {
|
||||
print '<td class="linecolmargin1 margininfos right" style="width: 80px">'.$langs->trans('CostPrice').'</td>';
|
||||
print '<th class="linecolmargin1 margininfos right" style="width: 80px">'.$langs->trans('CostPrice').'</th>';
|
||||
}
|
||||
}
|
||||
|
||||
if (!empty($conf->global->DISPLAY_MARGIN_RATES) && $user->rights->margins->liretous) {
|
||||
print '<td class="linecolmargin2 margininfos right" style="width: 50px">'.$langs->trans('MarginRate').'</td>';
|
||||
print '<th class="linecolmargin2 margininfos right" style="width: 50px">'.$langs->trans('MarginRate').'</th>';
|
||||
}
|
||||
if (!empty($conf->global->DISPLAY_MARK_RATES) && $user->rights->margins->liretous) {
|
||||
print '<td class="linecolmargin2 margininfos right" style="width: 50px">'.$langs->trans('MarkRate').'</td>';
|
||||
print '<th class="linecolmargin2 margininfos right" style="width: 50px">'.$langs->trans('MarkRate').'</th>';
|
||||
}
|
||||
}
|
||||
|
||||
// Total HT
|
||||
print '<td class="linecolht right">'.$langs->trans('TotalHTShort').'</td>';
|
||||
print '<th class="linecolht right">'.$langs->trans('TotalHTShort').'</th>';
|
||||
|
||||
// Multicurrency
|
||||
if (isModEnabled("multicurrency") && $this->multicurrency_code != $conf->currency) {
|
||||
print '<td class="linecoltotalht_currency right">'.$langs->trans('TotalHTShortCurrency', $this->multicurrency_code).'</td>';
|
||||
print '<th class="linecoltotalht_currency right">'.$langs->trans('TotalHTShortCurrency', $this->multicurrency_code).'</th>';
|
||||
}
|
||||
|
||||
if ($outputalsopricetotalwithtax) {
|
||||
print '<td class="right" style="width: 80px">'.$langs->trans('TotalTTCShort').'</td>';
|
||||
print '<th class="right" style="width: 80px">'.$langs->trans('TotalTTCShort').'</th>';
|
||||
}
|
||||
|
||||
if (isModEnabled('asset') && $object->element == 'invoice_supplier') {
|
||||
print '<td class="linecolasset"></td>';
|
||||
print '<th class="linecolasset"></th>';
|
||||
}
|
||||
|
||||
print '<td class="linecoledit"></td>'; // No width to allow autodim
|
||||
print '<th class="linecoledit"></th>'; // No width to allow autodim
|
||||
|
||||
print '<td class="linecoldelete" style="width: 10px"></td>';
|
||||
print '<th class="linecoldelete" style="width: 10px"></th>';
|
||||
|
||||
print '<td class="linecolmove" style="width: 10px"></td>';
|
||||
print '<th class="linecolmove" style="width: 10px"></th>';
|
||||
|
||||
if ($action == 'selectlines') {
|
||||
print '<td class="linecolcheckall center">';
|
||||
print '<th class="linecolcheckall center">';
|
||||
print '<input type="checkbox" class="linecheckboxtoggle" />';
|
||||
print '<script>$(document).ready(function() {$(".linecheckboxtoggle").click(function() {var checkBoxes = $(".linecheckbox");checkBoxes.prop("checked", this.checked);})});</script>';
|
||||
print '</td>';
|
||||
print '</th>';
|
||||
}
|
||||
|
||||
print "</tr>\n";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user