Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Client to update Order Status themselves if certain criteria met.

Client to update Order Status themselves if certain criteria met.

Views: 933

Results 1 to 4 of 4
26 Jul 2016, 2:54 PM
#1
matt_staines avatar

matt_staines

New Zenner

Join Date:
Oct 2013
Location:
Portishead, North Somerset, United Kingdom
Posts:
34
Plugin Contributions:
0

Client to update Order Status themselves if certain criteria met.

Hi All,

I'm looking to see if this is possible. I'm looking for clients to be able to update their own order status from within their own account order page (not admin). I want it restricted so that they can only edit the order status if it meets certain criteria.

For example:

I have a list or order statuses, such as

  • Processing Order
  • Order on Proof
  • Proof Approved
  • Proof Rejected
  • Order Dispatched

An example of functionality would be:
If order status is 'Order on Proof', show edit status dropdown menu. The client could then update to either 'Proof Approved' or 'Proof Rejected' with all the standard functionality that you would usually have in admin.

Does anyone know what files I'd need to look at for this customisation, or if this is even possible/safe from the clients order admin panel.

Thanks

Matt

26 Jul 2016, 3:00 PM
#2
lat9 avatar

lat9

Administrator

Join Date:
Sep 2009
Location:
Stuart, FL
Posts:
14,081
Plugin Contributions:
56

Re: Client to update Order Status themselves if certain criteria met.

You're looking to change the behavior of the account_history_info page (where an order's details are visible to the customer). There are a couple of files that you'll need to change to effect the behavior you desire:

/includes/modules/pages/account_history_info/header_php.php

You'll use this module to add the changes to detect whether the user's able to change their status and to intercept/process any updates that the customer has made via change to the status dropdown displayed by the template file.

/includes/templates/YOUR_TEMPLATE/templates/tpl_account_history_info_default.php

This module's change will detect the indication set by the header file to determine whether to create/display a form to allow the order's status to be changed.

26 Jul 2016, 4:00 PM
#3
design75 avatar

design75

Totally Zenned

Join Date:
Dec 2009
Location:
Amersfoort, The Netherlands
Posts:
2,862
Plugin Contributions:
5

Re: Client to update Order Status themselves if certain criteria met.

I may have the code for you from a previous project I did. Let me check for you tonight when I am home again.

27 Jul 2016, 10:59 AM
#4
matt_staines avatar

matt_staines

New Zenner

Join Date:
Oct 2013
Location:
Portishead, North Somerset, United Kingdom
Posts:
34
Plugin Contributions:
0

Re: Client to update Order Status themselves if certain criteria met.

Design75:

I may have the code for you from a previous project I did. Let me check for you tonight when I am home again.

That would be amazing if you have the code already! Let me know when you get a chance.