'int', 'sort' => 'int', 'image_id' => 'array', ]; protected $fillable = [ 'title', 'image_id', 'link', 'status', 'sort', ]; protected $with = ['image']; /** * 关联图片 * @return HasOne */ public function image(): HasOne { return $this->hasOne(SysFileModel::class, 'id', 'image_id'); } }