public function actionEdit($id)
    {
        $model = $this->findModel($id);
        $form  = new LanguageForm($model);
        if (Yii::$app->request->isAjax && $form->load(Yii::$app->request->post())){
            if (!$errors = ActiveForm::validate($form)) {
                try {
                    $this->service->edit($form->id, $form);
                    $this->output['status'] = 1;
                } catch (YiiException $e) {
                    $errors = ErrorHelper::checkModel($e->data, $form);
                }
            }
            return $this->output['errors'] = $errors;
        }
        return $this->render('edit', ['model' => $form]);
    }