1
0
mirror of https://github.com/robonen/metr.git synced 2026-03-20 02:44:42 +00:00
Files
metr/backend/app/Models/Feedback.php
2022-06-01 23:32:14 +07:00

43 lines
829 B
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
class Feedback extends Model
{
use HasFactory;
/**
* The attributes that are mass assignable.
*
* @var array<int, string>
*/
protected $fillable = [
'user_id',
'comment',
'rating',
];
/**
* The attributes that should be cast.
*
* @var array<string, string>
*/
protected $casts = [
'rating' => 'integer',
];
/**
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
// public function user(): BelongsTo
// {
// return $this
// ->belongsTo(User::class)
// ->select('first_name');
// }
}