fix
This commit is contained in:
@@ -18,6 +18,11 @@ class Add extends Component
|
||||
'value' => 'required|string',
|
||||
'is_build_time' => 'required|boolean',
|
||||
];
|
||||
protected $validationAttributes = [
|
||||
'key' => 'key',
|
||||
'value' => 'value',
|
||||
'is_build_time' => 'build',
|
||||
];
|
||||
public function mount()
|
||||
{
|
||||
$this->parameters = getRouteParameters();
|
||||
|
||||
@@ -15,6 +15,11 @@ class Show extends Component
|
||||
'env.value' => 'required|string',
|
||||
'env.is_build_time' => 'required|boolean',
|
||||
];
|
||||
protected $validationAttributes = [
|
||||
'key' => 'key',
|
||||
'value' => 'value',
|
||||
'is_build_time' => 'build',
|
||||
];
|
||||
public function mount()
|
||||
{
|
||||
$this->parameters = getRouteParameters();
|
||||
|
||||
@@ -47,6 +47,22 @@ class General extends Component
|
||||
'application.ports_exposes' => 'required',
|
||||
'application.ports_mappings' => 'nullable',
|
||||
];
|
||||
protected $validationAttributes = [
|
||||
'application.name' => 'name',
|
||||
'application.fqdn' => 'FQDN',
|
||||
'application.git_repository' => 'Git repository',
|
||||
'application.git_branch' => 'Git branch',
|
||||
'application.git_commit_sha' => 'Git commit SHA',
|
||||
'application.install_command' => 'Install command',
|
||||
'application.build_command' => 'Build command',
|
||||
'application.start_command' => 'Start command',
|
||||
'application.build_pack' => 'Build pack',
|
||||
'application.static_image' => 'Static image',
|
||||
'application.base_directory' => 'Base directory',
|
||||
'application.publish_directory' => 'Publish directory',
|
||||
'application.ports_exposes' => 'Ports exposes',
|
||||
'application.ports_mappings' => 'Ports mappings',
|
||||
];
|
||||
public function instantSave()
|
||||
{
|
||||
// @TODO: find another way - if possible
|
||||
|
||||
@@ -14,6 +14,9 @@ class Form extends Component
|
||||
protected $rules = [
|
||||
'application.preview_url_template' => 'required',
|
||||
];
|
||||
protected $validationAttributes = [
|
||||
'application.preview_url_template' => 'preview url template',
|
||||
];
|
||||
public function resetToDefault()
|
||||
{
|
||||
$this->application->preview_url_template = '{{pr_id}}.{{domain}}';
|
||||
|
||||
@@ -17,6 +17,15 @@ class ResourceLimits extends Component
|
||||
'application.limits_cpuset' => 'nullable',
|
||||
'application.limits_cpu_shares' => 'nullable',
|
||||
];
|
||||
protected $validationAttributes = [
|
||||
'application.limits_memory' => 'memory',
|
||||
'application.limits_memory_swap' => 'swap',
|
||||
'application.limits_memory_swappiness' => 'swappiness',
|
||||
'application.limits_memory_reservation' => 'reservation',
|
||||
'application.limits_cpus' => 'cpus',
|
||||
'application.limits_cpuset' => 'cpuset',
|
||||
'application.limits_cpu_shares' => 'cpu shares',
|
||||
];
|
||||
public function submit()
|
||||
{
|
||||
try {
|
||||
|
||||
@@ -16,6 +16,11 @@ class Source extends Component
|
||||
'application.git_branch' => 'required',
|
||||
'application.git_commit_sha' => 'nullable',
|
||||
];
|
||||
protected $validationAttributes = [
|
||||
'application.git_repository' => 'repository',
|
||||
'application.git_branch' => 'branch',
|
||||
'application.git_commit_sha' => 'commit sha',
|
||||
];
|
||||
private function get_private_keys()
|
||||
{
|
||||
$this->private_keys = PrivateKey::whereTeamId(session('currentTeam')->id)->get()->reject(function ($key) {
|
||||
|
||||
@@ -17,6 +17,11 @@ class Add extends Component
|
||||
'mount_path' => 'required|string',
|
||||
'host_path' => 'string|nullable',
|
||||
];
|
||||
protected $validationAttributes = [
|
||||
'name' => 'name',
|
||||
'mount_path' => 'mount',
|
||||
'host_path' => 'host',
|
||||
];
|
||||
public function mount()
|
||||
{
|
||||
$this->parameters = getRouteParameters();
|
||||
|
||||
@@ -12,6 +12,11 @@ class Show extends Component
|
||||
'storage.mount_path' => 'required|string',
|
||||
'storage.host_path' => 'string|nullable',
|
||||
];
|
||||
protected $validationAttributes = [
|
||||
'name' => 'name',
|
||||
'mount_path' => 'mount',
|
||||
'host_path' => 'host',
|
||||
];
|
||||
public function submit()
|
||||
{
|
||||
$this->validate();
|
||||
|
||||
Reference in New Issue
Block a user