Add users, teams, authentication, profile/login/register/navbar views
This commit is contained in:
18
app/Models/BaseModel.php
Normal file
18
app/Models/BaseModel.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Xaevik\Cuid2\Cuid2;
|
||||
|
||||
abstract class BaseModel extends Model
|
||||
{
|
||||
protected static function boot()
|
||||
{
|
||||
parent::boot();
|
||||
|
||||
static::creating(function (Model $model) {
|
||||
$model->uuid = (string) new Cuid2();
|
||||
});
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user