About
The Machship plugin provides an interface between Jiwa and the Machship freight platform via the Machship API.
Consignments in Machship can be created from a sales order in Jiwa, and the consignment information and freight items on a Jiwa sales order updated from Machship
Deployment
Prerequisites
Jiwa REST API Plugin
The Machship plugin has a dependency on the Jiwa REST API plugin, so this plugin must first be enabled.
Open the Plugin Maintenance form in Jiwa, and locate the REST API plugin and ensure it is enabled.
Import plugin
Open the Plugin Maintenance form in Jiwa, and locate any other freight integration plugins (such as IFS) and disable and save those.
Import the Machship plugin and ensure it is enabled and save.
SQL Script
A SQL Script attached to the documents tab of the Machship plugin, Machship.sql, should be run against your database. This script will create the required Machship freight descriptions against each carrier.
Configuration
Exit Jiwa and log back in after the deployment steps before proceeding to the following configuration steps.
System Configuration
Open the System Configuration Form, and on the Machship tab, enter the Machship API Token provided to you by Machship.
Also on the same tab of the System Configuration Form, you can also optionally set a Placeholder Freight Item. Machship requires at least one freight item when creating a consignment, and setting this value allows a sales order to have a consignment created in Jiwa with no freight items.
Warehouse Maintenance
Open the Warehouse Maintenance form in Jiwa, and for each Physical Warehouse which will be creating consignments in Machship, enter the Machship Company Id.
The Machship Company Id is obtained from the companies view of the Admin sections of the Machship portal. Whilst the Company Id is not visible on the page, it is revealed in the URL when a company is selected.
Also on the Custom Fields tab, select a Jiwa Staff member as the Freight Contact
Ensure also the Address and Phone fields are correct. The Address fields are used by Machship to determine the pick up location of the consignment and is a factor in selecting carriers, services and thus freight charges.
Carrier Maintenance
Carriers and their services in Jiwa are matched to Carriers in Machship by name.
So, Carriers in Jiwa need to be enabled and have the same name as carriers in Machship, and the same applies to the Services.
Freight Descriptions (Freight Items in Machship) are fixed and the same for all carriers in Machship, and the SQL Script run previously in this guide would have created these Freight Descriptions for all carriers.
Freight descriptions which were already attached to the carrier when the script was run that did not match the Machship Freight Items will have been disabled by the script.
Creating Consignments
Consignments are created in Machship by either the user pressing the Send to Freight System button on a sales order, Freight tab - or by invoking a REST API route
/SalesOrders/{InvoiceID}/SendToFreightSystem
.
Setting a Carrier or Service selection before creating the consignment is optional.
Machship will select the carrier and service based on its own rules, and Jiwa will be updated with the carrier, service and freight items from Machship.
On the Freight tab of a sales order, change the Status to Ready To Send and press the Send To Freight System button to create a consignment.
Jiwa will be updated with the Carrier, Service and Freight items from Machship.
If no freight items were on the sales order when initially sent, then a freight item “Item 01” of dimensions 1x1x1 and weight 1Kg is automatically added.