提交 7fe45bcd 编写于 作者: T Terry

update

上级 f49d1654
......@@ -17,7 +17,7 @@ return [
* 模块内部的params配置。
*/
'params'=> [
'guestOrder' => false, // 是否支持游客下单
],
],
];
......@@ -27,8 +27,12 @@ class OnepageController extends AppfrontController
public function actionIndex()
{
//var_dump(Yii::$app->request->post());
$guestOrder = Yii::$app->controller->module->params['guestOrder'];
if(!$guestOrder && Yii::$app->user->isGuest){
$checkoutOrderUrl = Yii::$service->url->getUrl('checkout/onepage/index');
Yii::$service->customer->setLoginSuccessRedirectUrl($checkoutOrderUrl);
return Yii::$service->url->redirectByUrlKey('customer/account/login');
}
$_csrf = Yii::$app->request->post('_csrf');
if ($_csrf) {
$status = $this->getBlock('placeorder')->getLastData();
......
......@@ -176,7 +176,7 @@ class Paypal extends Service
*/
protected function isNotDuplicate()
{
$ipn = $this->_ipnMessageModel::find()
$ipn = $this->_ipnMessageModel->find()
->asArray()
->where([
'txn_id'=>$this->_postData['txn_id'],
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册