Hey,
So I was trying Ben’s solution but with a dynamic list of comma separated numbers instead, so my variable looks something like this:
<dmx-value id="varPerm" dmx-bind:value="'{{sc_userRole.data.m}}'"></dmx-value>
And the variable is returning the correct list of numbers when checked on the console:
However the condition which I have is not working as it should:
<script is="dmx-flow" id="flow1" type="text/dmx-flow" autorun="autorun">{
condition: {
if: "{{varPerm.value.contains(2)}}",
then: {
steps: {
run: {action: "{{browser1.goto('page1')}}", name: "redirect"}
}
}
}
}</script>
Can anyone tell me whats going wrong?