mirror of
https://github.com/solidtime-io/solidtime.git
synced 2026-05-07 20:32:26 +00:00
21 lines
316 B
PHP
21 lines
316 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Models\Concerns;
|
|
|
|
use Ramsey\Uuid\Uuid;
|
|
|
|
trait HasUuids
|
|
{
|
|
use \Illuminate\Database\Eloquent\Concerns\HasUuids;
|
|
|
|
/**
|
|
* Generate a new UUID for the model.
|
|
*/
|
|
public function newUniqueId(): string
|
|
{
|
|
return (string) Uuid::uuid4();
|
|
}
|
|
}
|