All updates
QAFrontend

QA Promotion: Tenant Navigation Alignment, Folder Edit Fixes, and Vendor Task Detail Hardening

PR #814heytulsiprasadMar 3, 2026 · 09:46 UTC
QAMar 3, 2026

Executive summary

This release promotes a batch of frontend fixes from development into the QA environment for validation. It completes the renaming of the legacy "Entity" concept to "Tenant" across Admin navigation and the tenant-type API, fixes how AdminHub folder edits save status and tenant links, and makes vendor task-detail statistics more resilient to incomplete data from the backend.

Why this was needed

After the broader Entity-to-Tenant terminology change, several Admin links still pointed at the retired /entities route and the old entity-types API path, leaving broken navigation and stale labels. Separately, the AdminHub folder editor was sending the wrong field name for folder status and could not reliably clear a tenant or subtenant association, and vendor task-detail screens could render misleading numbers (negative counts, missing badges, skewed success rates) when the backend returned partial or missing statistics.

Client / user impact

  • Admin users get working navigation: the dashboard "View All Tenants" button and the "Create Tenant" quick action now route to /tenants, and the page title and breadcrumb read "Tenants" / "Tenant Management".
  • AdminHub folder edits now correctly persist the active/inactive status and allow a tenant or subtenant link to be explicitly cleared.
  • Vendor task-detail views show consistent, non-negative counts, a sensible "Pending" status for files awaiting conversion, and a stable success-rate figure even when the backend has not yet reported totals.
  • This batch reaches the QA environment only; it is not yet in Production.

Technical scope

Promotion of dev into qa. Notable changes (folded-in PRs #812, #813):

  • Admin routing/labels: dashboard page.tsx and AdminHeader.tsx switch /entities to /tenants for the CTA, quick action, page titles, and breadcrumbs; admin.routes.ts / admin.services.ts point tenant-types at /api/v1/tenants/tenant-types.
  • Mail tenant-type API alignment: hooks, services, routes, and query keys renamed entity→tenant (useGetTenantTypes, useGetTenantsForResolution, getTenantTypesWithMapping, TENANT_TYPES_QUERY_KEY, endpoint /v1/tenants/tenant-types), with backward-compatible aliases retained for old names.
  • AdminHub folder payload: Add/Edit folder modals and the folder mutation type send status instead of is_active; EditFolderModal parses tenant/subtenant IDs and sends null to explicitly clear, omitting the field when unchanged.
  • Vendor task detail: tasks/[taskId]/page.tsx clamps stats to non-negative integers with task-level fallbacks and derives progress when the API omits it; TaskFileList falls back through conversion_status → upload_status → status and shows a "Pending" badge; TaskProgressBar clamps to 0–100; TaskStatsGrid stabilizes the success-rate denominator; new optional status/upload_status fields added to TaskFileItem.

Risk & mitigation

Low to moderate, and well-suited to QA validation. The Admin entity-to-tenant API path change depends on the backend exposing /v1/tenants/tenant-types; if that endpoint is not live, tenant-type dropdowns could fail to load. The folder is_activestatus field rename must match the backend contract or folder status saves could be ignored. Mitigations: backward-compatible aliases preserve old hook/route names during migration, vendor changes are defensive (fallbacks only, no behavior change when data is complete), and the change set is isolated to admin, mail adminhub, and vendor task-detail surfaces.

QA validation focus

  • On the Admin dashboard, confirm "View All Tenants" opens /tenants and the "Create Tenant" quick action opens /tenants?action=create.
  • On /tenants, verify the header title shows "Tenants" and the breadcrumb shows "Tenant Management / Tenants".
  • Verify tenant-type dropdowns load (resolution add/assign modals, share-within-system dialog) against the new tenant-types endpoint.
  • In AdminHub, edit a folder: toggle active/inactive and confirm it persists; set then clear a tenant and subtenant and confirm the association is removed.
  • On a vendor task detail page, check that counts are never negative, the progress bar stays within 0–100%, files with no conversion status show "Pending", and the success rate looks correct for in-progress tasks.