Page 1 of 1

Invoice printout Numberformat/Variable Problem?

Posted: Sun Aug 20, 2017 12:43 pm
by sepp_huber
Hi,

we have got a problem with our invoices:
I do not know if it is a general bug or a bug in our form logic...

Invoices under 1.000 € are ok, for invoices over 1.000 € the tax rate of the room is zero in the printout.
For sure we have made some changes on the "standard".
It seems that the problem is in this statement and the "_p" in the variable and numbers over 1.000:
Set [rate_vat_p] Equal [rate_price_withdiscount_p] - [rate_no_vat_invo_p]
I have inserted some debug printouts in the invoice template and the two variables "rate_price_withdiscount_p" and "rate_no_vat_invo_p" have the correct values. The result of the subtraction is zero, but only for bigger numbers.
I cannot understand this, because for me the code is always the same... for big and small numbers.
The problem is also if I change the numberformat in the settings from "1.050.000,32" to "1,050,000.32"
The Problem was in 2.1.4 and today I have done a upgrade to 2.2.1, it also is there.
Any ideas?

Screenshots are here
https://drive.google.com/file/d/0B20s39 ... sp=sharing

Re: Invoice printout Numberformat/Variable Problem?

Posted: Sat Sep 09, 2017 10:40 am
by sepp_huber
Hi marco,

do you need more information for the problem?

Re: Invoice printout Numberformat/Variable Problem?

Posted: Tue Jun 05, 2018 9:25 pm
by marco
Hello,
this is not a bug, the variables ending with _p are transformed with the thousands separators, so you should not make operations on them (use them only to display numbers in the document), use the variable without _p instead.

Regards,
Marco