Hello all. I want to add the packing information f...
# advancedpdf
a
Hello all. I want to add the packing information from the item fulfillments onto the Advacnced PDF. Is this accomplished via #list ? If so, what is the syntax? <#list record.package> ?
✔️ 1
p
Going by the record browser
record.package
would be correct. Have you tried this and does it work?
a
@PenguinsOfDoom Thanks! I have not tried it yet. Did not want to waste time if it was not the correct idea, haha. I will give it a try and share my experience. Thank you.
The following is what I wrote but nothing appears on output PDF.
Copy code
<#if record.package?has_content>
<table class="itemtable" style="width: 100%;"><!-- start items --><#list record.package as tranline><#if tranline_index==0>
<thead>
	<tr>
	<th align="center" colspan="15" font-size="10px">Weight</th>
	<th align="center" colspan="6" font-size="10px">Length</th>
	<th align="center" colspan="5" font-size="10px">Width</th>
	<th align="center" colspan="5" font-size="10px">Height</th>
	<th align="center" colspan="5" font-size="10px">Tracking Number</th>
	
	</tr>
</thead>
</#if>
  
  <tr>
    <td align="left" colspan="15" font-size="10px"><span class="itemtable"><b>${tranline.packageweightups}</b></span></td>
	<td align="center" colspan="6" font-size="10px">${tranline.packagelengthups}</td>
	<td align="left" colspan="5" font-size="10px">${tranline.packagewidthups}</td>
	<td align="center" colspan="5" font-size="10px">${tranline.packageheightups}</td>
	<td align="center" colspan="5" font-size="10px">${tranline.packagetrackingnumberups}</td>
	</tr>
	</#list><!-- end items --></table>
p
As in no data appears or the whole table doesn't appear?
Also, from a personal preference, I wouldn't call it tranline for this because it isn't really one, I'd use a more meaningful name like packageline. That also means you wouldn't have any conflicts if you are also using tranline for the actual transaction lines
a
Very true. Yes, the changes save without an error but the pdf does not output any information. I will change it to packageline, good call.
p
If you aren't already, I'd suggest using the NetSuite Field Explorer plugin to confirm the field and sublist names https://chrome.google.com/webstore/detail/netsuite-field-explorer/cekalaapeajnlhphgdpmngmollojdfnd?hl=en
a
Already using it 🙂
They are correct.
The table does not even show up with the column headers.
p
Doing exactly what you have done above works for me. Does your fulfilment definitely have packing information and is the template you are using definitely the one that is being printed?
message has been deleted
a
I will check both again but I thought I had them. Let me check
I have 3 packages and its definitely the correct template. I'll work with it some more.
@PenguinsOfDoom Your code produced which part of that image? The tracking number at the bottom?
Nevermind. I figured it out. Thank you for your help @PenguinsOfDoom