Class DefaultSourcingBanService
- java.lang.Object
-
- de.hybris.platform.warehousing.sourcing.ban.service.impl.DefaultSourcingBanService
-
- All Implemented Interfaces:
SourcingBanService
public class DefaultSourcingBanService extends java.lang.Object implements SourcingBanService
The default implementation ofSourcingBanService
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.lang.StringBAN_DAYS
-
Constructor Summary
Constructors Constructor Description DefaultSourcingBanService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SourcingBanModelcreateSourcingBan(WarehouseModel warehouse)creates Sourcing Banprotected ConfigurationServicegetConfigurationService()protected java.util.DategetCurrentDateMinusBannedDays()Calculates the current date - # of ban days according to a property.protected ModelServicegetModelService()java.util.Collection<SourcingBanModel>getSourcingBan(java.util.Collection<WarehouseModel> warehouses)gets SourcingBan by passing Warehouseprotected SourcingBanDaogetSourcingBanDao()protected TimeServicegetTimeService()voidsetConfigurationService(ConfigurationService configurationService)voidsetModelService(ModelService modelService)voidsetSourcingBanDao(SourcingBanDao sourcingBanDao)voidsetTimeService(TimeService timeService)
-
-
-
Field Detail
-
BAN_DAYS
protected static final java.lang.String BAN_DAYS
- See Also:
- Constant Field Values
-
-
Method Detail
-
createSourcingBan
public SourcingBanModel createSourcingBan(WarehouseModel warehouse)
Description copied from interface:SourcingBanServicecreates Sourcing Ban- Specified by:
createSourcingBanin interfaceSourcingBanService- Parameters:
warehouse- warehouse that we want to ban- Returns:
- SourcingBanModel linked to the passed Warehouse, this ban will expire in 1 day by default
-
getSourcingBan
public java.util.Collection<SourcingBanModel> getSourcingBan(java.util.Collection<WarehouseModel> warehouses)
Description copied from interface:SourcingBanServicegets SourcingBan by passing Warehouse- Specified by:
getSourcingBanin interfaceSourcingBanService- Parameters:
warehouses- collection of warehouse that we want to get bans for- Returns:
- collection of SourcingBans that for warehouses that is active within configurable period (1 day by default)
-
getCurrentDateMinusBannedDays
protected java.util.Date getCurrentDateMinusBannedDays()
Calculates the current date - # of ban days according to a property.
-
getSourcingBanDao
protected SourcingBanDao getSourcingBanDao()
-
setSourcingBanDao
public void setSourcingBanDao(SourcingBanDao sourcingBanDao)
-
getModelService
protected ModelService getModelService()
-
setModelService
public void setModelService(ModelService modelService)
-
getConfigurationService
protected ConfigurationService getConfigurationService()
-
setConfigurationService
public void setConfigurationService(ConfigurationService configurationService)
-
getTimeService
protected TimeService getTimeService()
-
setTimeService
public void setTimeService(TimeService timeService)
-
-