/**
  * Creates a new Virtual model.
  * If creation is successful, the browser will be redirected to the 'view' page.
  * @return mixed
  */
 public function actionCreate()
 {
     $model = new Virtual();
     if ($model->load(Yii::$app->request->post()) && $model->save()) {
         // Yii::$app->Controllers->activity_user("[CREATE COS]");
         Yii::$app->Controllers->historyUserWithData($model);
         echo 1;
     } else {
         return $this->renderAjax('create', ['model' => $model]);
     }
 }
 /**
  * Creates a new Virtual model.
  * If creation is successful, the browser will be redirected to the 'view' page.
  * @return mixed
  */
 public function actionCreate()
 {
     $model = new Virtual();
     if ($model->load(Yii::$app->request->post()) && $model->save()) {
         GlobalFunctionController::activity_user("[CREATE VIRTUAL] Name : {$model->name} ,Description : {$model->description}");
         Yii::$app->Controllers->historyUserWithData($model);
         echo 1;
     } else {
         return $this->renderAjax('create', ['model' => $model]);
     }
 }