All updates
QAFrontend

QA: Admin, Vendor & Mail Improvements — Paginated Data Tables, Vendor Upload Retry, and Cleaner Error Handling

PR #770heytulsiprasadJan 19, 2026 · 17:16 UTC
QAJan 19, 2026

Executive summary

A batch of ~20 frontend changes was promoted to the QA environment, spanning the Admin, Vendor, and Mail apps plus shared UI. Highlights include floating paginated/searchable data tables across the Admin portal, server-side pagination and search for Vendor upload tasks, a new failed-uploads retry/re-upload workflow, and a smarter error-toast system that no longer alarms users when a request quietly succeeds on retry.

Why this was needed

Several Admin and Vendor screens loaded entire datasets at once and exposed non-functional UI (placeholder checkboxes, disabled menu items), which scaled poorly and confused users. Failed vendor uploads had no recovery path, some bulk operations gave no feedback, and transient API errors triggered scary toasts even when an automatic retry succeeded. This batch addresses those usability, scalability, and reliability gaps.

Client / user impact

  • Admin data tables (Users, Entities, Permissions, etc.) now paginate and search server-side with a floating pagination bar (page jump, rows-per-page), staying responsive on large datasets.
  • Vendors can retry or re-upload failed files directly from the View Files modal instead of being stuck.
  • Bulk folder activate/deactivate and bulk user/entity actions now show clear success, partial-success, and skipped-item toasts and refresh the grid automatically.
  • Fewer false-alarm error messages: users only see an error toast after automatic retries are exhausted.
  • Cleaner UI: non-functional checkboxes removed and Edit/Delete hidden (not just greyed out) for protected system folders and document types.

Technical scope

Grounded in the diff (51 files, +2441/-728). Notable changes:

  • Admin data-table (components/common/data-table.tsx, +458): floating pagination bar, page-number buttons with ellipsis, 'Go to' input, rows-per-page selector, 300ms debounced search (hooks/useDebounce.ts); enabled across the Admin portal pages.
  • Permissions page: rewritten to use the paginated DataTable with new getPermissionsList/usePermissionsList; PermissionMatrix now uses useInfinitePermissions 'Load more' paging.
  • Role form: removed unused role_code, switched from auto-save to explicit submit, chains create-role then assign-permissions; assignUserRoles and bulk assign moved PUT→POST; removed unsupported user first_name/last_name fields.
  • Error handling: Mail/Vendor/Admin query-client.provider.tsx add global QueryCache/MutationCache onError handlers (sonner toasts for 403/5xx/network/unexpected); error toasts removed from HTTP interceptors (401 kept for auth redirect).
  • Vendor: TaskList gains server-side pagination + search (limitsize, new search param); new FailedUploadsSection with retry and a new mailReupload route/service; case-insensitive status mapping; visible horizontal scrollbar in ViewFilesModal; removed duplicate close button and a non-functional Refresh button.
  • Mail: bulkDeleteMails moved from a query-string DELETE to a POST with a JSON body (mail_ids, user_id, permanent); 'Add Document' button added to documents page.
  • Cleanup: removed non-functional checkboxes from Rules Engine and several tables; hide Edit/Delete for system folders/document types.
  • Shared/infra: AppSwitcher reworked for theme-aware (light/dark) colors and dropdown width; NEXT_PUBLIC_SOCKET_URL build arg added to Dockerfile and the ECR workflow.

Risk & mitigation

Moderate, breadth-driven: this touches many high-traffic Admin/Vendor screens and shared providers, so a regression in the data-table or query-client could affect multiple pages at once. Several API contract changes (bulk-delete DELETE→POST, role assignment PUT→POST, vendor limitsize param) depend on matching backend behavior. Mitigation: changes are isolated to the QA environment for verification before any production promotion, and error-handling moved to a single centralized location reducing duplication.

QA validation focus

  • Admin tables: verify pagination (page buttons, 'Go to', rows-per-page), debounced search, and that grids auto-refresh after create/edit/bulk actions.
  • Mail: confirm bulk delete works via the new POST endpoint for both soft delete and permanent delete.
  • Vendor: test upload-tasks pagination/search, the failed-uploads retry and re-upload flows, status display, and the visible horizontal scrollbar in View Files.
  • Roles/Permissions: create a role, assign permissions, and load the permission matrix incrementally; confirm role assignment succeeds via POST.
  • Error toasts: trigger a transient/retryable failure and confirm no premature toast, plus correct toasts for 403, 5xx, and network errors; confirm 401 still redirects.
  • Bulk folder activate/deactivate: verify success, partial-success, and skipped messaging.
  • AppSwitcher: check dropdown rendering and colors in both light and dark themes.