first commit
This commit is contained in:
30
app/Models/Response.php
Normal file
30
app/Models/Response.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Response extends Model
|
||||
{
|
||||
protected $fillable = [
|
||||
'survey_id',
|
||||
'user_id',
|
||||
'respondent_name',
|
||||
'respondent_no_pekerja',
|
||||
'respondent_jabatan',
|
||||
];
|
||||
|
||||
|
||||
public function survey()
|
||||
{
|
||||
return $this->belongsTo(Survey::class);
|
||||
}
|
||||
public function user()
|
||||
{
|
||||
return $this->belongsTo(User::class);
|
||||
} // Responden
|
||||
public function answers()
|
||||
{
|
||||
return $this->hasMany(Answer::class);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user