Class DefaultSapCosOaaCommerceStockService
java.lang.Object
de.hybris.platform.commerceservices.stock.impl.DefaultCommerceStockService
de.hybris.platform.warehousing.atp.services.impl.WarehousingCommerceStockService
com.sap.retail.oaa.commerce.services.stock.impl.DefaultSapOaaCommerceStockService
com.sap.sapoaacosintegration.services.stock.impl.DefaultSapCosOaaCommerceStockService
- All Implemented Interfaces:
SapOaaCommerceStockService,de.hybris.platform.commerceservices.stock.CommerceStockService
Provides stock level for COS use-cases
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondeterminePointOfService(String sourceId) getAvailabilityForProduct(String cartGuid, String itemId, ProductModel product) Get the availability for a given cart item.getAvailabilityForProductAndSource(ProductModel product, String source) Get the availability for a given product and source.getAvailabilityForProductAndSource(String cartGuid, String itemId, ProductModel product, String source) Get the availability for a given cart item and source.getAvailabilityForProductAndSources(String cartGuid, String itemId, ProductModel product, List<String> sourcesList) Get the availability for a given cart item and sources.getAvailabilityForProducts(String cartGuid, String itemId, String productUnit, List<ProductModel> productList) Get the availability for a given cart items and corresponding product unit.getAvailableStockLevel(String cartGuid, String itemId, ProductModel productModel, PointOfServiceModel pointOfServiceModel) Get current stock information calling ATP Service (CAR)getAvailableStockLevelForPos(String cartGuid, ProductModel productModel, PointOfServiceModel pointOfService) Get current stock information calling ATP Service (CAR)de.hybris.platform.storelocator.PointOfServiceDaogetPosAndStockLevelStatusForProduct(ProductModel product, BaseStoreModel baseStore) getStockLevel(StockLevelStatus stockLevelStatus, ProductModel product, BaseStoreModel baseStore) Returns stock level value for combination of given product,base store and stock level statusgetStockLevelForProductAndBaseStore(ProductModel product, BaseStoreModel baseStore) getStockLevelForProductAndPointOfService(ProductModel product, PointOfServiceModel pointOfService) Get actual stock information calling ATP Service (CAR) for product in storegetStockLevelForRSI(ProductModel product, BaseStoreModel baseStore) Get the stock information for a product and base storegetStockLevelStatusForProductAndBaseStore(ProductModel product, BaseStoreModel baseStore) getStockLevelStatusForProductAndPointOfService(ProductModel product, PointOfServiceModel pointOfService) voidsetAtpAggregationStrategy(ATPAggregationStrategy atpAggregationStrategy) voidsetAtpService(ATPService atpService) voidsetCommonUtils(CommonUtils commonUtils) voidsetPointOfServiceDao(de.hybris.platform.storelocator.PointOfServiceDao pointOfServiceDao) Methods inherited from class com.sap.retail.oaa.commerce.services.stock.impl.DefaultSapOaaCommerceStockService
retrieveStockLevelForProductMethods inherited from class de.hybris.platform.warehousing.atp.services.impl.WarehousingCommerceStockService
getPickupWarehouseSelectionStrategy, setPickupWarehouseSelectionStrategyMethods inherited from class de.hybris.platform.commerceservices.stock.impl.DefaultCommerceStockService
getCommerceStockLevelCalculationStrategy, getStockLevelProductStrategy, getStockLevelStatusStrategy, getStockService, getStorePickupDao, getWarehouseSelectionStrategy, isStockSystemEnabled, setCommerceStockLevelCalculationStrategy, setStockLevelProductStrategy, setStockLevelStatusStrategy, setStockService, setStorePickupDao, setWarehouseSelectionStrategyMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.hybris.platform.commerceservices.stock.CommerceStockService
isStockSystemEnabled
-
Constructor Details
-
DefaultSapCosOaaCommerceStockService
public DefaultSapCosOaaCommerceStockService()
-
-
Method Details
-
getStockLevelForProductAndBaseStore
- Specified by:
getStockLevelForProductAndBaseStorein interfacede.hybris.platform.commerceservices.stock.CommerceStockService- Overrides:
getStockLevelForProductAndBaseStorein classDefaultSapOaaCommerceStockService- Parameters:
product-baseStore-- Returns:
Long
-
getStockLevelStatusForProductAndBaseStore
public StockLevelStatus getStockLevelStatusForProductAndBaseStore(ProductModel product, BaseStoreModel baseStore) - Specified by:
getStockLevelStatusForProductAndBaseStorein interfacede.hybris.platform.commerceservices.stock.CommerceStockService- Overrides:
getStockLevelStatusForProductAndBaseStorein classDefaultSapOaaCommerceStockService- Parameters:
product-baseStore-- Returns:
StockLevelStatus
-
getStockLevelStatusForProductAndPointOfService
public StockLevelStatus getStockLevelStatusForProductAndPointOfService(ProductModel product, PointOfServiceModel pointOfService) - Specified by:
getStockLevelStatusForProductAndPointOfServicein interfacede.hybris.platform.commerceservices.stock.CommerceStockService- Overrides:
getStockLevelStatusForProductAndPointOfServicein classDefaultSapOaaCommerceStockService
-
getStockLevelForProductAndPointOfService
public Long getStockLevelForProductAndPointOfService(ProductModel product, PointOfServiceModel pointOfService) Description copied from class:DefaultSapOaaCommerceStockServiceGet actual stock information calling ATP Service (CAR) for product in store- Specified by:
getStockLevelForProductAndPointOfServicein interfacede.hybris.platform.commerceservices.stock.CommerceStockService- Overrides:
getStockLevelForProductAndPointOfServicein classDefaultSapOaaCommerceStockService- Returns:
- available stock in POS/Store
-
getStockLevel
public Long getStockLevel(StockLevelStatus stockLevelStatus, ProductModel product, BaseStoreModel baseStore) Description copied from interface:SapOaaCommerceStockServiceReturns stock level value for combination of given product,base store and stock level status- Specified by:
getStockLevelin interfaceSapOaaCommerceStockService- Overrides:
getStockLevelin classDefaultSapOaaCommerceStockService- Parameters:
stockLevelStatus- This is used for populating Stock Level Status.product- This product availability will be checked.baseStore- This is used for validating associated warehouse .- Returns:
StockDatainformation
-
getAvailabilityForProduct
public List<ATPAvailability> getAvailabilityForProduct(String cartGuid, String itemId, ProductModel product) Description copied from interface:SapOaaCommerceStockServiceGet the availability for a given cart item.- Specified by:
getAvailabilityForProductin interfaceSapOaaCommerceStockService- Overrides:
getAvailabilityForProductin classDefaultSapOaaCommerceStockService- Parameters:
cartGuid- The id for the cart.itemId- The id for the item.product- This product availability will be checked.- Returns:
- list of availability
-
getAvailabilityForProductAndSource
public List<ATPAvailability> getAvailabilityForProductAndSource(ProductModel product, String source) Description copied from interface:SapOaaCommerceStockServiceGet the availability for a given product and source.- Specified by:
getAvailabilityForProductAndSourcein interfaceSapOaaCommerceStockService- Overrides:
getAvailabilityForProductAndSourcein classDefaultSapOaaCommerceStockService- Parameters:
product- This product availability will be checked.source- Product availability will be checked against given source.- Returns:
- list of availability
-
getAvailabilityForProductAndSource
public List<ATPAvailability> getAvailabilityForProductAndSource(String cartGuid, String itemId, ProductModel product, String source) Description copied from interface:SapOaaCommerceStockServiceGet the availability for a given cart item and source.- Specified by:
getAvailabilityForProductAndSourcein interfaceSapOaaCommerceStockService- Overrides:
getAvailabilityForProductAndSourcein classDefaultSapOaaCommerceStockService- Parameters:
cartGuid- The id for the cart.itemId- The id for the item.product- This product availability will be checked.source- Product availability will be checked against given source.- Returns:
- list of availability
-
getAvailabilityForProducts
public List<ATPProductAvailability> getAvailabilityForProducts(String cartGuid, String itemId, String productUnit, List<ProductModel> productList) Description copied from interface:SapOaaCommerceStockServiceGet the availability for a given cart items and corresponding product unit.- Specified by:
getAvailabilityForProductsin interfaceSapOaaCommerceStockService- Overrides:
getAvailabilityForProductsin classDefaultSapOaaCommerceStockService- Parameters:
cartGuid- The id for the cart.itemId- The id for the item.productUnit- This product unit will be checked.productList- This list of product whose availability will be checked.- Returns:
- list of ATP product availability
-
getAvailabilityForProductAndSources
public List<ATPProductAvailability> getAvailabilityForProductAndSources(String cartGuid, String itemId, ProductModel product, List<String> sourcesList) Description copied from interface:SapOaaCommerceStockServiceGet the availability for a given cart item and sources.- Specified by:
getAvailabilityForProductAndSourcesin interfaceSapOaaCommerceStockService- Overrides:
getAvailabilityForProductAndSourcesin classDefaultSapOaaCommerceStockService- Parameters:
cartGuid- The id for the cart.itemId- The id for the item.product- This product availability will be checked.sourcesList- This source list availability will be checked.- Returns:
- list of ATP product availability
-
getPosAndStockLevelStatusForProduct
public Map<PointOfServiceModel,StockLevelStatus> getPosAndStockLevelStatusForProduct(ProductModel product, BaseStoreModel baseStore) - Specified by:
getPosAndStockLevelStatusForProductin interfacede.hybris.platform.commerceservices.stock.CommerceStockService- Overrides:
getPosAndStockLevelStatusForProductin classDefaultSapOaaCommerceStockService
-
getAvailableStockLevelForPos
public Long getAvailableStockLevelForPos(String cartGuid, ProductModel productModel, PointOfServiceModel pointOfService) Description copied from interface:SapOaaCommerceStockServiceGet current stock information calling ATP Service (CAR)- Specified by:
getAvailableStockLevelForPosin interfaceSapOaaCommerceStockService- Overrides:
getAvailableStockLevelForPosin classDefaultSapOaaCommerceStockService- Parameters:
cartGuid- The id for the cart.productModel- This product availability will be checked.pointOfService- This point of service availability will be checked.- Returns:
- total aggregated ATP amount
-
getStockLevelForRSI
Description copied from interface:SapOaaCommerceStockServiceGet the stock information for a product and base store- Specified by:
getStockLevelForRSIin interfaceSapOaaCommerceStockService- Overrides:
getStockLevelForRSIin classDefaultSapOaaCommerceStockService- Parameters:
product- This product rough stock will be checked.baseStore- This base store rough stock will be checked.- Returns:
- StockLevelModel
-
getAvailableStockLevel
public Long getAvailableStockLevel(String cartGuid, String itemId, ProductModel productModel, PointOfServiceModel pointOfServiceModel) Description copied from interface:SapOaaCommerceStockServiceGet current stock information calling ATP Service (CAR)- Specified by:
getAvailableStockLevelin interfaceSapOaaCommerceStockService- Overrides:
getAvailableStockLevelin classDefaultSapOaaCommerceStockService- Parameters:
cartGuid- The id for the cart.itemId- The id for the item.productModel- This product stock will be checked.pointOfServiceModel- This point of service stock will be checked.- Returns:
- total aggregated ATP amount
-
getAtpService
- Overrides:
getAtpServicein classDefaultSapOaaCommerceStockService- Returns:
- the atpService
-
setAtpService
- Overrides:
setAtpServicein classDefaultSapOaaCommerceStockService- Parameters:
atpService- the atpService to set
-
getPointOfServiceDao
public de.hybris.platform.storelocator.PointOfServiceDao getPointOfServiceDao()- Overrides:
getPointOfServiceDaoin classDefaultSapOaaCommerceStockService- Returns:
- the pointOfServiceDao
-
setPointOfServiceDao
public void setPointOfServiceDao(de.hybris.platform.storelocator.PointOfServiceDao pointOfServiceDao) - Overrides:
setPointOfServiceDaoin classDefaultSapOaaCommerceStockService- Parameters:
pointOfServiceDao- the pointOfServiceDao to set
-
getAtpAggregationStrategy
- Overrides:
getAtpAggregationStrategyin classDefaultSapOaaCommerceStockService- Returns:
- the atpAggregationStrategy
-
setAtpAggregationStrategy
- Overrides:
setAtpAggregationStrategyin classDefaultSapOaaCommerceStockService- Parameters:
atpAggregationStrategy- the atpAggregationStrategy to set
-
determinePointOfService
- Overrides:
determinePointOfServicein classDefaultSapOaaCommerceStockService- Parameters:
sourceId-- Returns:
- pointOfServiceModel
-
getCommonUtils
- Overrides:
getCommonUtilsin classDefaultSapOaaCommerceStockService- Returns:
- the commonUtils
-
setCommonUtils
- Overrides:
setCommonUtilsin classDefaultSapOaaCommerceStockService- Parameters:
commonUtils- the commonUtils to set
-