Merge pull request #8713 from atm-greg/Fix_supplierinvoice_line_Rank_handling

FIX addline on invoice supplier manage rank on its own if not provided
This commit is contained in:
Laurent Destailleur 2018-05-02 18:24:17 +02:00 committed by GitHub
commit f3003fa542
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1383,6 +1383,11 @@ class FactureFournisseur extends CommonInvoice
if (empty($txlocaltax1)) $txlocaltax1=0;
if (empty($txlocaltax2)) $txlocaltax2=0;
if ($rang < 0) {
$rangmax = $this->line_max();
$rang = $rangmax + 1;
}
$localtaxes_type=getLocalTaxesFromRate($txtva, 0, $mysoc, $this->thirdparty);
// Clean vat code