fix: 用户权限认证

This commit is contained in:
JaguarJack
2023-05-10 16:51:25 +08:00
parent 2d61786ec6
commit cbb3c156a6
2 changed files with 6 additions and 8 deletions

View File

@@ -73,7 +73,8 @@ class User extends Model implements AuthenticatableContract
protected function DepartmentId(): Attribute
{
return new Attribute(
get: fn($value) => $value ? : null
get: fn($value) => $value ? : null,
set: fn($value) => $value ? : 0
);
}