Track shipments

  • Updated

Optimizely Configured Commerce provides an option to display shipment/order tracking information both on the website and in the Admin Console. Displaying this information requires data to exist within the Shipment database tables. Use the information in this article to enable this functionality.

Examples when tracking is enabled

This screen capture shows how the tracking information is displayed on the website within the Order Details section of My Account.

To view the data within the Admin Console, go to Sales > Order History, click View Only for an order and scroll to the Shipping Details section under the Order Lines.

Configure

To see these views, you must have data in the Shipment and ShipmentPackage tables. The ShipmentPackageLines table is an optional table to provide details of products that are within each shipment package.

Shipment refreshes are required to integrate data between Configured Commerce and the ERP.

For testing purposes, populate the Shipment tables to view shipment information in the Admin Console or website. You can use the following queries to add some test data into the database:

-- This adds a shipment package.
INSERT INTO [dbo].[shipment]
            ([shipmentnumber],
             [shipmentdate],
             [emailsentdate],
             [webordernumber])
VALUES      ( 'A1232114',
              '2017-08-22',
              '2017-08-22',
              'WEB001001' )
-- This web order or ERP order number should be an existing web or ERP order. The ERPOrderNumber column can also be used instead.

-- This adds a shipment package related to a shipment.
INSERT INTO [dbo].[shipmentpackage]
            ([shipmentid],
             [carrier],
             -- The value entered in this field needs to match the Name field for a Carrier. These require specific values. See below
             [trackingnumber],
             [freight],
             [packagenumber],
             [shipvia])
VALUES      ( 'F478E1A3-DC88-E711-9487-80000B2CEBFA',
              -- Relative to the shipmentId
              'UPS',
              'Z2321213215903',
              2.00000,
              '1',
              'GROUND' ) 

The Carrier names listed in the table below are examples only. The only requirement is that a Carrier name in the Name field within the Admin Console must match the value entered in the Carrier field in the ShipmentPackage table (referenced above).

You also need to make sure the ERP Ship Code matches the ERP's ShipVia on the Carrier Service. See Create carrier services for more details.

WebOrderNumber is required if you want to send out Shipment confirmation Emails.

Sample Carrier Names

Carrier Tracking Samples URL

UPS

http://wwwapps.ups.com/WebTracking/track?track=yes&trackNums=[trackingnumber]

FEDEX

http://www.fedex.com/Tracking?language=english&cntry_code=us&tracknumbers=[trackingnumber]

Speedee

http://packages.speedeedelivery.com/packages/packages.php?tracking= [trackingnumber]

DHL

http://track.dhl-usa.com/TrackByNbr.asp?ShipmentNumber=[trackingnumber]

OLDD

http://www.odfl.com/trace/Trace.jsp?pronum=[trackingnumber]

If a matching tracking number is not found, the tracking number will not be hyperlinked.