Skip to content

CreatorRecord ​

File: src/Entities/CreatorRecord.php
Namespace: Unusualify\Modularous\Entities
Extends: Illuminate\Database\Eloquent\Model

Records the creator of a model instance. Used by the HasCreator trait to track which user (and auth guard) created a given record. Timestamps are disabled.

Fillable Attributes ​

AttributeTypeDescription
creator_typestringCreator model class
creator_idintCreator model ID
guard_namestringAuth guard used at creation time
creatable_typestringCreated model class
creatable_idintCreated model ID

Relationships ​

creatable(): MorphTo ​

The model that was created.

creator(): MorphTo ​

The user/entity who created the model.

Table ​

Resolved from modularous.tables.creator_records, defaults to um_creator_records.

  • HasCreator — trait that writes creator records