1
I'm trying to create a Credit Amount at the bottom of each invoice in cases where the amount paid was more then the invoice.
I'm using the default.php file under componments/views/invoices/tmpl/ file to make changes.
I have this formula: $amount_credit = $total_payments - $total;
I have his entered in the $search: "{amount_credit}"
I have this entered in the replace: $amount_credit->amount_credit
Any help is much appreciated. Thanks. This is the final thing I am needing to customize your component. It working great.
There could be an easier way to do this as well...perhaps pointing me in the direction of the invoice file, and I could write a simple subtraction code inside nested ifs.
I'm using the default.php file under componments/views/invoices/tmpl/ file to make changes.
I have this formula: $amount_credit = $total_payments - $total;
I have his entered in the $search: "{amount_credit}"
I have this entered in the replace: $amount_credit->amount_credit
Any help is much appreciated. Thanks. This is the final thing I am needing to customize your component. It working great.
There could be an easier way to do this as well...perhaps pointing me in the direction of the invoice file, and I could write a simple subtraction code inside nested ifs.
Responses (1)
-
Accepted Answer
1I've got it now. I can have my created token of {amount_credit} appear when I create the formula of assign the value of :
$amount_credit=$subtotal_payments - $total
Now, I'm just going to make the format pretty.
And we are off and running.-
Germinal Campsmore than a month agogood job! :)
-
Your Reply
Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here.
Register Here »