public interface FulfillmentLocationService
| Modifier and Type | Method and Description |
|---|---|
FulfillmentLocation |
createNew()
Creates a new instance of a FulfillmentLocation.
|
void |
delete(FulfillmentLocation fulfillmentLocation)
Deletes the passed
FulfillmentLocation |
List<FulfillmentLocation> |
findAll()
Retrieves all of the fulfillment locations
|
List<FulfillmentLocation> |
findAllFulfillmentLocations(org.broadleafcommerce.core.order.service.type.FulfillmentType fulfillmentType)
Gets all of the fulfillment locations for the specified fulfillment type.
|
List<FulfillmentLocation> |
findAllFulfillmentLocationsForSku(Long skuId)
Returns all fulfillment locations associated with a
Sku. |
List<FulfillmentLocation> |
findAllFulfillmentLocationsForSku(Long skuId,
org.broadleafcommerce.core.order.service.type.FulfillmentType fulfillmentType)
Returns all fulfillment locations associated with a sku for a particular fulfillment type.
|
List<FulfillmentLocation> |
findAllFulfillmentLocationsForSku(Long skuId,
org.broadleafcommerce.core.order.service.type.FulfillmentType fulfillmentType,
int minimumQuantity)
Returns all fulfillment locations associated with a sku for a particular fulfillment type and has at least enough
inventory as quantity.
|
FulfillmentLocation |
findById(Long fulfillmentLocationId)
Retrieves a
FulfillmentLocation from the given id |
FulfillmentLocation |
findDefaultFulfillmentLocation()
Returns the first default fulfillment location found.
|
FulfillmentLocation |
save(FulfillmentLocation fulfillmentLocation)
Persists the
FulfillmentLocation |
void |
updateOtherDefaultLocationToFalse(FulfillmentLocation fulfillmentLocation)
Updates all
FulfillmentLocations in the database to false, excluding the FulfillmentLocation that was
passed in |
List<FulfillmentLocation> findAll()
List of FulfillmentLocationFulfillmentLocation findById(Long fulfillmentLocationId)
FulfillmentLocation from the given idfulfillmentLocationId - FulfillmentLocationFulfillmentLocation save(FulfillmentLocation fulfillmentLocation)
FulfillmentLocationfulfillmentLocation - FulfillmentLocationvoid delete(FulfillmentLocation fulfillmentLocation)
FulfillmentLocationfulfillmentLocation - FulfillmentLocation findDefaultFulfillmentLocation()
List<FulfillmentLocation> findAllFulfillmentLocationsForSku(Long skuId)
Sku. This does not take into account any matching
fulfillment types.List<FulfillmentLocation> findAllFulfillmentLocationsForSku(Long skuId, @Nullable org.broadleafcommerce.core.order.service.type.FulfillmentType fulfillmentType)
findAllFulfillmentLocationsForSku(Long)skuId - fulfillmentType - (optional) the type of FulfillmentLocation to look forFulfillmentLocations that can be found for the given Sku. If the given fulfillmentType
is null or FulfillmentType.PHYSICAL_PICKUP_OR_SHIP then the resulting list could be fulfillment locations
that have either FulfillmentType.PHYSICAL_PICKUP_OR_SHIP, FulfillmentType#SHIP or
FulfillmentType.PHYSICAL_PICKUPList<FulfillmentLocation> findAllFulfillmentLocationsForSku(Long skuId, @Nullable org.broadleafcommerce.core.order.service.type.FulfillmentType fulfillmentType, int minimumQuantity)
skuId - the Sku to look upfulfillmentType - (optional) type of FulfillmentLocation to look forquantity - filters the list of FulfillmentLocations by ones that have enough of this quantityFulfillmentLocations that can be found for the given Sku. If the given fulfillmentType
is null or FulfillmentType.PHYSICAL_PICKUP_OR_SHIP then the resulting list could be fulfillment locations
that have either FulfillmentType.PHYSICAL_PICKUP_OR_SHIP, FulfillmentType#SHIP or
FulfillmentType.PHYSICAL_PICKUPList<FulfillmentLocation> findAllFulfillmentLocations(org.broadleafcommerce.core.order.service.type.FulfillmentType fulfillmentType)
FulfillmentType.PHYSICAL_PICKUP_OR_SHIP then this will pick up both FulfillmentType.PHYSICAL_PICKUP
as well as FulfillmentType.PHYSICAL_SHIP. If the given fulfillmentType is null, this is equivalent
to invoking findAll()fulfillmentType - the type of fulfillment location to findFulfillmentLocation createNew()
void updateOtherDefaultLocationToFalse(FulfillmentLocation fulfillmentLocation)
FulfillmentLocations in the database to false, excluding the FulfillmentLocation that was
passed infulfillmentLocation - the FulfillmentLocation that will essentially become the new default locationCopyright © 2020. All rights reserved.