badgerdigital
01/06/2020, 4:37 PMstoredisplayname
field or a custom field, the engine always renders one of the items in the list and then repeats that value for all items. For example, with this simplified code snippet (only the essential markup/code remains).... we get the following result.... Anyone else run into this issue? Any hacks or workarounds?
<#list salesorder.item as itemline>
<table>
<tbody>
<tr>
<td><img src="${itemimages[itemline.item.internalId]}"/></td>
<td>${itemline.item.storedisplayname}<br/>by ${itemline.item.custitem_manufacturer}
</td>
<td>${itemline.quantity}</td>
<td>${itemline.amount}</td>
</tr>
</tbody>
</table>
</#list>
Steve Goldberg
01/06/2020, 6:08 PMstoredisplayname
has/had issues and so isn't typically used. I am curious if this problem occurs if you try to get the item name through alternative means. Typically, there is a bit of a fandango to get it but you can do something like this to get the name:
<#assign itemName = itemline.item?split(":")>
... [some code later] ...
${itemName[itemName?size-2]?trim}
Steve Goldberg
01/06/2020, 6:09 PMSteve Goldberg
01/06/2020, 6:14 PM<tbody>
or <tr>
but rather unusual with whole tables. Am curious as to whether some previous markup or FreeMarker stuff is tripping you upbadgerdigital
01/06/2020, 7:41 PMdescription
field out of the item sublist. However, any custom field just continually repeats.
Regarding your parse/split solution. When we brought back the item
property, it was only bringing back the SKU (name).
As for the table, I see what you mean. Our Marketing team had used the Bronto designer and order notification integration to create the email notification, so that's where the multiple tables came from. I was porting it to a system email template as Bronto doesn't store a copy of the sent email in the ERP and that has caused some issues for our CS team.