on GitHub" data-tooltip-id=":R1blcldb:">v2.5.1·Edited Jan 6·
This document showcases the module links defined between the Stock Location Module and other commerce modules.
The Stock Location Module has the following links to other modules:
FulfillmentSet
data model of the Fulfillment Module <> StockLocation
data model.FulfillmentProvider
data model of the Fulfillment Module <> StockLocation
data model.StockLocation
data model <> Inventory
data model of the Inventory Module.SalesChannel
data model of the Sales Channel Module <> StockLocation
data model.A fulfillment set can be conditioned to a specific stock location.
Medusa defines a link between the FulfillmentSet
and StockLocation
data models.
Medusa also defines a link between the FulfillmentProvider
and StockLocation
data models to indicate the providers that can be used in a location.
To retrieve the fulfillment sets of a stock location with Query, pass fulfillment_sets.*
in fields
:
fulfillment_providers.*
in fields
.To manage the stock location of a fulfillment set, use Link:
Medusa defines a read-only link between the StockLocation
data model and the Inventory Module's InventoryLevel
data model. This means you can retrieve the details of a stock location's inventory levels, but you don't manage the links in a pivot table in the database. The stock location of an inventory level is determined by the location_id
property of the InventoryLevel
data model.
To retrieve the inventory levels of a stock location with Query, pass inventory_levels.*
in fields
:
A stock location is associated with a sales channel. This scopes inventory quantities in a stock location by the associated sales channel.
Medusa defines a link between the SalesChannel
and StockLocation
data models.
To retrieve the sales channels of a stock location with Query, pass sales_channels.*
in fields
:
To manage the stock locations of a sales channel, use Link: