public function orderDataAccess($params, &$smarty)
    {
        /** @var Order $order */
        $order = $this->getSession()->getOrder();
        $attribute = $this->getNormalizedParam($params, array('attribute', 'attrib', 'attr'));
        switch ($attribute) {
            case 'untaxed_postage':
                return $order->getUntaxedPostage();
            case 'postage':
                return $order->getPostage();
            case 'postage_tax':
                return $order->getPostageTax();
            case 'discount':
                return $order->getDiscount();
            case 'delivery_address':
                return $order->getChoosenDeliveryAddress();
            case 'invoice_address':
                return $order->getChoosenInvoiceAddress();
            case 'delivery_module':
                return $order->getDeliveryModuleId();
            case 'payment_module':
                return $order->getPaymentModuleId();
            case 'has_virtual_product':
                return $order->hasVirtualProduct();
        }

        throw new \InvalidArgumentException(sprintf("%s has no '%s' attribute", 'Order', $attribute));
    }
public function orderDataAccess($params, &$smarty)
    {
        /** @var Order $order */
        $order = $this->getSession()->getOrder();
        $attribute = $this->getNormalizedParam($params, array('attribute', 'attrib', 'attr'));
        switch ($attribute) {
            case 'untaxed_postage':
                return $order->getUntaxedPostage();
            case 'postage':
                return $order->getPostage();
            case 'postage_tax':
                return $order->getPostageTax();
            case 'discount':
                return $order->getDiscount();
            case 'delivery_address':
                return $order->getChoosenDeliveryAddress();
            case 'invoice_address':
                return $order->getChoosenInvoiceAddress();
            case 'delivery_module':
                return $order->getDeliveryModuleId();
            case 'payment_module':
                return $order->getPaymentModuleId();
            case 'has_virtual_product':
                return $order->hasVirtualProduct();
        }

        throw new \InvalidArgumentException(sprintf("%s has no '%s' attribute", 'Order', $attribute));
    }
public function orderDataAccess ( $ params , & $ smarty ) { /** @var Order $order */ $ order = $ this -> getSession ( ) -> getOrder ( ) ; $ attribute = $ this -> getNormalizedParam ( $ params , array ( 'attribute' , 'attrib' , 'attr' ) ) ; switch ( $ attribute ) { case 'untaxed_postage' : return $ order -> getUntaxedPostage ( ) ; case 'postage' : return $ order -> getPostage ( ) ; case 'postage_tax' : return $ order -> getPostageTax ( ) ; case 'discount' : return $ order -> getDiscount ( ) ; case 'delivery_address' : return $ order -> getChoosenDeliveryAddress ( ) ; case 'invoice_address' : return $ order -> getChoosenInvoiceAddress ( ) ; case 'delivery_module' : return $ order -> getDeliveryModuleId ( ) ; case 'payment_module' : return $ order -> getPaymentModuleId ( ) ; case 'has_virtual_product' : return $ order -> hasVirtualProduct ( ) ; } throw new \ InvalidArgumentException ( sprintf ( "%s has no '%s' attribute" , 'Order' , $ attribute ) ) ; }
Provides access to an attribute of the current order

@param  array $params
@param  \Smarty $smarty
@return string the value of the requested attribute
Provides access to an attribute of the current order