Class LogisticsProviderServiceImpl
- java.lang.Object
-
- co.mastermindcms.modules.services.LogisticsProviderServiceImpl
-
- All Implemented Interfaces:
LogisticsProviderService
@Service public class LogisticsProviderServiceImpl extends java.lang.Object implements LogisticsProviderService
-
-
Field Summary
Fields Modifier and Type Field Description private CdekService
cdekService
private CommerceProperties
commerceProperties
-
Constructor Summary
Constructors Constructor Description LogisticsProviderServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.math.BigDecimal
calculateDeliveryPrice(Order order)
Maps an Order object to an OrderDTO object.boolean
isActive()
Checks if the logistics provider is active.boolean
ship(Order order)
-
-
-
Field Detail
-
commerceProperties
@Autowired private CommerceProperties commerceProperties
-
cdekService
@Autowired private CdekService cdekService
-
-
Method Detail
-
isActive
public boolean isActive()
Description copied from interface:LogisticsProviderService
Checks if the logistics provider is active.- Specified by:
isActive
in interfaceLogisticsProviderService
- Returns:
- true if the logistics provider is active, false otherwise.
-
calculateDeliveryPrice
public java.math.BigDecimal calculateDeliveryPrice(Order order)
Description copied from interface:LogisticsProviderService
Maps an Order object to an OrderDTO object.- Specified by:
calculateDeliveryPrice
in interfaceLogisticsProviderService
- Parameters:
order
- the Order object to be mapped- Returns:
- price amount for delivery service
-
ship
public boolean ship(Order order)
- Specified by:
ship
in interfaceLogisticsProviderService
-
-