-
Notifications
You must be signed in to change notification settings - Fork 6
Inspections
David Rodrigues edited this page May 31, 2017
·
11 revisions
This inspection tells that you should declares the @property
annotation on class that refers to each database columns. It is useful to determine the column type, getting a better IDE code support.
This inspection affects only models that extends the Eloquent\Model
class, direct or indirectly.
- Check for
id
column annotation; - Check for columns annotations from class properties:
$casts
and$dates
; - Check for columns annotations from accessors and mutators methods;
- Check for columns annotations from relationships methods;
- Check for columns annotations from model instance references (eg.
$user->name
); - Check for
created_at
andupdated_at
when the property$timestamps = true
; - Check for
deleted_at
column when using theSoftDeletes
trait; - Quick-fix available;