Closed (fixed)
Project:
Ubercart
Version:
7.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
1 May 2013 at 07:26 UTC
Updated:
24 Jun 2015 at 09:41 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
longwaveShould this just be a comma-separated list of product names? Or should we include the quantities here as well (e.g. 1 x T-shirt, 2 x Hat)?
Comment #2
philsward commentedPersonally, I would LOVE to see the quantities...
I'm not sure how other's would use this token, outside of an email, but now that I have all of the abandoned order emails coming in, it's given me some good insight to where I need to focus attention to assist conversions. (free shipping products vs freight lookup, product a vs product b, etc.)
I also use the emails as a Lead Generation method for my sales guy when someone does leave their info, but doesn't buy. If he had the quantities, he would have a much better idea of how to start a conversation with the customer.
Comment #3
philsward commentedThinking about it, would we be better off to have a comma separated list, or a "line item list"?
1 x shirt, 2 x coffee mug, 4 x plush widget
vs
1 x shirt
2 x coffee mug
4 x plush widget
(My vote is for the latter)
Comment #4
longwaveThe source of this bug is in Entity Tokens, which helpfully tries to provide tokens for all order properties, including the list of products, but this doesn't work properly for lists: #1621084: Support list<struct> type tokens
I think we could override this by providing our own token, however.
Comment #5
philsward commentedI think a list would be ideal, but at the same time if it's going to be a pain to get it working right, I suppose it can always be handled through email HTML?
On the same note, how hard will it be to integrate the uc quantity with the entity token? Your idea of creating a custom token might be easier in the long run... Your call :-)
Comment #6
longwaveThis patch adds a custom token with one product per line, including quantity. Fixing entity tokens is a lot more work without any more real benefits right now.
Comment #7
philsward commentedAwesome! Looks like it works perfect to me!!
Now that this is working, a person could override the default "E-mail admin checkout notification" using the admin template, and instead use a rule to output the same stuff and more, huh?
Thanks for getting this going!
Comment #8
philsward commentedLooking at things, the only two issues for replacing the admin template with a rule is:
1) Need a SKU token (and) Product & SKU token
2) Needs total shipping amount token
At this point, I can live without them :-)
@longwave if you're interested in adding the suggested tokens, let me know and I'll setup a feature request for them. Otherwise, I might have someone come up with a patch for it at a later time.
Comment #9
longwaveCommitted #6.
Feel free to open the feature request; ultimately I think the most flexibility would come from being able to render a Views table into a token, that way it would be fully customisable. And yes, replacing the order admin "invoice" template with a standard Rules email is a good long term goal, I think.
Comment #13
longwave