You've already forked Epicnabbo-Catalogus-Updated-Daily
Add Team model and controller from upstream
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models\Community\Teams;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Relations\HasMany;
|
||||
|
||||
class WebsiteTeam extends Model
|
||||
{
|
||||
protected $table = 'website_teams';
|
||||
|
||||
protected $fillable = [
|
||||
'name',
|
||||
'description',
|
||||
'rank_name',
|
||||
'is_active',
|
||||
];
|
||||
|
||||
protected $casts = [
|
||||
'is_active' => 'boolean',
|
||||
];
|
||||
|
||||
public function applications(): HasMany
|
||||
{
|
||||
return $this->hasMany(\App\Models\Community\Staff\WebsiteStaffApplications::class, 'team_id');
|
||||
}
|
||||
|
||||
public function openPositions(): HasMany
|
||||
{
|
||||
return $this->hasMany(\App\Models\Community\Staff\WebsiteOpenPosition::class, 'team_id');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user