fix một số bug nhỏ

This commit is contained in:
2020-10-27 17:34:09 +07:00
parent 758b8d29c3
commit 02418afb11
16 changed files with 117 additions and 37 deletions

View File

@@ -89,7 +89,7 @@ class DepartmentController extends Controller {
$oldCode = $model->code;
$model->name = $data["Name"];
$model->code = $data["Code"];
if ($model->pid != 1) {
if ($model->pid != 0) {
$model->pid = $data["Pid"] !== "" ? $data["Pid"] : 0;
}
$model->modified_at = time();