You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and dots ('.'), can be up to 35 characters long. Letters must be lowercase.
26 lines
420 B
26 lines
420 B
<?php |
|
|
|
namespace App\Models; |
|
|
|
use Illuminate\Database\Eloquent\Model; |
|
|
|
class DocumentState extends Model |
|
{ |
|
protected $fillable = [ |
|
'id', |
|
'name', |
|
]; |
|
|
|
public function jsonSerialize():array |
|
{ |
|
return [ |
|
'id' => $this->uuid, |
|
'name' => $this->name, |
|
]; |
|
} |
|
|
|
public function documents() |
|
{ |
|
return $this->hasMany(Document::class); |
|
} |
|
}
|
|
|