![]() |
Re: PO Numbers on Invoices, Searchable in Orders.
I just added this hack to order_invoice.tpl. It displays the PO number by using regex in the smarty template to remove everything after the first line break in $order.details.
{if $order.payment_method eq "Purchase Order"}{$order.details|regex_replace:"/[\n].*/":""}{/if} |
Re: PO Numbers on Invoices, Searchable in Orders.
I finally got this mod to work on v4.4.4. It was not working when the po_number field in the database was set to VARCHAR. But when I changed it to text, it worked. Weird!
But thank you, Russell, for the great modification! |
Re: PO Numbers on Invoices, Searchable in Orders.
Having an issue with getting this to work.
I can insert a table entry for po_number manually, and it'll show up just fine in searches, etc. but as soon as I go to create a new order through xcart I get an error. Warning 403 Access denied ! You are not allowed to access that resource! Id: 79 This error no longer occurs if I remove: 'po_number' => addslashes(getPONum($order_details)), from func.order.php I've tried changing the dbtype to text from varchar, but that didn't help. |
Re: PO Numbers on Invoices, Searchable in Orders.
Is this working with 4.5.1 ?
|
Re: PO Numbers on Invoices, Searchable in Orders.
will this mode work on 4.5.2?
|
Re: PO Numbers on Invoices, Searchable in Orders.
Quote:
Hasn't been tested higher than 4.4.x (see notgrass' post above) but you could be the first! :-) |
Re: PO Numbers on Invoices, Searchable in Orders.
:-) This mod works great in 4.5.4 I'm using it
|
Re: PO Numbers on Invoices, Searchable in Orders.
Quote:
I hate bumping old threads, but I ran across this thread while trying to determine the reason for an almost identical error while modifying a module, and wanted to provide my solution. Clear the x-cart cache. It's that easy. I made a change to code that involves inserting data into a modified db table using the array2insert function built into x-cart. Apparently x-cart caches information about that table, and would throw this error when I'd provide 2 extra columns in the array. Clearing the cache solved it. |
All times are GMT -8. The time now is 12:36 AM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.