Fix warning on vat possible anomaly.
This commit is contained in:
parent
f086fa6c40
commit
8954f7415b
@ -661,11 +661,11 @@ if ($result) {
|
|||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
// Vat rate
|
// Vat rate
|
||||||
$code_vat_differ='';
|
$code_vat_differ = '';
|
||||||
if ($product_static->tva_tx !== $facture_static_det->tva_tx && ! empty($facture_static_det->tva_tx)) { // Note: having a vat rate of 0 is often the normal case when sells is intra b2b or to export
|
if ($product_static->tva_tx !== $facture_static_det->tva_tx && !empty($product_static->tva_tx) && !empty($facture_static_det->tva_tx)) { // Note: having a vat rate of 0 is often the normal case when sells is intra b2b or to export
|
||||||
$code_vat_differ = 'font-weight:bold; text-decoration:blink; color:red';
|
$code_vat_differ = 'warning bold';
|
||||||
}
|
}
|
||||||
print '<td style="'.$code_vat_differ.'" class="right">';
|
print '<td class="right'.($code_vat_differ?' '.$code_vat_differ:'').'">';
|
||||||
print vatrate($facture_static_det->tva_tx.($facture_static_det->vat_src_code ? ' ('.$facture_static_det->vat_src_code.')' : ''));
|
print vatrate($facture_static_det->tva_tx.($facture_static_det->vat_src_code ? ' ('.$facture_static_det->vat_src_code.')' : ''));
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
|
|||||||
@ -654,11 +654,11 @@ if ($result) {
|
|||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
// Vat rate
|
// Vat rate
|
||||||
$code_vat_differ='';
|
$code_vat_differ = '';
|
||||||
if ($objp->vat_tx_l != $objp->vat_tx_p && ! empty($objp->vat_tx_l)) { // Note: having a vat rate of 0 is often the normal case when sells is intra b2b or to export
|
if ($objp->vat_tx_l != $objp->vat_tx_p && !empty($objp->vat_tx_p) && !empty($objp->vat_tx_l)) { // Note: having a vat rate of 0 is often the normal case when sells is intra b2b or to export
|
||||||
$code_vat_differ = 'font-weight:bold; text-decoration:blink; color:red';
|
$code_vat_differ = 'warning bold';
|
||||||
}
|
}
|
||||||
print '<td style="'.$code_vat_differ.'" class="right">';
|
print '<td class="right'.($code_vat_differ?' '.$code_vat_differ:'').'">';
|
||||||
print vatrate($facturefourn_static_det->tva_tx.($facturefourn_static_det->vat_src_code ? ' ('.$facturefourn_static_det->vat_src_code.')' : ''));
|
print vatrate($facturefourn_static_det->tva_tx.($facturefourn_static_det->vat_src_code ? ' ('.$facturefourn_static_det->vat_src_code.')' : ''));
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user