mirror of
https://github.com/pelican-dev/panel.git
synced 2025-05-29 16:44:44 +02:00
Update passed in hidden data to include actual changed server variable values
This commit is contained in:
parent
a839078c7d
commit
191f1456ee
@ -447,7 +447,12 @@ class CreateServer extends CreateRecord
|
|||||||
},
|
},
|
||||||
])
|
])
|
||||||
->label(fn (Forms\Get $get) => $get('name'))
|
->label(fn (Forms\Get $get) => $get('name'))
|
||||||
//->hint('Rule')
|
->live()
|
||||||
|
->afterStateUpdated(function (Forms\Set $set, Forms\Get $get, $state) {
|
||||||
|
$environment = $get($envPath = '../../environment');
|
||||||
|
$environment[$get('env_variable')] = $state;
|
||||||
|
$set($envPath, $environment);
|
||||||
|
})
|
||||||
->hintIcon('tabler-code')
|
->hintIcon('tabler-code')
|
||||||
->hintIconTooltip(fn (Forms\Get $get) => $get('rules'))
|
->hintIconTooltip(fn (Forms\Get $get) => $get('rules'))
|
||||||
->prefix(fn (Forms\Get $get) => '{{' . $get('env_variable') . '}}')
|
->prefix(fn (Forms\Get $get) => '{{' . $get('env_variable') . '}}')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user