update assigment lintas region
This commit is contained in:
39
app/Models/PenilaianTeam.php
Normal file
39
app/Models/PenilaianTeam.php
Normal file
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\PenilaianTeamFactory;
|
||||
|
||||
class PenilaianTeam extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'penilaian_team';
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['penilaian_id', 'team_id', 'user_id','role'];
|
||||
|
||||
|
||||
public function userPenilaiTeam()
|
||||
{
|
||||
return $this->belongsTo(User::class, 'user_id', 'id');
|
||||
}
|
||||
|
||||
public function team(){
|
||||
|
||||
return $this->belongsTo(Team::class, 'team_id', 'id');
|
||||
}
|
||||
|
||||
public function penilaian(){
|
||||
|
||||
return $this->belongsTo(Penilaian::class, 'penilaian_id', 'id');
|
||||
}
|
||||
|
||||
protected static function newFactory(): PenilaianTeamFactory
|
||||
{
|
||||
//return PenilaianTeamFactory::new();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user