on 02-23-2024 3:47 PM
Hello experts,
I am struggling with the syntax to embed UDF values in FSM HTML Checkout report.
I analyzed the data.js file and the UDF value are displayed in this format:
However, how should the syntax in the template.js look like? I tested different versions (e.g. udf.MILEAGE_NOTES) but they are not working...
Can someone please help?
Thanks a lot!
Best regards,
Deborah
@krzysztof_szalach Do you have a tip?
As addition for the community - here the code if there are multiple UDF value and you have to loop over it:
if (columnDefinition.operator == 'concat') {
return columnDefinition.aggregate.map(prop => {
//Custom, UDF handling (line 25-33 custom)
if (prop.startsWith('udfValue.')) {
let udfValue = prop.split('.')[1];
for (const element of context.udfValues){
if (element.meta.name === udfValue){
return element.value;
}
} return "";
} else {
return Handlebars.helpers.get(prop, context);
}
}).reduce((acc, current) => acc + ' ' + current, '');
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
10 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.