- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-27-2022 11:56 AM - edited 10-27-2022 11:57 AM
Good Evening,
I have a really odd problem, assigning some text to a data object but it won't display correctly on the html template.
Server Side:
var config = new GlideRecord(gs.getProperty('table'));
config.addQuery('number', 'LIKE', data.parent_configuration);
config.query();
if(config.next()) {
data.desc2 = config.description;
}
Html:
<div ng-if="data.show_desc == 'true'">{{data.desc2}}</div>
Result:
Result is an empty Object but when I check the logs, I can see its being picked up correctly:
Not sure what I am doing wrong... sigh
Any Ideas?
Kind Regards
Ashley
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2022 05:55 AM
Good Afternoon,
Thank you all for the replies, I managed to resolve it, a few hours lost and all I needed to do was add .toString() on the end.... doh
End Result:
data.desc2 = config2.description.toString();
Kind Regards
Ashley
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-28-2022 05:55 AM
Good Afternoon,
Thank you all for the replies, I managed to resolve it, a few hours lost and all I needed to do was add .toString() on the end.... doh
End Result:
data.desc2 = config2.description.toString();
Kind Regards
Ashley