Post by crispylettuce » Tue Nov 13, 2012 7:36 pm

Morning All :)

I know this is probably simple, but how can i add a line of text to appear at the bottom of the printed Invoice which is accessible via Admin area?

Im assuming i have to edit the order_invoice.tpl file but i just cant seem to get it to work....

Would really appreciate if someone could tell me how to get it to work...


Andy

Active Member

Posts

Joined
Fri Aug 03, 2012 8:54 pm

Post by Bg-foxx » Sun Dec 16, 2012 12:18 am

That's what I'm looking to do, too, Andy. Did you figure it out?

New member

Posts

Joined
Wed Feb 22, 2012 7:55 am

Post by crispylettuce » Sun Dec 16, 2012 12:24 am

I gave up to be honest :-)

I wanted to display VAT number at bottom, but ended up adding the VAT number to the address so it appears there on the invoice...

Had it close few times, but just couldn't get it to wrk

Andy

Active Member

Posts

Joined
Fri Aug 03, 2012 8:54 pm

Post by Bg-foxx » Sun Dec 16, 2012 1:03 am

Thanks, Andy. It was worth asking. I can't imagine that no one needed printed invoice edit before so that others who know the core files of OC have pointed to the file that needs to be edited.

I'm sure it's something more obvious than not, but I still don't know where to look for it.

New member

Posts

Joined
Wed Feb 22, 2012 7:55 am

Post by labeshops » Sun Dec 16, 2012 1:07 am

You can add anything you want to the invoice by editing admin/view/template/sale/order_invoice.tpl

I put return info, repeat customer coupon code, etc on it. Add any html you want above the bottom

Code: Select all

<?php } ?>
</body>
</html>
I also rearranged mine to suit me and added my logo to the top, etc. Easy.

Any of the template files can be edited so just look thru the this section to find what you want.

Running Opencart v3.0.3.9 with multi-stores and the default template from https://www.labeshops.com which has links to all my stores.


User avatar
Expert Member

Posts

Joined
Thu Aug 04, 2011 4:41 am
Location - Florida, USA

Post by Bg-foxx » Sun Dec 16, 2012 3:27 am

Thanks, labelshop!

I gather I have to place my custom text above the <?php } ?> line?

Thanks once again for the help!

New member

Posts

Joined
Wed Feb 22, 2012 7:55 am

Post by labeshops » Sun Dec 16, 2012 11:47 am

Yes, which is why I said add any html you want above the bottom section with that code, so yes, that would be above the <?php } ?> tag since that's part of the code I included.

Running Opencart v3.0.3.9 with multi-stores and the default template from https://www.labeshops.com which has links to all my stores.


User avatar
Expert Member

Posts

Joined
Thu Aug 04, 2011 4:41 am
Location - Florida, USA

Post by Bg-foxx » Sun Dec 16, 2012 10:19 pm

That's what I thought. Thanks again!

New member

Posts

Joined
Wed Feb 22, 2012 7:55 am

Post by delmi » Thu Dec 04, 2014 11:12 pm

hello everybody,

Tell me please if anybody knows , how to add in bottom customer name and surname? I have tried to add custom text like:
I ”name and surname” agree with this term of use , etc... I have added <?php echo $order['payment_address'];?> but it shows me name and surname with address. I would like to show only name and surname.

Thank you.

Newbie

Posts

Joined
Fri Dec 27, 2013 12:26 am

Post by labeshops » Thu Dec 04, 2014 11:38 pm

I haven't tested it, but try echoing instead in your template file:

Code: Select all

<?php echo $order['firstname'];?> <?php echo $order['lastname'];?>
And in admin/controller/sale/order.php

find the section that is:

Code: Select all

$this->data['orders'][] = array(
after the comment line ('comment' => nl2br($order_info['comment'])), add:

Code: Select all

					'firstname'			=> $order_info['firstname'],
					'lastname'          => $order_info['lastname'],

Running Opencart v3.0.3.9 with multi-stores and the default template from https://www.labeshops.com which has links to all my stores.


User avatar
Expert Member

Posts

Joined
Thu Aug 04, 2011 4:41 am
Location - Florida, USA
Who is online

Users browsing this forum: Amazon [Bot] and 14 guests