Displaying records based on a field's value

Posted by Rollbase User on 16-Mar-2010 22:42

I am trying to create a portal for my loyalty rewards application. My Loyalty member object contains a membership type (bronze, silver, or gold). Now I want my Loyalty member to view records from the Available for Redemption object that has the same membership type. Is there a way that in my portal, my object selector for Available for Redemption check the membership type of my Loyalty Member then whichever its type is, it would display the corresponding view ( a view for bronze, silver or gold)?

All Replies

Posted by Admin on 16-Mar-2010 23:04

There is no direct way to filter records dynamically based on value of another record. You can, however, build a template which utilizes EVAL[ ] blocks. Something like this:
{!LOOP_BEGIN}
#EVAL[ {!cond}==true ? "{!LINK}" : "" ]
{!LOOP_END}

Posted by Admin on 17-Mar-2010 01:57

I tried your suggestion but I get this error using this script

{!LOOP_BEGIN.all#8681333}
#EVAL[ {!membership_type#value}=='Bronze' ? "{!id}" : "" ]
{!LOOP_END}

What seems to be the problem?

Posted by Admin on 17-Mar-2010 09:37

Well, you need to use quotes on the other side of comparison.

Also, I'm considering to enhance Rollbase views filtering capabilities to include expressions. Stay tune.

This thread is closed