mirror of
https://git.meshkee.com/cssd/cssd-back.git
synced 2026-10-11 02:31:05 +03:30
20 lines
473 B
PHP
20 lines
473 B
PHP
<?php
|
|
|
|
namespace App;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Illuminate\Database\Eloquent\SoftDeletes;
|
|
|
|
class Message extends Model
|
|
{
|
|
use SoftDeletes;
|
|
public $fillable = ['title', 'text', 'status', 'recipient_user_id', 'sender_user_id'];
|
|
public function sender_user()
|
|
{
|
|
return $this->belongsTo('App\User', 'sender_user_id');
|
|
}
|
|
public function recipient_user()
|
|
{
|
|
return $this->belongsTo('App\User', 'recipient_user_id');
|
|
}
|
|
}
|