Dumplie\Customer\Application\Command\ChangeShippingAddress::cartId PHP 메소드

cartId() 공개 메소드

public cartId ( ) : string
리턴 string
    public function cartId() : string
    {
        return $this->cartId;
    }

Usage Example

 /**
  * @param ChangeShippingAddress $command
  * @throws InvalidArgumentException
  */
 public function handle(ChangeShippingAddress $command)
 {
     $shippingAddress = new Address($command->name(), $command->street(), $command->postCode(), $command->city(), $command->countryIso2Code());
     $checkout = $this->checkouts->getForCart(new CartId($command->cartId()));
     $checkout->changeShippingAddress($shippingAddress);
 }
ChangeShippingAddress