Acceptance Criteria — Web Portal, Manage Lawyers (WPLAW)¶
User Story¶
As a Web Portal Admin I want to add, edit, delete, filter, import, and export lawyers on the Manage Lawyers screen So that the lawyer directory stays accurate, complete, and available to end users
Scenario-based AC — Given / When / Then¶
| AC ID | Scenario | Jira | Type | Criticality | Given (context) | When (action / trigger) | Then (expected outcome) | Linked TCs | Status |
|---|---|---|---|---|---|---|---|---|---|
| AC-WPLAW-01 | Admin adds a new lawyer | RC-107 | Happy | 🔴 Critical | Admin has the Add Lawyer form open | Admin fills Full Name, First name, Last name, Email, Mobile, Status, Full address, and Rate with valid values, then selects Add | A new lawyer record is created and appears in the Manage Lawyers list with the entered data | TC-WPLAW-001 |
Draft |
| AC-WPLAW-02 | Admin assigns an existing company to a lawyer from the Company name dropdown | RC-107 | Happy | 🟡 Medium | Admin has the Add Lawyer (or Edit Lawyer) form open; the Company name field offers a searchable list of existing companies | Admin opens the Company name dropdown and selects an existing company, then saves | The selected company is stored as the lawyer's Company name and shown in the Company name column of the list | TC-WPLAW-002 |
Draft |
| AC-WPLAW-03 | Opening Edit shows the lawyer's current data | RC-107 | Happy | 🔴 Critical | Admin is on the Manage Lawyers list, viewing an existing lawyer's row | Admin selects Edit for that lawyer | The Edit Lawyer panel opens pre-filled with that lawyer's current Full Name, First name, Last name, Email, Mobile, Status, Full address, Rate, and Company name — no field is blank or stale | TC-WPLAW-003 |
Draft |
| AC-WPLAW-04 | Saving an edit persists and immediately reflects the new data | RC-107 | Happy | 🔴 Critical | Admin has the Edit Lawyer panel open and changes one or more fields | Admin selects Save | The lawyer record is updated And the Manage Lawyers list shows the newly saved values immediately, without a manual page reload |
TC-WPLAW-004 |
Draft |
| AC-WPLAW-05 | Cancelling an edit discards unsaved changes | RC-107 | Alternate | 🟡 Medium | Admin has the Edit Lawyer panel open and has changed one or more fields | Admin selects Cancel | The panel closes And the lawyer's stored data remains exactly as it was before the edit |
TC-WPLAW-005 |
Draft |
| AC-WPLAW-06 | Selecting Delete opens a confirmation prompt | RC-107 | Happy | 🟠 High | Admin is viewing the Manage Lawyers list | Admin selects Delete on a lawyer's row | A confirmation modal opens asking "Are you sure you want to delete this record?" with Yes, I'm sure and No, cancel actions | TC-WPLAW-006 |
Draft |
| AC-WPLAW-07 | Confirming delete removes the row from the list immediately | RC-107 | Happy | 🔴 Critical | The delete confirmation modal is open for a lawyer | Admin selects Yes, I'm sure | The lawyer record is deleted And its row disappears from the Manage Lawyers list immediately, without requiring a page reload |
TC-WPLAW-007 |
Draft |
| AC-WPLAW-08 | Confirming delete updates the total record count immediately | RC-107 | Happy | 🟠 High | The delete confirmation modal is open for a lawyer; the list currently shows N total records | Admin selects Yes, I'm sure | The displayed total record count decreases to N−1 immediately, without a manual page reload | TC-WPLAW-008 |
Draft |
| AC-WPLAW-09 | Cancelling the delete prompt keeps the record unchanged | RC-107 | Alternate | 🟡 Medium | The delete confirmation modal is open for a lawyer | Admin selects No, cancel | The modal closes And the lawyer record remains in the list, unchanged |
TC-WPLAW-009 |
Draft |
| AC-WPLAW-10 | Every lawyer row shows a valid Id | RC-107 | Happy | 🟠 High | The Manage Lawyers list is populated with lawyer records | Admin views the Id column | Every row shows its correct, non-blank Id value — no row has a missing or empty Id | TC-WPLAW-010 |
Draft |
| AC-WPLAW-11 | Company name displays correctly for lawyers that have one set | RC-107 | Happy | 🟠 High | A lawyer record has a Company name assigned | Admin views that lawyer's row in the Manage Lawyers list | The Company name column shows the assigned company for that row | TC-WPLAW-011 |
Draft |
| AC-WPLAW-12 | Filtering by Full Name narrows the lawyer list | RC-107 | Happy | 🔴 Critical | Admin opens Filter by on the Manage Lawyers list | Admin enters a value in Full Name and selects Apply | Only lawyers whose full name matches the entered value are shown in the list | TC-WPLAW-012 |
Draft |
| AC-WPLAW-13 | Filtering by Email narrows the lawyer list | RC-107 | Happy | 🟡 Medium | Admin opens Filter by on the Manage Lawyers list | Admin enters a value in Email and selects Apply | Only lawyers whose email matches the entered value are shown | TC-WPLAW-013 |
Draft |
| AC-WPLAW-14 | Filtering by Mobile narrows the lawyer list | RC-107 | Happy | 🟡 Medium | Admin opens Filter by on the Manage Lawyers list | Admin enters a value in Mobile and selects Apply | Only lawyers whose mobile number matches the entered value are shown | TC-WPLAW-014 |
Draft |
| AC-WPLAW-15 | Filtering by Status narrows the lawyer list | RC-107 | Happy | 🟡 Medium | Admin opens Filter by on the Manage Lawyers list | Admin enters a value in Status and selects Apply | Only lawyers with that status are shown | TC-WPLAW-015 |
Draft |
| AC-WPLAW-16 | Filtering by Full address narrows the lawyer list | RC-107 | Happy | 🟡 Medium | Admin opens Filter by on the Manage Lawyers list | Admin enters a value in Full address and selects Apply | Only lawyers whose address matches the entered value are shown | TC-WPLAW-016 |
Draft |
| AC-WPLAW-17 | Filtering by Company name narrows the lawyer list | RC-107 | Happy | 🟠 High | Admin opens Filter by on the Manage Lawyers list | Admin enters a value in Company name and selects Apply | Only lawyers belonging to that company are shown | TC-WPLAW-017 |
Draft |
| AC-WPLAW-18 | Importing a valid file adds the lawyers it contains | RC-107 | Happy | 🔴 Critical | Admin opens Import and has a well-formed .xlsx or .csv file of lawyer records |
Admin selects/drags the file and confirms the import | Every lawyer row in the file is created and appears in the Manage Lawyers list | TC-WPLAW-018 |
Draft |
| AC-WPLAW-19 | Import rejects a file that isn't .xlsx or .csv | RC-107 | Negative | 🟡 Medium | Admin opens Import ("Files format should be xlsx, csv") | Admin selects a file with an unsupported extension (e.g. .txt, .pdf) |
The import is rejected before processing And an error message states the accepted formats (xlsx, csv) |
TC-WPLAW-019 |
Draft |
| AC-WPLAW-20 | Import does not create a lawyer record from the file's header/title row | RC-107 | Negative | 🟠 High | Admin imports a file whose first row is the column header/title row | Admin confirms the import | No lawyer record is created from the header row And only the data rows below it are imported |
TC-WPLAW-020 |
Draft |
| AC-WPLAW-21 | Imported Email values render as plain text, never as HTML markup | RC-107 | Negative | 🔴 Critical | Admin imports a file whose Email column contains raw HTML content in one or more cells | Import completes and Admin views the resulting lawyer rows | The Email column displays the cell's content as plain, escaped text — no HTML is rendered/executed in the page | TC-WPLAW-021 |
Draft |
| AC-WPLAW-22 | Exporting produces a downloadable file of the lawyer list | RC-107 | Happy | 🟠 High | Admin is on the Manage Lawyers list (filtered or unfiltered) | Admin selects Export | A file is generated and downloaded containing the currently listed lawyer records | TC-WPLAW-022 |
Draft |
| AC-WPLAW-23 | Add/Edit/Filter Lawyer forms show clear separation between Company name and the action buttons | RC-107 | Edge | ⚪ Low | Admin has the Add Lawyer, Edit Lawyer, or Filter panel open, with the Company name field as the last field before the action buttons | Admin views the bottom of the form | There is visible spacing between the Company name field and the Cancel/Add/Save/Apply buttons — they are not visually crowded together | TC-WPLAW-023 |
Draft |
Business Rules (rule-based AC)¶
| Rule ID | Business Rule | Jira | Rationale / Source | Criticality | Linked TCs | Status |
|---|---|---|---|---|---|---|
| BR-WPLAW-01 | The Import function only accepts .xlsx and .csv files; any other file type must be rejected before processing. |
RC-107 | Import modal: "Files format should be xlsx, csv" | 🟡 Medium | TC-WPLAW-019 |
Draft |
| BR-WPLAW-02 | Import must treat the file's first (header/title) row as column labels, not as lawyer data — it must never be inserted as a record. | RC-107 | QA bug report (comment 2026-07-28): "import title file also [fails]" | 🟠 High | TC-WPLAW-020 |
Draft |
| BR-WPLAW-03 | All field values ingested via Import (including Email) must be sanitized/escaped on render so that HTML or script content in a source cell is never rendered or executed in the page. | RC-107 | QA bug report (comment 2026-07-28): "show html in email column" — potential stored-content rendering (XSS) risk, not merely cosmetic | 🔴 Critical | TC-WPLAW-021 |
Draft |
| BR-WPLAW-04 | Deleting a lawyer must update the visible list and the total record count immediately — never requiring a manual page reload to reflect the change. | RC-107 | QA bug reports (comments 2026-07-22, 2026-07-23) | 🔴 Critical | TC-WPLAW-007, TC-WPLAW-008 |
Draft |
| BR-WPLAW-05 | The free-text Find Lawyers search box is out of scope for this ticket and is not to be validated until re-enabled by a future ticket. | RC-107 | Jira description: "Note: Not apply search Find lawyer" | 🟡 Medium | Draft | |
| BR-WPLAW-06 | This feature (Web Portal — Manage Lawyers) is the single source of truth for a lawyer's Full Name, Address, Rate, and Company; every add, edit, and delete made here must propagate to and be reflected by the consumer-facing Lawyer Web app (feature lawyer). |
— |
Stakeholder confirmation (chat, 2026-08-10) | 🟠 High | TC-LAW-022, TC-LAW-023, TC-LAW-024 (verified in feature LAW) |
Draft |
Column Guide¶
| Column | Description | Values / Format |
|---|---|---|
| AC ID | Unique scenario id — TCs trace back to this | AC-WPLAW-NN |
| Rule ID | Unique business-rule id — TCs trace back to this | BR-WPLAW-NN |
| Scenario | Short title of the behaviour, start with an action verb | Plain text |
| Jira | The ticket this AC came from | [RC-107](url) |
| Type | Class of scenario | Happy / Alternate / Negative / Edge / Permission |
| Criticality | Impact if this AC fails — drives the verifying TC's priority | 🔴 Critical / 🟠 High / 🟡 Medium / ⚪ Low |
| Given | Precondition / context true before the action | One state per clause; <br>And … to compound |
| When | The single action or event that triggers behaviour | One trigger |
| Then | Observable, verifiable outcome — pass/fail must be objective | Include error code / message / state where relevant |
| Linked TCs | TCs in 01_Features/lawyer/wp_lawyer/wp_lawyer_tc.md that verify this AC |
TC-WPLAW-NNN, comma-separated |
| Status | Review state of the criterion | Draft / Reviewed / Approved |
Traceability¶
Jira ticket ──▶ AC-WPLAW-NN / BR-WPLAW-NN ──▶ TC-WPLAW-NNN
(the why) (the what — this file) (the how to verify)
- Upward: header
SRS ref+ each row'sJiracolumn link the AC to its source (RC-107). - Downward: the
Linked TCscolumn lists the test cases that verify each AC — to be filled by/gen-tc. - Coverage rule: every
CriticalandHighAC and every business rule must have ≥1 Linked TC. Flag any such AC with zero TCs as a coverage gap. Conversely, every TC must name theACit verifies — no orphan TCs.