fix(deployments): order deployments by ID for consistent retrieval

- Added ordering by ID to the deployments query to ensure consistent results.
- Removed unnecessary sorting after retrieval to streamline the data handling process.
This commit is contained in:
Andras Bacsai 2025-10-01 20:10:22 +02:00
parent 89c4f83bc5
commit 464b76e597

View file

@ -18,6 +18,7 @@ public function deployments()
return ApplicationDeploymentQueue::whereIn('status', ['in_progress', 'queued'])
->whereIn('server_id', $servers->pluck('id'))
->orderBy('id')
->get([
'id',
'application_id',
@ -27,8 +28,7 @@ public function deployments()
'server_name',
'server_id',
'status',
])
->sortBy('id');
]);
}
#[Computed]