mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-17 05:43:45 +02:00
ui(admin): add search and sort to ServersContainer
This commit is contained in:
@@ -125,7 +125,9 @@ class ServerTransferController extends Controller
|
||||
$server = $this->connection->transaction(function () use ($server, $transfer) {
|
||||
$allocations = [$transfer->old_allocation];
|
||||
if (!empty($transfer->old_additional_allocations)) {
|
||||
array_push($allocations, $transfer->old_additional_allocations);
|
||||
foreach ($transfer->old_additional_allocations as $allocation) {
|
||||
$allocations[] = $allocation;
|
||||
}
|
||||
}
|
||||
|
||||
// Remove the old allocations for the server and re-assign the server to the new
|
||||
@@ -169,7 +171,9 @@ class ServerTransferController extends Controller
|
||||
|
||||
$allocations = [$transfer->new_allocation];
|
||||
if (!empty($transfer->new_additional_allocations)) {
|
||||
array_push($allocations, $transfer->new_additional_allocations);
|
||||
foreach ($transfer->new_additional_allocations as $allocation) {
|
||||
$allocations[] = $allocation;
|
||||
}
|
||||
}
|
||||
|
||||
Allocation::query()->whereIn('id', $allocations)->update(['server_id' => null]);
|
||||
|
||||
Reference in New Issue
Block a user