Quantcast
Channel: SCN : All Content - SAPUI5 Developer Center
Viewing all articles
Browse latest Browse all 6178

Calculated field does not update after change of child element

$
0
0

Hi,

 

I am using a calculated field to join the values of an array, which contains objects, into a single text string. This uses the following syntax:

<Text text="{path:'Values', formatter:'.formatter'}" />

The Values array contains objects that look similar to that:

{     value: "Hello",     enabled: true
}

The .formatter function should join together the value of all enabled objects.

 

Now, when I change the Values array directly, i.e., when I add or remove an element from the array, the text element is updated automatically.

However, when I change the "enabled" property of one of the elements, the .formatter function is not triggered and the text element does not change its content.

 

The only solution I found so far is a refresh(true) after the property change on the underlying model. However, this model is bound to many other controls in my application so that a large rerendering is triggered. This slows down the application significantly and would only be a solution if nothing else helps.

 

Does anybody know another way to trigger a reevaluation of the calculated field?


Viewing all articles
Browse latest Browse all 6178

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>