diff options
Diffstat (limited to 'src/Models/User/UsesUserModel.php')
-rw-r--r-- | src/Models/User/UsesUserModel.php | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/Models/User/UsesUserModel.php b/src/Models/User/UsesUserModel.php new file mode 100644 index 00000000..84795480 --- /dev/null +++ b/src/Models/User/UsesUserModel.php @@ -0,0 +1,25 @@ +<?php + +namespace Engelsystem\Models\User; + +use Illuminate\Database\Eloquent\Relations\BelongsTo; + +/** + * @property integer $user_id + * + * @property-read \Illuminate\Database\Query\Builder|\Engelsystem\Models\User\User $user + * + * @method static \Illuminate\Database\Query\Builder|static whereUserId($value) + */ +trait UsesUserModel +{ + // protected $fillable = ['user_id']; + + /** + * @return BelongsTo + */ + public function user() + { + return $this->belongsTo(User::class); + } +} |