When conditional rendering based on model property number of rows is applied to a component, the rendered result is incorrect.
This appears to be a regression of https://community.skuid.com/t/conditional-rendering-model-property-number-of-rows-issu……
Steps to Reproduce:
- Create Page using sample xml below
- Preview page picking account
Expected Result
Templates “Show if RowCount > 0”, “Show if RowCount >= 1”,“Show if RowCount == 1” are displayed
Actual Result
Template “Show if RowCount != 1” is displayed
Note - The sample page below works as expected on 6.8.20
Sample Page XML
<skuidpage unsavedchangeswarning="yes" showsidebar="true" showheader="true" tabtooverride="Account" personalizationmode="server"> <models> <model id="Account" limit="1" query="true" createrowifnonefound="false" sobject="Account">
<fields>
<field id="Name"/>
<field id="CreatedDate"/>
</fields>
<conditions>
<condition type="param" enclosevalueinquotes="true" operator="=" field="Id" value="id"/>
</conditions>
<actions/>
</model>
</models>
<components>
<pagetitle model="Account" uniqueid="sk-3Zk7mZ-58">
<maintitle>
<template>{{Name}}</template>
</maintitle>
<subtitle>
<template>{{Model.label}}</template>
</subtitle>
<actions/>
</pagetitle>
<template multiple="false" uniqueid="sk-3ZkHGo-82" model="Account">
<contents>Show if RowCount &gt; 0</contents>
<renderconditions logictype="and">
<rendercondition type="fieldvalue" enclosevalueinquotes="false" fieldmodel="Account" sourcetype="modelproperty" nosourcerowbehavior="deactivate" sourceproperty="data.length" operator="gt" value="0"/>
</renderconditions>
</template>
<template multiple="false" uniqueid="sk-3ZkdpN-129" model="Account">
<contents>Show if RowCount &gt;= 1</contents>
<renderconditions logictype="and">
<rendercondition type="fieldvalue" enclosevalueinquotes="false" fieldmodel="Account" sourcetype="modelproperty" nosourcerowbehavior="deactivate" sourceproperty="data.length" operator="gte" value="1"/>
</renderconditions>
</template>
<template multiple="false" model="Account" uniqueid="sk-3Zk7mZ-59">
<contents>Show if RowCount == 1</contents>
<renderconditions logictype="and">
<rendercondition type="fieldvalue" operator="=" enclosevalueinquotes="false" fieldmodel="Account" sourcetype="modelproperty" nosourcerowbehavior="deactivate" sourceproperty="data.length" value="1"/>
</renderconditions>
</template>
<template multiple="false" model="Account" uniqueid="sk-3Zk7mZ-60">
<contents>Show if RowCount != 1</contents>
<renderconditions logictype="and">
<rendercondition type="fieldvalue" operator="!=" enclosevalueinquotes="true" fieldmodel="Account" sourcetype="modelproperty" nosourcerowbehavior="deactivate" sourceproperty="data.length" value="1"/>
</renderconditions>
</template>
<template multiple="false" model="Account" uniqueid="sk-3Zk7mZ-61">
<contents>Row Count = {{$Model.Account.data.length}}</contents>
</template>
</components>
<resources>
<labels/>
<css/>
<javascript/>
</resources>
<styles>
<styleitem type="background" bgtype="none"/>
</styles>
</skuidpage>