А
Size: a a a
А
AV
С
W
ПК
ПК
ПК
ПК
P
ПК
4
public function participants()
{
return $this->belongsToMany(User::class, 'assignment_participants')->withPivot('role');
}
public function surveyor()
{
return $this->participants()->where('role', static::ROLE_SURVEYOR)->limit(1);
}
T0
public function participants()
{
return $this->belongsToMany(User::class, 'assignment_participants')->withPivot('role');
}
public function surveyor()
{
return $this->participants()->where('role', static::ROLE_SURVEYOR)->limit(1);
}
ПК
ПК
ПК
4
EG
public function participants()
{
return $this->belongsToMany(User::class, 'assignment_participants')->withPivot('role');
}
public function surveyor()
{
return $this->participants()->where('role', static::ROLE_SURVEYOR)->limit(1);
}
4
4
EG
public function getSurveyorAttributes()
{
return $this->participants()->where('role', static::ROLE_SURVEYOR)->limit(1)->first();
}