Hello,
My products have no base price and are all about the customization options. I have two issues I could use some assistance with, both involve the final order.
1: I would like the full details about what it is the user chose from the options. This seems fairly obvious to me, but I don't know what the user actually chose by looking at an order. If red = $5 and blue = $5 and green = $7, but in the order I see a price of $5, how do I know if it's for red or blue? I feel like I am missing something very obvious here.
2: I want to add user data to these orders. A good use case would be 'an engraving on a ring', what's the engraving? I already have the form in place as a custom variant that I programmed, but what is the best route to save this data into the order so I can use it later when processing said order?
thank you,
-Steven
I am sorry, but the options are stored and shown, which version do you use?
Quote from: Milbo on December 19, 2013, 11:35:21 AM
I am sorry, but the options are stored and shown, which version do you use?
apologies, in my last reply I mis-read what you wrote here.
I do not see any custom variants being shown on my order screen ( in the admin ), I only see the total of the order. Would you mind confirming where I should see this data? Thanks!
Apologies, I do see the data now. The confusion was due to testing only one cart variant, it just wasn't all that obvious that the I was looking at the variant and not the product.
How about saving the extra data, my number 2 question?
Ok, I've made some progress.
In my custom plugin ( based on the donations plugin ) I have added some variables, like this:
function __construct(& $subject, $config) {
parent::__construct($subject, $config);
$varsToPush = array(
'message'=>array('', 'string'),
);
$this->setConfigParameterable('custom_params',$varsToPush);
}
And I see the variable is on the product's page, confirmed with print_r
I setup the form like this:
<input id="Field1" name="customPlugin[<?php echo $viewData[0]->virtuemart_customfield_id ?>][<?php echo $this->_name?>][message]" type="text" class="field text fn" value="<? echo $viewData[0]->message; ?>" size="8" tabindex="1">
But I am unsure if it saves. I never see any of it in the order details page. Also, when I try to edit an item in the cart, instead it wants to add a new item of that type instead of editing it. Is there edit functionality?
Thanks for your help.
I moved this discussion to another forum:
http://forum.virtuemart.net/index.php?topic=121076.0