From 9e8b9cd599aeccb1698ff649e200b3c368a22d4a Mon Sep 17 00:00:00 2001 From: Boy132 Date: Sun, 19 Jan 2025 01:28:52 +0100 Subject: [PATCH] Update node record after updating (#929) * refresh node model after updating * update record so form is correctly filled --- app/Filament/Admin/Resources/NodeResource/Pages/EditNode.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/Filament/Admin/Resources/NodeResource/Pages/EditNode.php b/app/Filament/Admin/Resources/NodeResource/Pages/EditNode.php index 7078b15b5..7b893aaad 100644 --- a/app/Filament/Admin/Resources/NodeResource/Pages/EditNode.php +++ b/app/Filament/Admin/Resources/NodeResource/Pages/EditNode.php @@ -603,9 +603,12 @@ class EditNode extends EditRecord try { unset($data['unlimited_mem'], $data['unlimited_disk'], $data['unlimited_cpu']); - return $this->nodeUpdateService->handle($record, $data); + $this->record = $this->nodeUpdateService->handle($record, $data); + + return $this->record; } catch (Exception $exception) { $this->errored = true; + Notification::make() ->title('Error connecting to the node') ->body('The configuration could not be automatically updated on Wings, you will need to manually update the configuration file.')