I'm looking for a way to identify which 'Store' an order came from.
A little context, our client, a restaurant, uses Expresso Store to handle their online ordering. They've just opened a new location, and online orders all go to the same email address, making it impossible for them to determine which location the order refers to.
I'm working around this using a cookie that gets set to a value depending on which page they are ordering from. On submission, I'd like to set the order status depending on the cookie value.
Am I right in assuming I'll need to use the 'store_order_complete_end' hook to change order status on submission? Or is there a way to set status before submitting the order?
Thanks in advance.
Bobby
EDIT: I believe the change, if possible, would have to be made within the {exp:store:payment} tag pair. I noticed that it has access to the {exp:store:order} tags, including the order_status parameter. In the latter, it's used as a filter, but when used in the {exp:store:payment} tag pair, could it be used to set the order status?
FINAL EDIT: Hey guys, just wanted to let you know I've found a workaround for this problem using Michael's advice below. I'm using a custom variable. Basically, there is a page for each location that has an address checker (to see if you're within the delivery zone). On success, both are directed to the same order page, and the custom variable is set. This value is appended to the subject line for the Order / Payment Confirmation emails.
There is a master email address that is BCC'd on all emails. We then use filtering to forward to individual store email addresses depending on the subject line.
All in all, it's not the most elegant solution, but it does work. Thanks again for the help.