cancel
Showing results for 
Search instead for 
Did you mean: 

VizFrame : How to bind using i18n model in FeedItems values

former_member762375
Discoverer
0 Kudos

<viz.feeds:FeedItem uid="categoryAxis" type="Dimension" values="{i18n>sales}" />

Accepted Solutions (0)

Answers (2)

Answers (2)

vneecious
Advisor
Advisor

You can't. That's not the purpose of the Resource Model. Use JSON Model instead.

michaelschmid03
Explorer
0 Kudos

I mean thats great and all,but what is the alternative how can i have a Vizchart where the column names are translated?

Edit just found out about Expression Bindings and got it working

michaelschmid03
Explorer
0 Kudos

Hey i know this is a old Topic but since i've needed a solution for this and it havent been posted by anyone else im writing this for future Users encountering this issue.

If you encounter properties that dont support regular bindings, you can use so called "expression bindings"

<vizData:DimensionDefinition
name="{= [${i18n>week}] }"
id="idDay"
value="{Day}"
/>


Binding a translatable name to a DimensionDefinition.

And this might not be relevant directly to the question but heres a interesting way i had to implement expression bindings. They work on almost every ui5 property when working with xml

<viz:VizFrame
xmlns="sap.viz"
height="60%"
width="100%"
id="idDualStackedChart"
vizType="dual_stacked_column"
selectData="onVizFramePress"
vizProperties="{={title:
{text: ${i18n>pieces}},
plotArea:{ colorPalette: [['lightblue','orange','lightgreen'],['blue','green']]},
legendGroup: {layout: {
position: 'bottom',
alignment: 'center'
}}}}"
>​