News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Print Invoice on Order Confirmation Page

Started by Stonedfury, July 25, 2013, 21:15:35 PM

Previous topic - Next topic

Stonedfury

Hello Everyone.

Could I get some guidance in adding a print invoice button on the confirmation/thank you page? I did a search and I get a ton of results, mostly vm1.1, and for vm2 it seems only BE. However this would be a much better approach to customers than waiting on the email or having to do a manual print.

I looked at the admin section and see where the invoice print information there but something tells me that it is not as simple as using that code.

Thank you in advance.
No such thing as a stupid question, only a stupid answer. I won't ask if I know the answer or found it using the search as you suggested.

Stonedfury

Has anyone thought about this and came up with a solution or maybe knows where the solution lies and can point a finger that way?
No such thing as a stupid question, only a stupid answer. I won't ask if I know the answer or found it using the search as you suggested.

Stonedfury

Maybe use this on the order_done.php
<h1><?php echo JText::_('COM_VIRTUEMART_ACC_ORDER_INFO'); ?>

<?php

/* Print view URL */
$details_url juri::root().'index.php?option=com_virtuemart&view=orders&layout=details&tmpl=component&virtuemart_order_id=' $this->orderdetails['details']['BT']->virtuemart_order_id .'&order_pass=' JRequest::getString('order_pass',false) .'&order_number='.JRequest::getString('order_number',false);
$details_link "<a href=\"javascript:void window.open('$details_url', 'win2', 'status=no,toolbar=no,scrollbars=yes,titlebar=no,menubar=no,resizable=yes,width=640,height=480,directories=no,location=no');\"  >";
//$details_link .= '<span class="hasTip print_32" title="' . JText::_('COM_VIRTUEMART_PRINT') . '">&nbsp;</span></a>';
$button = (JVM_VERSION==1) ? '/images/M_images/printButton.png' 'system/printButton.png';
$details_link .= JHtml::_('image',$buttonJText::_('COM_VIRTUEMART_PRINT'), NULLtrue);
$details_link  .=  '</a>';
echo $details_link?>

</h1>
No such thing as a stupid question, only a stupid answer. I won't ask if I know the answer or found it using the search as you suggested.

Maxim Pishnyak

Quote from: Stonedfury on July 25, 2013, 21:15:35 PM
Could I get some guidance in adding a print invoice button on the confirmation/thank you page? I did a search and I get a ton of results, mostly vm1.1, and for vm2 it seems only BE.
So these tons of threads about pdfs for invoices couldn't be helpful? Pdf for invoice could be used only in BE?
You can support Community by voting for Project on the JED
https://extensions.joomla.org/extension/virtuemart/#reviews
Join us at
https://twitter.com/virtuemart

Stonedfury

Quote from: Maxim Pishnyak on August 14, 2013, 21:41:45 PM
Quote from: Stonedfury on July 25, 2013, 21:15:35 PM
Could I get some guidance in adding a print invoice button on the confirmation/thank you page? I did a search and I get a ton of results, mostly vm1.1, and for vm2 it seems only BE.
So these tons of threads about pdfs for invoices couldn't be helpful? Pdf for invoice could be used only in BE?
Nope. See customers like to be able to be lazy and click the print button to get their invoice then and there. Not wait for an email. So do you have anything helpful to provide?
No such thing as a stupid question, only a stupid answer. I won't ask if I know the answer or found it using the search as you suggested.

Maxim Pishnyak

Yes. It's Bulk Order Print 3rd party VM extension.
You can support Community by voting for Project on the JED
https://extensions.joomla.org/extension/virtuemart/#reviews
Join us at
https://twitter.com/virtuemart

Stonedfury

I am not talking about BE printing. I am talking about the customer being able to print the order invoice from the order done page. order_done.php
No such thing as a stupid question, only a stupid answer. I won't ask if I know the answer or found it using the search as you suggested.


Stonedfury

I guess if I wanted to print the product details page that is a good start.
No such thing as a stupid question, only a stupid answer. I won't ask if I know the answer or found it using the search as you suggested.

Maxim Pishnyak

I saw that your code in your post #2 in this thread is not the same as printing code in mentioned by me thread. Why do you think that 'details' thread isn't useful for you at all?
You can support Community by voting for Project on the JED
https://extensions.joomla.org/extension/virtuemart/#reviews
Join us at
https://twitter.com/virtuemart

Stonedfury

The code in my post is from my template and is off the order details page. I wish to get it functional on the order done page. I think you are skipping that part.

Order done! Thank you! Your order number is --------- Click to print invoice
No such thing as a stupid question, only a stupid answer. I won't ask if I know the answer or found it using the search as you suggested.

mowlman

anyone get this figured out?

The ability for a customer to print their invoice directly from the Order_done page once they completed checkout?