background

Zenkraft Blog

Zenkraft Blogs about Logistics, LSPs, Integration with CRM, ERP and WMS applications.

Generate return labels from web2lead

Published on 13 March 2019 by in multi-carrier returns 

A very easy, almost non-code way to offer self-service return label generate on your website is using Salesforce's popular web2lead capabilities. We've outlined the steps below to get this setup. 

 

1.Generate the web2lead code

Login to your Salesforce instance and go to Setup > Customize > Leads > Web-2-Leads. Click the Create Web-2-lead Form button. The following fields are required to create a shipping label:

 

We will hide the lead Source field. You should add a new lead source called something like Requested Shipping Label.

 

2. Embed form on your website

Next you should embed the web-2-lead form on your website. The only change we need to make is to apply style="display:none" to the Lead Source section and default it to Requested Shipping Label. This will enable us to run a process builder task of this lead source.

 

3. Install the Multi-carrier app 

Next you should install our Multi-carrier app. Follow the guide here to get setup: https://zenkraft.com/docs/salesforce-multi-carrier

 

You will need to create a custom address source that looks up to the Lead object. Here is the guide: https://zenkraft.com/docs/multi/custom-address-source

 

4. Setup a process builder on the lead to send a label

Once the Multi-carrier app is setup and you have added a Preference for your shipping carrier (a test FedEx account is available here) you can create a process builder task. You will need to set the Lead Status = Requested Shipping Label as below:

 

 

Next selected an Immediate Action. And choose Apex Class and Create Shipment. You should enter the Custom Address Source ID that you created in step 3 and set the recordId as a field Reference of Lead ID. 

 

 

 

5. Setup a second Process Builder to Send the label

Now that a shipping label will be generated when a web-2-lead form is submitted, we now need to email it to the customer. This can be done with a second process builder task based on the Shipment object:

 

 

That's it! Now it's time to try it out by completing your web-2-lead form. You should receive a shipping label in under 10 seconds via email. 

 

Continue reading »

Status Exception Report

Published on 08 May 2018 by in returns 

This report will show you a list of shipments which have an atypical status description for example stuck at customs, held at UPS location or customer unavailable.

Step 1

Create a report for ‘UPS Shipments’

Step 2

Add the following fields:

  • UPS Shipments: UPS Shipment Number
    UPS Checkpoint: UPS Checkpoint Name
    Status Exception Description
    Event Description
    Recipient Name
    Recipient Phone
    Email Recipient

Add the following filter:

Status Exception Description not equal to “” (Empty)
AND Delivered = “False”

Tip – You can also filter by date to show you most recent shipments.

Step 3

Save the report

Final Result

Continue reading »

Report on unused RMA labels

Published on 01 May 2018 by in salesforce fedex reports returns 

If you have sent our an RMA label for a customer to return a faulty product, this report will show you exactly how many of them are still outstanding.

Step 1

Create a report for ‘UPS Shipments with Order’

Step 2

Add the following fields:

UPS Shipment: UPS Shipment Number

Status Description

Order: Order Number

Recipient Name

Recipient Phone

Add the following filters:

Returns Shipment = “True”

AND Delivered = “False”

This will allow you to produce a call list of those customers who have received returns labels but have not used them yet.

Step 3

Save the report

Final Result

Continue reading »

Multiple Package Returns for UPS and Auto Printing

Published on 28 February 2017 by in ups returns 

This weeks post will detail how to achieve the following using our package, and some apex code.

  • Multiple Package Returns for UPS
  • Auto Printing

Multiple Package Returns for UPS

Currently the UPS api only allows the creation of 1 return label at a time. So if you want to create 20 return labels at once you need to set up a batch process to create them individually but group them into a Bulk Shipment which then allows you to print them all off at once.

We first need a method to create our bulk shipments, which we then reference later on in a loop.

Line 2: create a new queuedShipment object.

Line 3: set this new queuedShipment to be in the bulkShipment object.

Line 4-9: Sets the payment type, service type, units, labeltype, packaging type and the account this shipment is related to.

Lines 12-20: sets the sender address from the shipping preference.

Lines 23-30: set the recipient address details from the account.

Liens 33-35: set the values needed to create a return shipment.

 

Then we utilise a loop for the number of labels we will be creating. The code to loop through and to eventually send the shipments to be created is here:

Line 5: Create the bulkShipmentId that we will then send for processing after we have created the queuedShipments

Lines 10-21: This is the for loop where we go through creating the list of queuedShipments and creating the packages that are also required.

Line 28: is where we send the bulkShipment to be processed.

Lines 44-55: show how to create the packages.

 

Auto Printing

Our package is already setup to auto print a shipment label and all related documents from the shipment view page. All you need is the salesforce id of the shipment that has been generated. After shipment creation, you need to redirect the user to the shipment using the code below, and as long as you have setup the users default printers in the “Manage Printers”, the printing of all the labels and documents related to that shipment will automatically print on the respective printers. For example if you have a thermal shipping label and an international document, they will be printed to the thermal printer and to the laser printer respectively.

String redirectUrl = ‘/apex/zkups__ShipmentViewV2?autoprint=1&id=’ & shipmentId;

Any questions, please contact us and we will be happy to help you out.

Continue reading »