Portal Engine Questions on portal engine and web parts.
Version 7.x > Portal Engine > Macro Question - Product Is Bundle View modes: 
User avatar
Member
Member
steve - 5/8/2013 2:42:36 PM
   
Macro Question - Product Is Bundle
I'm attempting to hide a repeater web part via the visible condition if a product is representing the bundle type.

I've done this with other conditions, but I can't figure out how to check and see if a product is a bundle or not via macro.

Any ideas?

User avatar
Member
Member
kentico_sandroj - 5/8/2013 5:00:43 PM
   
RE:Macro Question - Product Is Bundle
Hi,

I haven't tested this yet but I believe evaluating OrderItemBundleGUID should do the trick. So if OrderItemBundleGUID != null should work, please let me know if it doesn't.

Regards,
Sandro

User avatar
Member
Member
steve - 5/9/2013 8:11:52 AM
   
RE:Macro Question - Product Is Bundle
I tried this from the visible condition of my repeater on my custom document type which inherits from the product document type. I'm not real sure I'm using it correctly, but i can't get it to work, it just disables the repeater on all documents with or without bundles. Below is what I tried.
{% OrderItemBundleGUID != null %}
and
{% CurrentDocument.GetValue.OrderItemBundleGUID != null %}

Thanks for your help.

User avatar
Member
Member
kentico_sandroj - 5/13/2013 7:27:45 PM
   
RE:Macro Question - Product Is Bundle
Hello,

Thank you for the update. So far I have been able to accomplish this by using a WHERE condition with "Hide if no records found":

WHERE SKUProductType != "BUNDLE" will load everything but the BUNDLE products and Hide if no record found will ensure the repeater does not load if there is nothing listed. Would this approach work for you? I am still testing other solutions so if I find something better I will provide an update.

Regards,
Sandro

User avatar
Member
Member
steve - 5/14/2013 1:34:54 PM
   
RE:Macro Question - Product Is Bundle
This is perfect, thank you so much for your help!