change cart to plain post from ajax
This commit is contained in:
@@ -63,6 +63,7 @@ class AccountStateController extends Controller
|
||||
$model = new AccountState();
|
||||
$model->type = AccountState::TYPE_OPEN;
|
||||
$model->id_user = Yii::$app->user->id;
|
||||
$model->id_account = Account::readDefault();
|
||||
if ($model->load(Yii::$app->request->post()) && $model->save()) {
|
||||
// return $this->redirect(['view', 'id' => $model->id_account_state]);
|
||||
return $this->redirect(['index' ]);
|
||||
@@ -89,6 +90,7 @@ class AccountStateController extends Controller
|
||||
$model = new AccountState();
|
||||
$model->type = AccountState::TYPE_CLOSE;
|
||||
$model->id_user = Yii::$app->user->id;
|
||||
$model->id_account = Account::readDefault();
|
||||
if ($model->load(Yii::$app->request->post()) && $model->save()) {
|
||||
return $this->redirect(['index' ]);
|
||||
// return $this->redirect(['view', 'id' => $model->id_account_state]);
|
||||
|
||||
Reference in New Issue
Block a user