[#2] some progress
This commit is contained in:
@@ -41,6 +41,36 @@ class ItemToFetchJobs extends Model
|
||||
self::JOB_CONTENT_RATINGS,
|
||||
];
|
||||
|
||||
public const MOVIE_JOBS = [
|
||||
self::JOB_ALTERNVATIVE_TITLES,
|
||||
self::JOB_CREDITS,
|
||||
self::JOB_IMAGES,
|
||||
self::JOB_KEYWORDS,
|
||||
self::JOB_RELEASES,
|
||||
self::JOB_TRANSLATIONS,
|
||||
self::JOB_SIMILAR,
|
||||
self::JOB_RECOMMNDATION,
|
||||
self::JOB_REVIEWS,
|
||||
self::JOB_LISTS,
|
||||
self::JOB_VIDEOS,
|
||||
self::JOB_WATCH_PROVIDERS,
|
||||
self::JOB_EXTERNAL_IDS,
|
||||
];
|
||||
|
||||
public const SHOW_JOBS = [
|
||||
self::JOB_ALTERNVATIVE_TITLES,
|
||||
self::JOB_CREDITS,
|
||||
self::JOB_IMAGES,
|
||||
self::JOB_KEYWORDS,
|
||||
self::JOB_TRANSLATIONS,
|
||||
self::JOB_SIMILAR,
|
||||
self::JOB_RECOMMNDATION,
|
||||
self::JOB_VIDEOS,
|
||||
self::JOB_WATCH_PROVIDERS,
|
||||
self::JOB_EXTERNAL_IDS,
|
||||
self::JOB_CONTENT_RATINGS,
|
||||
];
|
||||
|
||||
protected $fillable = [
|
||||
'tmdb_id',
|
||||
'item_id',
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class ProductionCompany extends Model
|
||||
{
|
||||
protected $fillable = [
|
||||
'tmdb_id',
|
||||
'logo_path',
|
||||
'name',
|
||||
'origin_country',
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class ProductionCountry extends Model
|
||||
{
|
||||
protected $fillable = [
|
||||
'iso_3166',
|
||||
'name',
|
||||
];
|
||||
}
|
||||
@@ -80,4 +80,14 @@ class Show extends Model
|
||||
{
|
||||
return $this->belongsToMany(Network::class, 'show_networks', 'show_id', 'network_id');
|
||||
}
|
||||
|
||||
public function productionCompanies()
|
||||
{
|
||||
return $this->belongsToMany(ProductionCompany::class, 'show_production_companies', 'show_id', 'production_company_id');
|
||||
}
|
||||
|
||||
public function productionCountries()
|
||||
{
|
||||
return $this->belongsToMany(ProductionCountry::class, 'show_production_countries', 'show_id', 'production_country_id');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user