Page tree
Skip to end of metadata
Go to start of metadata

Overview

 

Order exporter framework allows to create arbitrary export implementation that are bound to specific order export eligibility.

The main process is facilitated by a cron (recurring) job that retrieves all orders that have export eligibility status set. This job uses order's shop (i.e. shop where order is placed) in order to retrieve configurations for the bound exporters. If applicable exporter is determined export is executed.

Once an exporter is executed it can either: 

  • do nothing, which means that export eligibility property of the order is set to empty; or 
  • set next eligibility state for the order, which will be picked up by another exporter in the next export cycle, thus creating a chain of exports

Default export eligibility states

 

TransitionStateNotes
Payment (both online and offline) is confirmed for the order. This is the initial payment confirmation transition.INITPAIDUsed as the initial order export hook. Exporters can use this state in order to export newly created paid order.
A delivery has been set to a "shipment completed" stateDELIVERYCould be used by exporters to notify third party systems of the completed delivery. Note that this may not necessarily indicate that all deliveries are shipped
Full order cancellationCANCELLEDMay be used to notify fulfilment systems of the cancellation. Cancellation indicates orders that have not yet been shipped
Full order returnRETURNEDMay be used to notify fulfilment systems of the return of the items that were shipped previously.

Default exporters

 

Supplier email notification exporter

 

Supplier email notification exporter is a basic order exporter that sends email notification to specified supplier with only items that are applicable to be full filed by this supplier. Supplier in this context refers to specific fulfilment centre.

In order to enable this exporter for a given shop business user can use SHOP[ORDER_EXPORTER_MAIL_SUPPORTED_SUPPLIERS] attribute, which is of type Property and should contain mapping of [Fulfilment Center Code].[Export eligibility]=[CSV of emails to send the email to]

Example configuration for Fulfilment centre with code "Main" and "Secondary" to export when "INITPAID" eligibility is set:

Main.INITPAID=neworder@mainff.com
Secondary.INITPAID=specialorder@specialff.com,viporders@specialff.com

 

Manual state proxy

 

Manual state proxy is not a real exporter but rather is a tool to set the desired export eligibility state on the order and also to facilitate manual export flows for specific eligibilities i.e. when export button appears in Admin app for the order and requires business user to click if to actually "approve" the export.

Manual export flow is achieved by setting "Block export" flag if necessary to enable manual export flow for a specific export eligibility.

In order to enable this exporter for a given shop business user can use SHOP[ORDER_EXPORTER_MANUAL_STATE_PROXY] attribute, which is of type Property and should contain mapping of [Fulfilment Center Code].[Export eligibility]=NEXT|BLOCK or NEXT|UNBLOCK

For example business requirement is not to automatically send email notification to suppliers via "Supplier email notification exporter" but rather put the order into blocked state with EMAILNOTIFY eligibility. Then bind the "Supplier email notification exporter" to EMAILNOTIFY. Thus when manual export button is pressed in Admin app the exporter will proceed with EMAILNOTIFY.

Example configuration for blocking default INITPAID export eligibility to EMAILNOTIFY and enable the manual export button in Admin app:

INITPAID=EMAILNOTIFY|BLOCK

And then "Supplier email notification exporter" configuration would be set to:

Main.EMAILNOTIFY=neworder@mainff.com
Secondary.EMAILNOTIFY=specialorder@specialff.com,viporders@specialff.com
  • No labels