add feature payout_later
This commit is contained in:
@@ -16,6 +16,7 @@ use common\models\ProductCategory;
|
||||
use common\models\Product;
|
||||
use backend\models\TransferListUserGroupedSearch;
|
||||
use backend\models\TransferLaterSearch;
|
||||
use yii\helpers\Url;
|
||||
|
||||
/**
|
||||
* TransferController implements the CRUD actions for Transfer model.
|
||||
@@ -50,6 +51,15 @@ class TransferController extends \backend\controllers\BackendController
|
||||
|
||||
public function actionPaymentLater(){
|
||||
$searchModel = new TransferLaterSearch();
|
||||
|
||||
|
||||
if ( \Yii::$app->request->isPost){
|
||||
$searchModel->load(Yii::$app->request->post());
|
||||
if ( $searchModel->doPayout()) {
|
||||
return $this->redirect(['transfer/payment-later' ]);
|
||||
}
|
||||
}
|
||||
|
||||
$dataProvider = $searchModel->search(Yii::$app->request->queryParams);
|
||||
|
||||
$accounts = Account::read();
|
||||
@@ -57,6 +67,8 @@ class TransferController extends \backend\controllers\BackendController
|
||||
|
||||
$users = User::read();
|
||||
|
||||
Url::remember("payment_later",Url::current());
|
||||
|
||||
return $this->render('payment_later', [
|
||||
'searchModel' => $searchModel,
|
||||
'dataProvider' => $dataProvider,
|
||||
|
||||
Reference in New Issue
Block a user