You've already forked isop-mirror
fix: add hidden attributes for serialization in models and update contact method in Company model
This commit is contained in:
@@ -23,6 +23,16 @@ class Company extends Model
|
||||
'hiring'
|
||||
];
|
||||
|
||||
/**
|
||||
* The attributes that should be hidden for serialization.
|
||||
*
|
||||
* @var list<string>
|
||||
*/
|
||||
protected $hidden = [
|
||||
'created_at',
|
||||
'updated_at',
|
||||
];
|
||||
|
||||
/**
|
||||
* Get the internships for the company.
|
||||
*/
|
||||
@@ -34,7 +44,7 @@ class Company extends Model
|
||||
/**
|
||||
* Get the contact person (user) for the company.
|
||||
*/
|
||||
public function contactPerson()
|
||||
public function contact()
|
||||
{
|
||||
return $this->belongsTo(User::class, 'contact');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user