tonis Posted August 5, 2014 Share Posted August 5, 2014 (edited) Hello I want to display the list of products on payment confirmation pages of bankwire payment and cash on delivery. To add in valitation.tpl {include file="$tpl_dir./shopping-cart.tpl"} does not displays them. It shows the table, but it is empty. What else I need to add? Thanks a lot for lelp Presta 1.6.0.6 Edited August 8, 2014 by tonis (see edit history) Link to comment Share on other sites More sharing options...
tonis Posted August 8, 2014 Author Share Posted August 8, 2014 I have found something similar here http://www.prestashop.com/forums/topic/286768-adding-cart-summary-to-payment-executiontpl/?hl=%2Bproduct+%2Blist+%2Bpayment&do=findComment&comment=1445775 but this is not enough in 1.6 I think, because to add $cart->getProducts() into the controler havent helped. Any "upgreads" for 1.6? Link to comment Share on other sites More sharing options...
tonis Posted August 8, 2014 Author Share Posted August 8, 2014 Solved for both payments I addet to the validation page the code {include file="$tpl_dir./shopping-cart.tpl"} for bankwire I addet to the controller payment.php $this->context->smarty->assign(array( 'nbProducts' => $cart->nbProducts(), 'products' => $cart->getProducts(), 'cust_currency' => $cart->id_currency, 'currencies' => $this->module->getCurrency((int)$cart->id_currency), 'total' => $cart->getOrderTotal(true, Cart::BOTH), 'total_price' => $cart->getOrderTotal(true, Cart::BOTH), 'total_products_wt'=> $cart->getOrderTotal(true, Cart::ONLY_PRODUCTS), 'total_discounts'=>$cart->getOrderTotal(true, Cart::ONLY_DISCOUNTS), 'total_discounts_tax_exc'=>$cart->getOrderTotal(false, Cart::ONLY_DISCOUNTS), 'total_wrapping'=>$cart->getOrderTotal(true, Cart::ONLY_WRAPPING), 'total_wrapping_tax_exc'=>$cart->getOrderTotal(false, Cart::ONLY_WRAPPING), 'total_shipping_tax_exc'=>$cart->getOrderTotal(false, Cart::ONLY_SHIPPING), 'total_shipping'=>$cart->getOrderTotal(tru, Cart::ONLY_SHIPPING), 'this_path' => $this->module->getPathUri(), 'this_path_ssl' => Tools::getShopDomainSsl(true, true).__PS_BASE_URI__.'modules/'.$this->module->name.'/' )); and for cah on delivery I addet to controller validation.php $this->context->smarty->assign(array( 'nbProducts' => $this->context->cart->nbProducts(), 'products' => $this->context->cart->getProducts(), 'cust_currency' => $this->context->cart->id_currency, 'currencies' => $this->module->getCurrency((int)$cart->id_currency), 'total' => $this->context->cart->getOrderTotal(true, Cart::BOTH), 'total_price' => $this->context->cart->getOrderTotal(true, Cart::BOTH), 'total_products_wt'=> $this->context->cart->getOrderTotal(true, Cart::ONLY_PRODUCTS), 'total_discounts'=>$this->context->cart->getOrderTotal(true, Cart::ONLY_DISCOUNTS), 'total_discounts_tax_exc'=>$this->context->cart->getOrderTotal(false, Cart::ONLY_DISCOUNTS), 'total_wrapping'=>$this->context->cart->getOrderTotal(true, Cart::ONLY_WRAPPING), 'total_wrapping_tax_exc'=>$this->context->cart->getOrderTotal(false, Cart::ONLY_WRAPPING), 'total_shipping_tax_exc'=>$this->context->cart->getOrderTotal(false, Cart::ONLY_SHIPPING), 'total_shipping'=>$this->context->cart->getOrderTotal(tru, Cart::ONLY_SHIPPING), 'this_path' => $this->module->getPathUri(), 'this_path_cod' => $this->module->getPathUri(), 'this_path_ssl' => Tools::getShopDomainSsl(true, true).__PS_BASE_URI__.'modules/'.$this->module->name.'/' )); ...replace the similar lines of codes in the controllers. Thanks for help community Link to comment Share on other sites More sharing options...
w.ig Posted December 10, 2014 Share Posted December 10, 2014 Similiar way is with PayU I added code in controlers/front/ payment.php: $this->context->smarty->assign(array( 'nbProducts' => $this->context->cart->nbProducts(), 'products' => $this->context->cart->getProducts(), 'cust_currency' => $this->context->cart->id_currency, 'currencies' => $this->module->getCurrency((int)$cart->id_currency), 'total' => $this->context->cart->getOrderTotal(true, Cart::BOTH), 'total_price' => $this->context->cart->getOrderTotal(true, Cart::BOTH), 'total_products_wt'=> $this->context->cart->getOrderTotal(true, Cart::ONLY_PRODUCTS), 'total_discounts'=>$this->context->cart->getOrderTotal(true, Cart::ONLY_DISCOUNTS), 'total_discounts_tax_exc'=>$this->context->cart->getOrderTotal(false, Cart::ONLY_DISCOUNTS), 'total_wrapping'=>$this->context->cart->getOrderTotal(true, Cart::ONLY_WRAPPING), 'total_wrapping_tax_exc'=>$this->context->cart->getOrderTotal(false, Cart::ONLY_WRAPPING), 'total_shipping_tax_exc'=>$this->context->cart->getOrderTotal(false, Cart::ONLY_SHIPPING), 'total_shipping'=>$this->context->cart->getOrderTotal(tru, Cart::ONLY_SHIPPING) )); Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now