app\controllers\CashbookController::actionIndex PHP Method

actionIndex() public method

public actionIndex ( )
    public function actionIndex()
    {
        $searchModel = new CashbookSearch();
        $searchModel->start_date = date('Y-m-01');
        // get start date
        $searchModel->end_date = date("Y-m-t");
        // get end date
        $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
        return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
    }