| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
Printing 'Customer Notes' on invoices | ||||
|
|
Thread Tools | Search this Thread |
#61
|
|||||||
|
|||||||
Re: Printing 'Customer Notes' on invoices
Order Status with Date/Time Stamp addition
Many people in the X-Cart forums have asked for a way to put a timestamp when the order status changes. You can integrate a Date and Time Stamp with this addition to the Customer Notes MOD. Each time an Order Status change is made, it will automatically be appended to the end of the Customer Comments/Notes and added into every email sent that has the Customer Comments/Notes included. The Order Status with Timestamp are also visible on the backend of the site and stored in the $customer_comments field in the database. If you would like to use this code, follow the steps in Post #56 above, but replace Step 9 with this code: Locate this File: admin/order.php Find this Code: (around line 134) Code:
Replace with this Code: (added just above) # This section converts the Order Status letter to Status Type name (NOTE - adjust or add to list if you have Custom Order Status) Code:
NOTES: 1.) I needed to add an hour (i.e. 3600 seconds) to the $timestamp variable, as my server is an hour behind my store - adjust accordingly (+/-) for your store time. 2.) I am on east cost time, hence the EST in the timestamp code output formatting... adjust for your timezone. 3.) You can adjust the $timestamp variable to equal the date format you prefer... here's some sample output: date("M j, Y @ g:i a",time()); # outputs: Oct 6, 2007 @ 1:06 pm date("F j, Y, g:i a",time()); # outputs: September 21, 2007, 4:25 pm date("m/d/y - H:i:s",time()); # outputs: 9/21/07 - 16:25:02 date("r"); # outputs: Fri, Sep 2007 16:25:56 * You can find other sample time and date formatting in PHP here: http://us3.php.net/date UPDATE: If you would like a standalone version of the Order Status with TimeStamp and UserID of the person who made the change, only visible to Admins and Providers... view my code at these 2 posts: http://forum.x-cart.com/showthread.php?t=12823 http://forum.x-cart.com/showthread.php?t=18645&page=2 Tested in X-Cart 4.0.19 Robert
__________________
X-cart 4.1.10 |
|||||||
|
|||
X-Cart forums © 2001-2020
|