Subscribe
Blog

Automatically Generate Packing Slips from Salesforce Opportunities

Formstack
July 14, 2018
|
Min Read

With a tool like Salesforce, you can organize your entire sales process from lead to sale to delivery.  With its robust tracking and automation features, Salesforce can keep your entire team on point.

Another way you can improve your sales process is by using Formstack Documents to automatically generate documents like contracts, invoices, quotes, and more.  For this example, we’re going to show you how to automatically send a packing slip to your shipping department when an Opportunity in Salesforce is updated to “Ship Order”.

To get started, we’re going to setup the template of our packing slip using a fillable PDF.  Using a PDF editor, we’re going to add fields where we want the order information to go.  Here’s what our packing slip template looks like:



Once we have our template ready to go, we need to upload it to Formstack Documents.  From the Documents page in Formstack.com, click the New Document button and enter a name.  On the next step, select Fillable PDF as the document type and then pick the file from your computer.


After we have uploaded our template, we’ll be taken to the Settings tab where we can modify various options like the type of file that is generated and the name of the file.  For this example, we’re going to generate a PDF and then we’re going to include the opportunity ID in the file name.

In our PDF, we have line items that we’ll need to pull from a list of line items coming over from Salesforce.  To do this, we need to use the Field Map which you can turn on under Advanced Settings.


Next, we’re going to setup the Field Map.  Head on over to the Field Map tab and you’ll see a list of all the fields in your PDF.  For the line items fields, we’re going to add merge fields like {$LineItems.0.Name}, {$LineItems.1.Name}, etc.


Next, we’re going to setup the delivery of our document so that it is automatically emailed to our shipping department for processing.  Under the Deliver tab, we’re going to edit the default email delivery.  For the To address, we’re going to enter the email address of our shipping department.  Feel free to change any of the other settings.


Once we have our email delivery finished, we’re done with the setup process in Formstack Documents and we’re ready to integrate with Salesforce.

For the integration, we’re going to use the Formstack Documents managed package that you can install from the AppExchange.

Inside Salesforce, we’re going to setup a new Mapping for our packing slip.  On the New Mapping page, we’re going to give the mapping a name and then we’re going to select Opportunity as the Salesforce object, then pick the Packing Slip document that we just setup in Formstack Documents.


On the next step, we’re going to match up all of our merge fields with the corresponding fields in Salesforce.  This tells the managed package how to pull data from Salesforce and send it over to Formstack Documents so that it is populated in the correct spot on our document.



So that our packing slip is automatically generated when the opportunity is completed, we’re going to use the Process Builder.  Go ahead and create a new process, and we’re going to monitor the Opportunity object and watching for a change to the status.



Now we’re ready for a test!  Open up one of your opportunities and then update the status to trigger your process builder to run.  The managed package will then send your opportunity information over to Formstack Documents and your packing slip will be sent to the shipping department via email.

Here’s what our packing slip looked like:



Now, you can automatically generate all types of documents from your Salesforce org.  Start a free trial of Formstack Documents today to start simplifying your paper-based processes.

Blog

Formstack's Subaccount Model Through an Olympic Lens

We use Team USA to explain the useful Formstack subaccount model
Read more
Formstack
Formstack is a SaaS company with a mission to help organizations digitize what matters, automate workflows, and fix processes—all without code. A variety of team members come together to compile posts under Formstack's authorship.
More Articles