2018-01-15 15:24:11 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Models;
|
|
|
|
|
2018-06-10 14:37:37 +00:00
|
|
|
/**
|
|
|
|
* Class Reply
|
|
|
|
* @property int id
|
|
|
|
* @property string content
|
|
|
|
* @property string created_at
|
|
|
|
* @property string updated_at
|
|
|
|
* @property int user_id
|
|
|
|
* @property int topic_id
|
|
|
|
* @property User user
|
|
|
|
* @package App\Models
|
|
|
|
*/
|
2018-01-15 15:24:11 +00:00
|
|
|
class Reply extends Model
|
|
|
|
{
|
|
|
|
protected $fillable = ['content'];
|
|
|
|
|
|
|
|
|
|
|
|
public function topic()
|
|
|
|
{
|
|
|
|
return $this->belongsTo(Topic::class);
|
|
|
|
}
|
|
|
|
|
|
|
|
public function user()
|
|
|
|
{
|
|
|
|
return $this->belongsTo(User::class);
|
|
|
|
}
|
|
|
|
}
|