This repository was archived by the owner on Mar 18, 2022. It is now read-only.
This repository was archived by the owner on Mar 18, 2022. It is now read-only.
Class 'App\Model' not found #205
Open
Description
I have implement the all steps and integrated everything successfully But i am getting this error after login using "Class 'App\Model' not found"
Below is my user model :-
namespace App;
use Illuminate\Notifications\Notifiable;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Bican\Roles\Traits\HasRoleAndPermission;
use Bican\Roles\Contracts\HasRoleAndPermission as HasRoleAndPermissionContract;
class User extends Model implements AuthenticatableContract, CanResetPasswordContract, HasRoleAndPermissionContract
{
use Authenticatable, CanResetPassword, HasRoleAndPermission;
use Notifiable;
protected $fillable = [
'name', 'email', 'password',
];
protected $hidden = [
'password', 'remember_token',
];
// delete the user detail table entry when delete user
public function users_detail()
{
return $this->has_many('users_detail');
}
// delete the user role table entry when delete user
public function role_user()
{
return $this->has_many('role_user');
}
// this is a recommended way to declare event handlers
protected static function boot() {
parent::boot();
static::deleting(function($user) { // before delete() method call this
$user->users_detail()->delete();
$user->role_user()->delete();
// do the rest of the cleanup...
});
}
}
Metadata
Metadata
Assignees
Labels
No labels
Activity