taucher
Posts: 0
Joined: Fri Apr 17, 2015 6:06 am

Array to List Mapping With Adding Custom String

Hello,

I get a list of houses with prices from my rest service. The price and the price type($,€) are in different columns. When mapping to UI, how can i add the type at the end of the price label. ( Need to check if it is $, then add $. For € is needed also)

Thank you,

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

Array to List Mapping With Adding Custom String

Hello,

Please add JS for the mapping $-listItem:

$(element).find("[name=priceLabel]").text(value.price + value.type);

here priceLabel - label with the price value

taucher
Posts: 0
Joined: Fri Apr 17, 2015 6:06 am

Array to List Mapping With Adding Custom String

Hello Sergiy,

Thank you so much! Done.

Regards,

Return to “Issues”