';
// Ref
- print '| ';
+ print ' | ';
print $invoicesupplierstatic->getNomUrl(1);
print ' | ';
// Ref supplier
- print ''.$objp->ref_supplier.' | ';
+ print ''.$objp->ref_supplier.' | ';
+
+ // type
+ if ($displayAllInvoices) {
+ $typearray = [
+ FactureFournisseur::TYPE_STANDARD => $langs->trans("InvoiceStandard"),
+ FactureFournisseur::TYPE_REPLACEMENT => $langs->trans("InvoiceReplacement"),
+ FactureFournisseur::TYPE_CREDIT_NOTE => $langs->trans("InvoiceAvoir"),
+ FactureFournisseur::TYPE_DEPOSIT => $langs->trans("InvoiceDeposit"),
+ ];
+ // Primary Secondary Success Danger Warning Info Light Dark status0 status1 status2 status3 status4 status5 status6 status7 status8 status9
+ print '' . $typearray[$objp->type] . ' | ';
+ }
// Date
if ($objp->df > 0) {
- print '';
+ print ' | ';
print dol_print_date($db->jdate($objp->df), 'day').' | ';
} else {
- print '!!! | ';
+ print '!!! | ';
}
// Date Max Payment
if ($objp->dlr > 0) {
- print '';
+ print ' | ';
print dol_print_date($db->jdate($objp->dlr), 'day');
if ($invoice->hasDelay()) {
@@ -678,21 +729,21 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie
print ' | ';
} else {
- print '-- | ';
+ print '-- | ';
}
// Multicurrency
if (isModEnabled("multicurrency")) {
// Currency
- print ''.$objp->multicurrency_code." | \n";
+ print ''.$objp->multicurrency_code." | \n";
- print '';
+ print ' | ';
if ($objp->multicurrency_code && $objp->multicurrency_code != $conf->currency) {
print price($objp->multicurrency_total_ttc);
}
print ' | ';
- print '';
+ print ' | ';
if ($objp->multicurrency_code && $objp->multicurrency_code != $conf->currency) {
print price($sign * $multicurrency_payment);
if ($multicurrency_creditnotes) {
@@ -704,23 +755,33 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie
}
print ' | ';
- print '';
+ print ' | ';
if ($objp->multicurrency_code && $objp->multicurrency_code != $conf->currency) {
print price($sign * (float) $multicurrency_remaintopay);
}
print ' | ';
- print '';
+ print ' | ';
// Add remind multicurrency amount
$namef = 'multicurrency_amount_'.$objp->facid;
$nameRemain = 'multicurrency_remain_'.$objp->facid;
+
+ $min = $max = '';
+ if ($displayAllInvoices) {
+ if ($objp->type == FactureFournisseur::TYPE_CREDIT_NOTE) {
+ $max = ' max="0" ';
+ } else {
+ $min = ' min="0" ';
+ }
+ }
+
if ($objp->multicurrency_code && $objp->multicurrency_code != $conf->currency) {
if ($action != 'add_paiement') {
if (!empty($conf->use_javascript_ajax)) {
- print img_picto("Auto fill", 'rightarrow', "class='AutoFillAmount' data-rowname='".$namef."' data-value='".($sign * (float) $multicurrency_remaintopay)."'");
+ print ' |