Using a Saved search PDF template, is it possible ...
# advancedpdf
s
Using a Saved search PDF template, is it possible to print #list of items? • Using custbody field of type: inline html to generate a button • Button prints using internalid of saved search and internalid of pdf template Goal: to print Vendor Return just like a PO PDF • Works great except it only prints the first line item. • e.g. if there are 5 line items, I need it to print all 5.
e.g. Saved search shows 1. Transaction 1 | Item 1 2. Transaction 1 | Item 2 3. Transaaction 2 | Item 1 When I click the custom button it prints Transaction 1 | Item 1 on page 1 Then Item 2 on page 2
d
not seen it done before with an inline HTML button pointing to a saved search-pdf template, but it might work. I have it working with the typical: UE adds button that points to a SL that renders the record/transaction using a 'normal' PDF template
šŸ‘€ 1
If you can, I would suggest to do it that way. Pros/Cons off the top of my head: Pros: • print button appears at the top, where user is expecting to find the print button • access to all of the transaction fields without having to add them each as a result column • can use 'standard' template references to fields instead of all fields being within a result 'row' • potentially more performant? • *the method is well documented online by several people/websites Cons: • have to set up at least one UE script and one SL script (but if you're clever you can reuse them for all custom print buttons that you want to do)
s
Thanks for the great breakdown @David B
šŸ‘ 1
n
Thank you so much @David B, for a detailed explanation.
šŸ‘ 1
d
These should be enough to get you going @NS User: SuiteAnswer 41269 : Create Custom Print Packing Slip Buttons on an Item Fulfillment using nlapiPrintRecord
Official SuiteAnswer example to give you a general idea
Netsuite Advanced PDF/HTML templates for any record type
Michoel's SS1.0 example. Nicely shows that you can call the Suitelet directly from the UE without needing to have a client script (recommended)
Left Ledger | Oracle NetSuite Customer Relationship Management CRM | NetSuite Customization
A great SS2.0 example, although uses the unnecessary UE>CS>SL pattern. Well formatted. Would recommend following this but swapping in the UE>SL method that Michoel's example shows
pdf - Netsuite Custom Print Button to HTML Template - Stack Overflow
Someone doing a custom VRA custom print from 7 months ago. A great reference
Stackoverflow has lots of examples of people doing custom print buttons with the UE>CS>SL method, if you need more reading And of course, make sure to keep the docs for the N/render module open
šŸ™ 1
n
@David B @Stephan Vagner - Could you also please advise on creating a PDF template for Vendor Return Authorization? I have created a transaction saved search with type=vendor return authorization and pulled columns as vendor name, bill to address, memo, item, qty, rate, and amount. Is this the only way to do it? Or Is there any other way for this? I appreciate your quick response on this.
d
my recommendation to Dway is to not print using a saved search, and instead print using N/render to add the entire VRA to the template as 'record'. Should be able to find examples online of VRA templates
šŸ‘ 1
šŸ™Œ 1