fix: assign onboarding group through model properties

This commit is contained in:
hellcat 2026-10-11 15:59:52 +08:00
parent dfdfbf2562
commit 9a523b625c

View File

@ -38,7 +38,9 @@ file_put_contents("$dir/before.json", json_encode([
], JSON_THROW_ON_ERROR));
$manifest = DB::transaction(function () use ($opts) {
$group = ServerGroup::create(['name' => 'dpl 接入验收 ' . $opts['key']]);
$group = new ServerGroup();
$group->name = 'dpl 接入验收 ' . $opts['key'];
$group->save();
$machine = ServerMachine::create([
'name' => 'dpl-' . $opts['key'], 'notes' => 'Independent AnyTLS service; existing XrayR preserved',
'is_active' => true, 'token' => ServerMachine::generateToken(),