本文整理匯總了PHP中FrontController::postProcess方法的典型用法代碼示例。如果您正苦於以下問題:PHP FrontController::postProcess方法的具體用法?PHP FrontController::postProcess怎麽用?PHP FrontController::postProcess使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類FrontController
的用法示例。
在下文中一共展示了FrontController::postProcess方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: postProcess
/**
* Set default medias for this controller
*/
public function postProcess()
{
if (Tools::getIsset('product_id')) {
$output = $this->getProductAttributeCombinations(Tools::getValue('product_id'));
echo json_encode($output);
parent::postProcess();
die;
}
}
示例2: postProcess
public function postProcess()
{
parent::postProcess();
if (Tools::isSubmit('submitReorder') && ($id_order = (int) Tools::getValue('id_order'))) {
$oldCart = new Cart(Order::getCartIdStatic($id_order, $this->context->customer->id));
$duplication = $oldCart->duplicate();
if (!$duplication || !Validate::isLoadedObject($duplication['cart'])) {
$this->errors[] = $this->trans('Sorry. We cannot renew your order.', array(), 'Shop.Notifications.Error');
} elseif (!$duplication['success']) {
$this->errors[] = $this->trans('Some items are no longer available, and we are unable to renew your order.', array(), 'Shop.Notifications.Error');
} else {
$this->context->cookie->id_cart = $duplication['cart']->id;
$context = $this->context;
$context->cart = $duplication['cart'];
CartRule::autoAddToCart($context);
$this->context->cookie->write();
Tools::redirect('index.php?controller=order');
}
}
$this->bootstrap();
}