mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-14 20:40:49 +08:00
add section taxonomy
This commit is contained in:
@@ -7,6 +7,8 @@ class AudioCodec extends NexusModel
|
||||
{
|
||||
protected $table = 'audiocodecs';
|
||||
|
||||
protected $fillable = ['name', 'sort_index'];
|
||||
|
||||
public static function getLabelName()
|
||||
{
|
||||
return nexus_trans('searchbox.sub_category_audio_codec_label');
|
||||
|
||||
@@ -7,6 +7,8 @@ class Codec extends NexusModel
|
||||
{
|
||||
protected $table = 'codecs';
|
||||
|
||||
protected $fillable = ['name', 'sort_index'];
|
||||
|
||||
public static function getLabelName()
|
||||
{
|
||||
return nexus_trans('searchbox.sub_category_codec_label');
|
||||
|
||||
@@ -7,6 +7,8 @@ class Media extends NexusModel
|
||||
{
|
||||
protected $table = 'media';
|
||||
|
||||
protected $fillable = ['name', 'sort_index'];
|
||||
|
||||
public static function getLabelName()
|
||||
{
|
||||
return nexus_trans('searchbox.sub_category_media_label');
|
||||
|
||||
@@ -7,6 +7,8 @@ class Processing extends NexusModel
|
||||
{
|
||||
protected $table = 'processings';
|
||||
|
||||
protected $fillable = ['name', 'sort_index'];
|
||||
|
||||
public static function getLabelName()
|
||||
{
|
||||
return nexus_trans('searchbox.sub_category_processing_label');
|
||||
|
||||
@@ -45,6 +45,11 @@ class SearchBox extends NexusModel
|
||||
return $result;
|
||||
}
|
||||
|
||||
public static function getTaxonomyDisplayText($field)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
protected function customFields(): Attribute
|
||||
{
|
||||
return new Attribute(
|
||||
@@ -73,7 +78,7 @@ class SearchBox extends NexusModel
|
||||
return $this->hasMany(Source::class, 'mode');
|
||||
}
|
||||
|
||||
public function taxonomy_media(): \Illuminate\Database\Eloquent\Relations\HasMany
|
||||
public function taxonomy_medium(): \Illuminate\Database\Eloquent\Relations\HasMany
|
||||
{
|
||||
return $this->hasMany(Media::class, 'mode');
|
||||
}
|
||||
|
||||
@@ -5,6 +5,8 @@ namespace App\Models;
|
||||
|
||||
class Source extends NexusModel
|
||||
{
|
||||
protected $fillable = ['name', 'sort_index'];
|
||||
|
||||
public static function getLabelName()
|
||||
{
|
||||
return nexus_trans('searchbox.sub_category_source_label');
|
||||
|
||||
@@ -5,6 +5,8 @@ namespace App\Models;
|
||||
|
||||
class Standard extends NexusModel
|
||||
{
|
||||
protected $fillable = ['name', 'sort_index'];
|
||||
|
||||
public static function getLabelName()
|
||||
{
|
||||
return nexus_trans('searchbox.sub_category_standard_label');
|
||||
|
||||
@@ -5,6 +5,8 @@ namespace App\Models;
|
||||
|
||||
class Team extends NexusModel
|
||||
{
|
||||
protected $fillable = ['name', 'sort_index'];
|
||||
|
||||
public static function getLabelName()
|
||||
{
|
||||
return nexus_trans('searchbox.sub_category_team_label');
|
||||
|
||||
Reference in New Issue
Block a user