33 lines
555 B
PHP
33 lines
555 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class RandDVotingPaperAnswer extends Model
|
|
{
|
|
protected $table = 'randd_voting_paper_answers';
|
|
|
|
protected $fillable = [
|
|
'vote_id',
|
|
'score',
|
|
'score_type',
|
|
'description',
|
|
'user_id',
|
|
'q_id',
|
|
'q_fa',
|
|
'fullname'
|
|
];
|
|
|
|
public function vote()
|
|
{
|
|
return $this->belongsTo(RandDVoting::class, 'vote_id', 'id');
|
|
}
|
|
|
|
public function user()
|
|
{
|
|
return $this->belongsTo(User::class);
|
|
}
|
|
|
|
}
|