git add .

git commit "Implement user registration"
This commit is contained in:
2026-08-16 08:52:04 +03:30
parent cd74c1848a
commit 687681744a
22 changed files with 1036 additions and 210 deletions
+48
View File
@@ -0,0 +1,48 @@
<?php
/**
* Created by Reliese Model.
*/
namespace App\Models;
use Carbon\Carbon;
use Illuminate\Database\Eloquent\Collection;
use Illuminate\Database\Eloquent\Model;
/**
* Class Role
*
* @property int $id
* @property string $name
* @property string $slug
* @property string $description
* @property Carbon $created_at
* @property Carbon $updated_at
*
* @property Collection|Admin[] $admins
* @property Collection|Permission[] $permissions
*
* @package App\Models
*/
class Role extends Model
{
protected $table = 'roles';
public static $snakeAttributes = false;
protected $fillable = [
'name',
'slug',
'description'
];
public function admins()
{
return $this->belongsToMany(Admin::class, 'admin_roles');
}
public function permissions()
{
return $this->belongsToMany(Permission::class, 'role_permissions');
}
}