声明翻译的多语言
This commit is contained in:
@@ -47,7 +47,7 @@ class BrandBannerTranslationModel extends Model
|
||||
/**
|
||||
* 允许自动填充模型字段
|
||||
*/
|
||||
protected $fillable = ['id', 'brand_id', 'banner_id', 'alt', 'created_at', 'updated_at'];
|
||||
protected $fillable = ['id', 'brand_id', 'banner_id', 'alt', 'locale', 'created_at', 'updated_at'];
|
||||
|
||||
/**
|
||||
* 不允许自动填充模型字段
|
||||
|
||||
@@ -56,4 +56,10 @@ class VehicleNewTraitService extends BaseService
|
||||
// }
|
||||
];
|
||||
}
|
||||
|
||||
// 声明需要多语言翻译
|
||||
protected array $translatable = [
|
||||
'title',
|
||||
'content',
|
||||
];
|
||||
}
|
||||
Reference in New Issue
Block a user