public function actionCreate()
 {
     $form = new CreateCategoryForm();
     $form->setUser($this->_user);
     $form->load(Yii::$app->request->post());
     if ($form->save()) {
         return ['status' => true, 'data' => $form->getCategory()];
     }
     return ['status' => true, 'error' => ApiActiveRecord::ERROR_VALIDATION, 'error_code' => ApiActiveRecord::ERROR_VALIDATION, 'data' => $form->errors];
 }
 /**
  * @return array
  */
 public function actionSignUp()
 {
     $form = new SignUpForm();
     $form->load(Yii::$app->request->post());
     if ($data = $form->signUp()) {
         $user = $form->getUser();
         CreateCategoryForm::createDefault($user);
         CreateCurrencyForm::createDefault($user);
         return ['status' => true, 'data' => $data];
     }
     return ['status' => false, 'error' => ApiActiveRecord::ERROR_VALIDATION, 'error_code' => ApiActiveRecord::ERROR_VALIDATION, 'data' => $form->errors];
 }