This breaks literally the entire panel.

This commit is contained in:
Dane Everitt 2017-10-06 23:57:53 -05:00
parent 344c1a9885
commit df87ea0867
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
88 changed files with 1205 additions and 992 deletions

View file

@ -47,7 +47,7 @@ class Pack extends Model implements CleansAttributes, ValidableContract
'selectable' => 'sometimes|required',
'visible' => 'sometimes|required',
'locked' => 'sometimes|required',
'option_id' => 'required',
'egg_id' => 'required',
];
/**
@ -60,7 +60,7 @@ class Pack extends Model implements CleansAttributes, ValidableContract
'selectable' => 'boolean',
'visible' => 'boolean',
'locked' => 'boolean',
'option_id' => 'exists:service_options,id',
'egg_id' => 'exists:eggs,id',
];
/**
@ -69,7 +69,7 @@ class Pack extends Model implements CleansAttributes, ValidableContract
* @var array
*/
protected $casts = [
'option_id' => 'integer',
'egg_id' => 'integer',
'selectable' => 'boolean',
'visible' => 'boolean',
'locked' => 'boolean',
@ -83,9 +83,8 @@ class Pack extends Model implements CleansAttributes, ValidableContract
protected $searchableColumns = [
'name' => 10,
'uuid' => 8,
'option.name' => 6,
'option.tag' => 5,
'option.docker_image' => 5,
'egg.name' => 6,
'egg.docker_image' => 5,
'version' => 2,
];
@ -114,13 +113,13 @@ class Pack extends Model implements CleansAttributes, ValidableContract
}
/**
* Gets option associated with a service pack.
* Gets egg associated with a service pack.
*
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
public function option()
public function egg()
{
return $this->belongsTo(ServiceOption::class);
return $this->belongsTo(Egg::class);
}
/**