mirror of
https://github.com/tiennm99/coolify.git
synced 2026-10-06 22:15:02 +00:00
ui fixes
This commit is contained in:
1 parent
23f58b8c13
commit
539f82eb08
9 files changed
+66
-34
No files matched your search
@@ -15,13 +15,20 @@ class Add extends Component
|
||||
public string $value;
|
||||
public bool $is_build_time = false;
|
||||
|
||||
protected $rules = [
|
||||
'key' => 'required|string',
|
||||
'value' => 'required|string',
|
||||
'is_build_time' => 'required|boolean',
|
||||
];
|
||||
public function mount()
|
||||
{
|
||||
$this->parameters = Route::current()->parameters();
|
||||
}
|
||||
public function submit()
|
||||
{
|
||||
$this->validate();
|
||||
try {
|
||||
|
||||
$application_id = Application::where('uuid', $this->parameters['application_uuid'])->firstOrFail()->id;
|
||||
EnvironmentVariable::create([
|
||||
'key' => $this->key,
|
||||
@@ -29,7 +36,9 @@ class Add extends Component
|
||||
'is_build_time' => $this->is_build_time,
|
||||
'application_id' => $application_id,
|
||||
]);
|
||||
$this->emit('reloadWindow');
|
||||
$this->emit('refreshEnvs');
|
||||
$this->key = '';
|
||||
$this->value = '';
|
||||
} catch (mixed $e) {
|
||||
dd('asdf');
|
||||
if ($e instanceof QueryException) {
|
||||
|
||||
Reference in new issue
Block a user