Configuring Custom Fields to handle two different Parent field price interaction

Started by qualiadesigns, July 16, 2013, 07:36:24 AM

Previous topic - Next topic

qualiadesigns

So we have a Virtuemart system that is running the latest version of Joomla 2.5.11 and Virtuemart 2.0.22.

We are providing conferences and there are two sets of Customs Fields that need to adjust pricing for one another.

here is the pricing break down for the conference product that takes into account Day(s)Attending and Professional Accreditation.

Professional:
All 3 Days              = $460
2 Days - Oct 1 & 3 = $340
2 Days - Oct 2 & 3 = $340
2 Days - Oct 1 & 2 = $340
1 Day - Oct 1         = $190
1 Day - Oct 2         = $190
1 Day - Oct 3         = $190

Parent:
All 3 Days              = $400
2 Days - Oct 1 & 3 = $295
2 Days - Oct 2 & 3 = $295
2 Days - Oct 1 & 2 = $295
1 Day - Oct 1         = $160
1 Day - Oct 2         = $160
1 Day - Oct 3         = $160


There are two drop downs

Field Set 1 (Professional or Parent) includes two selections.
- Professional
- Parent

Field Set 2 (Day(s) Attending) Includes the number of days related to the conference.
All 3 Days
2 Days - Oct 1 & 3
2 Days - Oct 2 & 3
2 Days - Oct 1 & 2
1 Day - Oct 1
1 Day - Oct 2
1 Day - Oct 3

You can see an example of something similar running on our old site here:
http://www.socialthinking.com/books-products/workshops26/new-york-ny-oct-2013

It is using a Hacked piece of code to handle the pricing formula.

We do NOT want to use any more hacks as they create real difficulty with updates for us.

My questions is there some way to do this configuration in Virtuemart out of the box with the current VMCustom Fields? I have tried several variations but I must be missing something.

I have seen other cart software that does this out of the box by echoing out all the variations as a list of variants with pricing fields so you can set the price for all of the different combinations.

any insight into this setting would be most welcome!

qualiadesigns

Also I tried to create a single variant Called Conference Options.

With the following usability nightmare as big drop down list using the cart variant custom field:

Professional: All 3 Days; Professional: 2 Days - Oct 1 & 3; Professional: 2 Days - Oct 2 & 3; Professional: 2 Days - Oct 1 & 2; Professional: 1 Day - Oct 1; Professional: 1 Day - Oct 2; Professional: 1 Day - Oct 3; Parent: All 3 Days; Parent: 2 Days - Oct 1 & 3; Parent: 2 Days - Oct 2 & 3; Parent: 2 Days - Oct 1 & 2; Parent: 1 Day - Oct 1; Parent: 1 Day - Oct 2; Parent: 1 Day - Oct 3

This doesn't work either as the entry for Default field in the custom field seems to have a maximum number of characters allowed so it cuts off most of my variants after Parent: 2 Day Oct 1 & 3;

I assume I would have to edit the character count for this field in the database.

But I am really hoping there is an elegant solution that someone might point out to me in the event that I am being thick.

Maxim Pishnyak

For example "Day(s) Attending" could be your child variants.
After choosing "2 Days - Oct 1 & 3", web page reloads and show what options could choose customer: Professional or Parent.

Or vica versa.

For example "Professional or Parent" could be your child variants.
After choosing "Professional", web page reloads and show what options could choose customer:
2 Days - Oct 1 & 3
2 Days - Oct 2 & 3
2 Days - Oct 1 & 2
1 Day - Oct 1
1 Day - Oct 2
1 Day - Oct 3
You can support Community by voting for Project on the JED
https://extensions.joomla.org/extension/virtuemart/#reviews
Join us at
https://twitter.com/virtuemart

qualiadesigns

Hi Maxim thanks for your reply.

So using the Child Variant would involve using a Child product?

Would I have to create parent product for example called professional and have all the days attached to it?

Then create a child product called Parent to it that would have all the days attached to it with its own pricing?

Then the Child Variant would custom field would handle which one the user selects?

Let me know if I am thinking correctly about this.

Maxim Pishnyak

Yep, with only two main options (pro and parent) your plan is looking very good.
You can support Community by voting for Project on the JED
https://extensions.joomla.org/extension/virtuemart/#reviews
Join us at
https://twitter.com/virtuemart