public function subtotal(Product $product)
    {
        $subtotal = $this->money($product);

        if (! $product->freebie) {
            $value    = $this->value($product);
            $discount = $this->discount($product);
            $subtotal = $subtotal->add($value)->subtract($discount);
        }

        $delivery = $this->delivery($product);
        $subtotal = $subtotal->add($delivery);

        return $subtotal;
    }
public function subtotal(Product $product)
    {
        $subtotal = $this->money($product);

        if (! $product->freebie) {
            $value    = $this->value($product);
            $discount = $this->discount($product);
            $subtotal = $subtotal->add($value)->subtract($discount);
        }

        $delivery = $this->delivery($product);
        $subtotal = $subtotal->add($delivery);

        return $subtotal;
    }
public function subtotal ( Product $ product ) { $ subtotal = $ this -> money ( $ product ) ; if ( ! $ product -> freebie ) { $ value = $ this -> value ( $ product ) ; $ discount = $ this -> discount ( $ product ) ; $ subtotal = $ subtotal -> add ( $ value ) -> subtract ( $ discount ) ; } $ delivery = $ this -> delivery ( $ product ) ; $ subtotal = $ subtotal -> add ( $ delivery ) ; return $ subtotal ; }
Return the subtotal of the Product

@param Product $product
@return Money
Return the subtotal of the Product