Add invoice print option

michal.siman

No avatar

2007-03-09 22:38

Hi,

i want add another one option in orders list. On order list now is 1) print order, 2) show order detail, 3) delete order.

On the orders_list template i was add one more button, print invoice - for a very similar function as print order, just with diferent template file, order_invoice.tpl instead of order_print.tpl.

Any idea how i can do this? Thanks for show me any way.

» Quick.Cart v2.x

treewood (OpenSolution)

Avatar: treewood

2007-03-09 23:55

michal.siman - hmm... not easy. i cant give you all steps because it will take alot time. but i can give You advice.
1. Copy file orders_print.tpl to new file for example orders_invoice.tpl
2. In actions_admin/orders.php copy "if" statement where is ( $a == 'More' || $a == 'Print' ) and add to this another $a == 'Invoice', after You will see if and add there another elseif to check $a and define $sFile with orders_invoice.tpl
3. In orders_list.tpl add link something like that: ?p=ordersInvoice&iOrder=$aList[iOrder]

michal.siman

No avatar

2007-03-10 07:55

yeah, it is easy. thank you for advice no. 2 :-)

treewood (OpenSolution)

Avatar: treewood

2007-03-10 13:58

michal.siman - for You it is easy. But to someone who is not oriented in QC and dont know PHP or HTML then it will be problem. I post to peoples and i have on mind that they know small PHP, good HTML ... and it is why i said it is not easy.
For me it is super simple :P

Back to top
about us | contact