<?php
/*
 本代码由 口号帮 创建
 创建时间 2019-05-08 16:22:09
 技术支持 口号帮 
 严禁反编译、逆向等任何形式的侵权行为，违者将追究法律责任
*/

namespace App\Models;use Illuminate\Notifications\Notifiable;use Illuminate\Foundation\Auth\User as Authenticatable;use Spatie\Permission\Traits\HasRoles;class User extends Authenticatable{use Notifiable,HasRoles;protected $table='users';protected $fillable=['username','name','email','password','phone','uuid','status','avatar','remember_token','role_slug','status'];protected $hidden=['password','remember_token',];protected $guard_name='web';public function isRoot(){if(in_array('root',$this->roles()->pluck('name')->all()))goto P2gBodyx2;goto P2gNextx2;P2gBodyx2:return true;goto P2gx1;P2gNextx2:return false;P2gx1:}}
?>