mirror of
https://github.com/pelican-dev/panel.git
synced 2025-05-29 13:14:45 +02:00
Populate these fields for server variables
This commit is contained in:
parent
6b0c1d136b
commit
2d7804311d
@ -173,11 +173,15 @@ class ServerCreationService
|
|||||||
*/
|
*/
|
||||||
private function storeEggVariables(Server $server, Collection $variables): void
|
private function storeEggVariables(Server $server, Collection $variables): void
|
||||||
{
|
{
|
||||||
$records = $variables->map(function ($result) use ($server) {
|
$now = now();
|
||||||
|
|
||||||
|
$records = $variables->map(function ($result) use ($server, $now) {
|
||||||
return [
|
return [
|
||||||
'server_id' => $server->id,
|
'server_id' => $server->id,
|
||||||
'variable_id' => $result->id,
|
'variable_id' => $result->id,
|
||||||
'variable_value' => $result->value ?? '',
|
'variable_value' => $result->value ?? '',
|
||||||
|
'created_at' => $now,
|
||||||
|
'updated_at' => $now,
|
||||||
];
|
];
|
||||||
})->toArray();
|
})->toArray();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user