The Custom Address Source functionality allows default values to be populated onto the shipping wizard from any Standard or Custom object on your Salesforce organisation.
You are also able to go as far as to auto create shipments, and auto print the labels from one click once you have this set up.
Please ensure you have upgraded to the latest version of Shipmate before continuing.
The images below describe an example on how you can use this technique to ship to the Case object, but you can choose any object you like.
There are two steps:
- Add Lookup Field to Shipment Object
- Create the Custom Address Source Record
1. Add Lookup Field to Shipment Object
To allow your standard/custom object to be used as a Custom Address Source in Shipmate, you must create a Lookup Relationship on the USPS Shipment object to the standard/custom object you are looking to integrate. This allows your standard/custom object to be associated to the USPS Shipment records and to have a USPS Shipments related list on your standard/custom object. The following steps detail this process.
- Go to Setup | Create | Objects
- Under the Label column, click USPS Shipment.
- Under the Custom Fields & Relationships section, click New.
- Select Lookup Relationship as the Data Type, and click Next. Shown in Figure 1.
- For the Related To value, select the object you want to use as a custom address source, and click Next. Shown in Figure 2.
- Enter in a value for Field Name, and click Next.
- Continue to click Next until you reach Step 6 of the New Relationship wizard.
- Click Save to complete the New Relationship wizard.
Figure 1: Adding Lookup from the USPS Shipment Object.
Figure 2: Select the standard/custom object you want to ship to. In this example, we’ll select Case object.
2. Create the Custom Address Source Record
To connect the standard/custom object as an address source, a Custom Address Source record must be created. The following steps detail this process.
- Go to the USPS Custom Address Sources tab.
- Click on New Custom Address Source. Shown in Figure 3.
- Enter in a value for Custom Address Source Name. Shown in Figure 4.
- For Object, select the object that you want to use as an address source. Shown in Figure 4.
- For Shipment Object Lookup Field, select the Lookup field that was added to the USPS Shipment object in part 1. Shown in Figure 4.
- For the values under the Recipient Address Fields section you can either select a custom field on your object, or use the field selector to navigate to the field needed as you can see in Figure 5.
- Populate the Recipient Address Fields, as a minimum.
- Once all fields are assigned under Recipient Address Fields, click Save.
- Test the Custom Address Source by going to your standard/custom object and click on the New USPS Shipment button. Shown in Figure 6.
- You should then see all the prepopulated fields in the wizard as shown in Figure 7.
Figure 3: After you create the Lookup relationship on USPS Shipment, create a new Custom Address Source.
Figure 4: In our example, Custom Address Source Name is Case, Object is Case and USPS Shipment Object Lookup Field is Case__c. Then map the related Case fields to the USPS Shipment recipient fields as shown.
Figure 5: Field selector. You are able to go 3 levels from your starting standard/custom object. Any related object will have a ">" that once clicked will allow you to select that related objects fields and relationships. Once you have navigated to the correct field click on INSERT to set that field.
Figure 6: Click New USPS Shipment button to be taken to the shipping wizard page with the information pre-populated.
Figure 7: Create a new USPS Shipment and you’ll see your new Address Source (you can also initiate the shipment from the USPS Shipment related list on the lookup object. As shown, data from the mapped fields will be auto-populated).
The last step of our quick start tutorial is One Click Shipping