Author Topic: Creating a Thank you notice on paid invoice  (Read 1190 times)

0 Members and 1 Guest are viewing this topic.

Offline lewistyler

  • 1
  • 0
  • New Member
  • *
Creating a Thank you notice on paid invoice
« on: December 20, 2016, 09:18:25 AM »

I suspect this would have to be achieved inside the invoice template rather than creating a separate .tpl file for the confirmation / thank you notice.

We are using the Design11 template and in the invoice.tpl I can see logic for:

Code: [Select]
{if $invoice.status=='Unpaid'}
I am assuming I'd have to write some logic where the invoice.status is 'Paid' but I was really hoping for some advice on the best way to achieve this - and to auto redirect the user upon the successful payment.

Any insights would be much appreciated. thanks

Offline d4f

  • 130
  • 6
  • Community Managers
  • Active Participant
  • ****
Re: Creating a Thank you notice on paid invoice
« Reply #1 on: February 27, 2017, 08:06:52 AM »
It's regular HTML with Smarty template engine so you can just proceed like you would on any other template page. 
However please note that the PDF is also rendered from the same template and does not have a decent CSS support so you'll have to restrict your styling quite badly unfortunately.

Autoredirect won't work directly but you could inject some javascript to do that job for you through the use of a custom module. Not too hard but as always without decent documentation you'll waste an afternoon or two getting it to work correctly  ::)

Offline Chrisuza

  • 2
  • 0
  • New Member
  • *
Re: Creating a Thank you notice on paid invoice
« Reply #2 on: May 21, 2017, 10:59:00 PM »
The information may not be supported css you need to change this more appropriate pattern.