Skip to main content
Nintex Community Menu Bar
Question

Formula Field Value not updating when formula uses global merge syntax

  • July 10, 2024
  • 3 replies
  • 1 view
  • Translate

Forum|alt.badge.img+13

Formula fields that use global merge syntax are not updating when the data in the merge syntax changes.

Examples:
{{$Model.Account.data.0.Name}}
{{$Model.Account.data.length}}

Steps to reproduce

  1. Create page with XML below
  2. Preview page
  3. Change the first records name

Expected Behavior
Formula field “AccountRow0Name” is updated in all rows

Actual Behavior
Only the row that is changed is updated

  1. Click “+” on table to add a new row

Expected Behavior
AccountRowCount in all rows should reflect the current number of rows and AccountRow0Name should be updated in all rows

Actual Behavior
AccountRowCount and AccountRow0Name in new row are correct but existing rows were not updated

Page XML

<skuidpage unsavedchangeswarning="yes" personalizationmode="server" showsidebar="true" showheader="true" tabtooverride="Account">   <models>
      <model id="Account" limit="20" query="true" createrowifnonefound="false" sobject="Account" adapter="" type="">
         <fields>
            <field id="Name"/>
            <field id="CreatedDate"/>
            <field id="AccountRow0Name" uionly="true" displaytype="FORMULA" label="AccountRow0Name" readonly="true" returntype="TEXT" precision="9" scale="2">
               <formula>{{$Model&#46;Account&#46;data&#46;0&#46;Name}}</formula>
            </field>
            <field id="AccountRowCount" uionly="true" displaytype="FORMULA" label="AccountRowCount" readonly="true" returntype="DOUBLE" precision="9" scale="2">
               <formula>{{$Model&#46;Account&#46;data&#46;length}}</formula>
            </field>
         </fields>
         <conditions/>
         <actions/>
      </model>
   </models>
   <components>
      <pagetitle model="Account" uniqueid="sk-cNOcY-70">
         <maintitle>
            <template>{{Name}}</template>
         </maintitle>
         <subtitle>
            <template>{{Model&#46;label}}</template>
         </subtitle>
         <actions>
            <action type="savecancel" window="self"/>
         </actions>
      </pagetitle>
      <skootable showconditions="true" showsavecancel="false" showerrorsinline="true" searchmethod="server" searchbox="true" showexportbuttons="false" pagesize="10" createrecords="true" model="Account" buttonposition="" mode="read" uniqueid="sk-cNaQf-118">
         <fields>
            <field id="Name"/>
            <field id="AccountRowCount" decimalplaces="" valuehalign="" type=""/>
            <field id="AccountRow0Name" decimalplaces="" valuehalign="" type=""/>
         </fields>
         <rowactions>
            <action type="edit"/>
            <action type="delete"/>
         </rowactions>
         <massactions usefirstitemasdefault="true">
            <action type="massupdate"/>
            <action type="massdelete"/>
         </massactions>
         <views>
            <view type="standard"/>
         </views>
      </skootable>
   </components>
   <resources>
      <labels/>
      <css/>
      <javascript/>
   </resources>
   <styles>
      <styleitem type="background" bgtype="none"/>
   </styles>
</skuidpage>
Did this topic help you find an answer to your question?

Forum|alt.badge.img+11

Barry~

Thanks for reporting this bug. The devs are aware of it and will consider it for a future release. This post will be updated when a fix is available. 

Thanks!
Karen

Translate

Forum|alt.badge.img+13

Thanks Karen!

Translate

Forum|alt.badge.img+4

Has this been fixed?  I think I’m having a similar issue: I have a formula field in a UI-only model that uses global merge syntax to check whether conditions on other models are inactive, e.g., {{$Model.MyModel.conditions.2.inactive}}.  The formula result does not update in real time when the referenced condition is activated.  However, if a new row is added to the UI-only model, the new row shows the correct formula result.  I thought maybe this was only an issue on a UI model so I tried adding the UI formula field to a model tied to a Salesforce object and had the same problem where the formula result did not update in real time.

Thanks for any help or info on this!

Translate

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie Settings