修改限购商品结算页左上角返回按钮的跳转地址
Code Review By Rock Zhang
Showing
1 changed file
with
8 additions
and
2 deletions
@@ -283,8 +283,8 @@ class IndexController extends AbstractAction | @@ -283,8 +283,8 @@ class IndexController extends AbstractAction | ||
283 | // 审判跳转登录页 | 283 | // 审判跳转登录页 |
284 | $this->auditJumpLogin(); | 284 | $this->auditJumpLogin(); |
285 | 285 | ||
286 | - $this->setTitle('确认订单'); | ||
287 | - $this->setNavHeader('确认订单', Helpers::url('/cart/index/index'), false); // 不显示右上角home按钮 | 286 | + // 返回地址 |
287 | + $returnUrl = Helpers::url('/cart/index/index'); | ||
288 | 288 | ||
289 | $cartType = $this->get('cartType', ''); | 289 | $cartType = $this->get('cartType', ''); |
290 | $cookieData = $this->getCookie('order-info', null); | 290 | $cookieData = $this->getCookie('order-info', null); |
@@ -299,6 +299,9 @@ class IndexController extends AbstractAction | @@ -299,6 +299,9 @@ class IndexController extends AbstractAction | ||
299 | $sku = $this->get('sku', ''); | 299 | $sku = $this->get('sku', ''); |
300 | $skn = $this->get('skn', ''); | 300 | $skn = $this->get('skn', ''); |
301 | $buyNumber = $this->get('buy_number', 1); | 301 | $buyNumber = $this->get('buy_number', 1); |
302 | + if ($limitProductCode) { | ||
303 | + $returnUrl = $this->server('HTTP_REFERER', $returnUrl); | ||
304 | + } | ||
302 | 305 | ||
303 | // 购物车商品为空跳转到购物车页面 | 306 | // 购物车商品为空跳转到购物车页面 |
304 | $uid = $this->getUid(true); | 307 | $uid = $this->getUid(true); |
@@ -320,6 +323,9 @@ class IndexController extends AbstractAction | @@ -320,6 +323,9 @@ class IndexController extends AbstractAction | ||
320 | 'orderEnsure' => $order | 323 | 'orderEnsure' => $order |
321 | ); | 324 | ); |
322 | 325 | ||
326 | + $this->setTitle('确认订单'); | ||
327 | + $this->setNavHeader('确认订单', $returnUrl, false); // 不显示右上角home按钮 | ||
328 | + | ||
323 | $this->_view->display('order-ensure', $data); | 329 | $this->_view->display('order-ensure', $data); |
324 | } | 330 | } |
325 | 331 |
-
Please register or login to post a comment