Skip to content

添加、编辑、删除角色的时候报错 #11

@yujiak

Description

@yujiak

添加、编辑、删除角色的时候报错ErrorException in RoleController.php line 102:
Trying to get property of non-object
但是数据是操作成功的。
event(new \App\Events\userActionEvent('\App\Models\Admin\Role',$role->id,1,"用户".Auth::user()->username."{".Auth::user()->id."}添加角色".$role->name."{".$role->id."}"));
这是对应的抱错行

不知道是否是要这样使用的:event(new userActionEvent('\App\Models\Admin\Role',$role->id,1,"用户".Auth::guard('admin')->user()->name."{".Auth::guard('admin')->user()->id."}添加角色".$role->name."{".$role->id."}"));

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions