Hello,
I am generating pay by square img in e-mail template using dynamic variables but i need to delete EUR currency from variable {{{invoice_total}}} , otherwise it wont generate the image, could you please help me how to solve it?
Thanks
Hello,
I am generating pay by square img in e-mail template using dynamic variables but i need to delete EUR currency from variable {{{invoice_total}}} , otherwise it wont generate the image, could you please help me how to solve it?
Thanks
Maybe <?php echo ($invoice->invoice_balance) ?>
will help you here.
Tried that, but that doesnt work
I cant use PHP there probably…
I thought maybe creating new variable without currency but I dont know where…
There’s three problems:
dynamic variable
, invoice_total with a bunch of curly bracketsFirst figure out question 2, maybe there’s a class somewhere that does that for you.
Do you know where I can find invoice_total variable? I tried to find it but I couldnt, also Im not a PHP expert…
Thanks
I am trying to do this:
https://api.qrgenerator.sk/by-square/pay/qr.png?iban{{{user_iban}}}&amount={{{invoice_total}}}¤cy=EUR&vs={{{invoice_number}}}&size=128&transparent=false
and I get error:
“errors”:{“amount”:[“The value ‘{{{invoice_total}}}’ is not valid.”]}}
because the value has EUR currency
EDIT:
<img src="https://api.QRGenerator.sk/by-square/pay/qr.png?iban=<?php echo ($invoice->user_iban) ?>&amount=<?php echo ($invoice->invoice_balance) ?>¤cy=EUR&vs=<?php echo ($invoice->invoice_number) ?>&size=128&transparent=false" alt="QR kod" />
I did it like this in application\modules\mailer\views\invoice.php and it works
This is a nice tweak you made, want to share all that needs to be done to enable this function? Thanks in advance!
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.