commit compras1 3011
tests / ci (push) Canceled after 0s

This commit is contained in:
2026-11-30 09:33:36 +02:00
parent 96b30368bc
commit 47649bd46c
163 changed files with 9419 additions and 145 deletions
@@ -16,7 +16,9 @@ final class PrivateAuditController extends Controller
{
$scope = $access->current($this->staffIdentity($request));
$request->validate(['page' => 'nullable|integer|min:1|max:1000000']);
$exports = PrivateAuditExport::query()->where('created_by', $scope['actor']->id)->where('work_context', $scope['context'])->latest('id')->paginate(20)
$legacyIds = $access->legacyExportIds($scope['actor'], $scope['context']);
$exports = PrivateAuditExport::query()->where('created_by', $scope['actor']->id)
->where(fn ($query) => $query->where('work_context', $scope['context'])->orWhereIn('id', $legacyIds))->latest('id')->paginate(20)
->through(fn (PrivateAuditExport $export) => ['id' => $export->id, 'families' => $export->families,
'created_at' => $export->created_at, 'size' => $export->size, 'sha256' => $export->sha256,
'download_url' => '/auditoria/privada/'.$export->id.'/download']);