Portal Engine Questions on portal engine and web parts.
Version 7.x > Portal Engine > Custom Fields in Kentico Product Options View modes: 
User avatar
Member
Member
robert-pulldigital - 6/13/2013 3:26:40 AM
   
Custom Fields in Kentico Product Options
Good morning, i'm new to Kentico Development and will explain the issue as I understand it.

Ultimately the end goal is to have a drop down on the page that is dependent on another drop down value.

For instance in the case of your Configurable PC product in the ecommerce demo site.

We need to implement a customisation whereby when the user selects a type of motherboard then the selection of graphics cards changes.

So from the top how might you go about implementing this in Kentico, we have a plan but it seems like a very complicated plan for something I would consider so simple :)

At the moment we are creating a document type with custom fields we can override the OptionCategoryInfoProvider but i'm not sure where to go with it from there.

Can you just take it from the top and i'll drill into it myself.

Thanks

User avatar
Kentico Support
Kentico Support
kentico_filipl - 6/13/2013 4:43:42 AM
   
RE:Custom Fields in Kentico Product Options
Hello Robert,

This can be done by creating a new form control which will consist of 2 drop-down lists. Basically, the second one will dynamically load its content based on the value selected in the first one.

More information about creating custom form controls can be found in Developer's Guide - Developing form controls.

Best regards,
Filip Ligac

User avatar
Member
Member
robert-pulldigital - 6/13/2013 5:10:18 AM
   
RE:Custom Fields in Kentico Product Options
Thanks i'll take a look, it's important we get the selected options back into the basket so we can fulfil the order correctly. I'll start with the document you have provided though and come back if I can't complete the work.

Thanks

User avatar
Member
Member
robert-pulldigital - 6/13/2013 6:17:20 AM
   
RE:Custom Fields in Kentico Product Options
Can you explain in more detail even after following the example I didn't get the same outcome that the example suggested I would :).

Typical really

What are the steps for me to create a single control that has 2 drop downs on it

When a particular value is selected on the first control the second would be made visible, should the user then select a different item from the first dropdown the second dropdown would disappear again.

We need to be able to define the values for both dropdowns and we need to specify which value in the first dropdown is the one that makes the second dropdown show.

Finally the values of both dropdowns need to be retrieved later on as it is important to correctly fulfil the order.

User avatar
Member
Member
robert-pulldigital - 6/13/2013 6:34:27 AM
   
RE:Custom Fields in Kentico Product Options
It's worth noting the outcome of this is to have the selected options from the user fed back into the basket and through to the order so staff can pick up the order and fulfill it.

User avatar
Member
Member
robert-pulldigital - 6/14/2013 6:29:21 AM
   
RE:Custom Fields in Kentico Product Options
I still haven't been able to achieve this. Have a dropdown show or hide based on another ones value.

The fact it takes 30 seconds to achieve when writing a site is really getting me down :)


User avatar
Kentico Support
Kentico Support
kentico_filipl - 6/14/2013 7:34:12 AM
   
RE:Custom Fields in Kentico Product Options
Hello Robert,

You should follow the same steps which are mentioned in Developer's Guide, except for adding just 1 DropDownList to this form control, you add 2 of them. Then you implement your custom logic in the code behind of this control (public override Object Value method) according to the example and register it the same way.

If you are experiencing certain problems with the implementation itself, I would recommend that you consider our consulting services which should help you develop this functionality exactly according to your needs.

Best regards,
Filip Ligac