FIX accountancy export Quadratus when doc ref is less than 10 char

This commit is contained in:
VESSILLER 2025-02-18 12:07:19 +01:00
parent f511e2e523
commit 9d9d890c97

View File

@ -966,7 +966,7 @@ class AccountancyExport
// We need to keep the 10 lastest number of invoice doc_ref not the beginning part that is the unusefull almost same part
// $tab['num_piece3'] = str_pad(self::trunc($line->piece_num, 10), 10);
$tab['num_piece3'] = substr(self::trunc($line->doc_ref, 20), -10);
$tab['num_piece3'] = str_pad(substr(self::trunc($line->doc_ref, 20), -10), 10);
$tab['reserved'] = str_repeat(' ', 10); // position 159
$tab['currency_amount'] = str_repeat(' ', 13); // position 169
// get document file