} | } | ||||
// setDeliveryAddress | // setDeliveryAddress | ||||
public function initDeliveryAddress(OrderShopInterface $orderShop, AddressInterface $address):void | |||||
public function initDeliveryAddress(OrderShopInterface $orderShop, AddressInterface $address = null):void | |||||
{ | { | ||||
$orderShop->setDeliveryAddress($address); | $orderShop->setDeliveryAddress($address); | ||||
$orderShop->setDeliveryInfos($address ? $address->getDeliveryInfos() : null); | $orderShop->setDeliveryInfos($address ? $address->getDeliveryInfos() : null); |
} | } | ||||
// isOrderProductAvailable | // isOrderProductAvailable | ||||
public function isAvailable() | |||||
/*public function isAvailable() | |||||
{ | { | ||||
return $this->getProduct()->isAvailable($this->getQuantityOrder()); | return $this->getProduct()->isAvailable($this->getQuantityOrder()); | ||||
} | |||||
}*/ | |||||
// isOrderProductAvailableAddCart | // isOrderProductAvailableAddCart | ||||
// @TODO : à remettre en place si nécessaire | // @TODO : à remettre en place si nécessaire |