This is not a feature of Zen Cart at this time, but you could build this into the comments and customize the catalog to not show these marked comments to the customer ...
You would need to edit the file:
/includes/modules/pages/account_history_info/header_php.php
And change the select statement to not include those that were not sent to the customer ...
This select is grabbing all of the history ...
[PHP]
$statuses_query = "SELECT os.orders_status_name, osh.date_added, osh.comments
FROM " . TABLE_ORDERS_STATUS . " os, " . TABLE_ORDERS_STATUS_HISTORY . " osh
WHERE osh.orders_id = :ordersID
AND osh.orders_status_id = os.orders_status_id
AND os.language_id = :languagesID
ORDER BY osh.date_added";
[/PHP]
Thanks Linda for providing the file and the PHP code that needed to be edited.
$statuses_query = "SELECT os.orders_status_name, osh.date_added, osh.comments
FROM " . TABLE_ORDERS_STATUS . " os, " . TABLE_ORDERS_STATUS_HISTORY . " osh
WHERE osh.orders_id = :ordersID
AND osh.orders_status_id = os.orders_status_id
AND os.language_id = :languagesID
ORDER BY osh.date_added";
Added (AND osh.customer_notified ='1' ) to the file above. And now if I do not tic the notifiy customer box it does not show in the customers account under "Status History & Comments".
$statuses_query = "SELECT os.orders_status_name, osh.date_added, osh.comments
FROM " . TABLE_ORDERS_STATUS . " os, " . TABLE_ORDERS_STATUS_HISTORY . " osh
WHERE osh.orders_id = :ordersID
AND osh.customer_notified ='1'
AND osh.orders_status_id = os.orders_status_id
AND os.language_id = :languagesID
ORDER BY osh.date_added";
It is on the list of things to do ... but it is not a pressing feature ...
You might be best having this customized for your site ... there are many ways to approach this and you can do a simple limitation of all but customer is seen by customer vs a more useful change where you can control what the customer sees and does not see ...
If you get stuck, you can drop me a PM if need be ...
her post does not say what to edit. The previous posts mention this:
/includes/pages/account_history_info/header_php.php and that is INCORRECT. I would think the forum would want correct information....
I mention where to edit and what in one post...
is that acceptable?
-----
ps if i am ever wrong (almost thru 2007 without...) I will gladly take a tomatoe in the face. Until then, I think you will find my posts are usually right on. I am not new to osc, php, sql or server. thanks, look forward to contributing without explanations.
This worked perfectly for me! And is going to be a huge time saver to be able to have order information all in one, especially when a customer calls with a problem with the order or something!