Refactor application general settings view for improved readability and maintainability

- Adjusted indentation and formatting for better code clarity.
- Simplified conditional statements and removed unnecessary null checks.
- Enhanced user interface elements for Docker Compose and Dockerfile configurations.
- Improved handling of deployment commands and network settings.
- Updated helper texts for better user guidance.
This commit is contained in:
Andras Bacsai
2025-12-31 11:44:08 +01:00
parent 3ffe05f0ce
commit 770ce2d327
3 changed files with 324 additions and 294 deletions

View File

@@ -558,8 +558,11 @@ class General extends Component
$this->dispatch('refreshStorages');
$this->dispatch('refreshEnvs');
} catch (\Throwable $e) {
$this->application->docker_compose_location = $this->initialDockerComposeLocation;
$this->application->save();
// Refresh model to get restored values from Application::loadComposeFile
$this->application->refresh();
// Sync restored values back to component properties for UI update
$this->syncData();
return handleError($e, $this);
} finally {