Discard a bill¶
A user discards the current bill, which sets its status to discarded and then either returns to the Inbox or, with Auto feed checked, loads the next queue bill.
Trigger and screens¶
| Item | Detail |
|---|---|
| Trigger | User selects Discard on the Bill entry screen |
| Screens | Bill entry |
| Tables | Not traced** |
Steps¶
- When the screen loads,
Entry.IndexchecksCBEDiscardBilland hides the Discard button when it is missing (BR-SCR-006). - The user selects Discard and confirms.
- The screen posts to Entry.DiscardBill.
- The action maps the posted worker to a
Billwith AutoMapper. - The action calls
IBillEntryService.UpdateBillStatuswith the bill id, the mail idSYSTEMand the statusDIS. It does not checkCBEDiscardBill(BR-SCR-006). - The action reads the remaining queue count with
IBillEntryService.GetClaimBillQueueRemainingCountand returns the bill view model as JSON.
Origin: Steps 3.2–3.3 are the controller-side calls to
IBillEntryServiceinSAIF.SAIFCode.Core†. Per the Legends CLI RAG service,SAIF.SAIFCode.Coreis a contracts-only library and this interface's implementation lives outside it (most likelySAIF.Services), which this run did not trace*. 4. On success the client checks the Auto feed checkbox (ClaimBillEntry/js/ClaimBillEntry.entry.js:255-263). 1. When Auto feed is checked, the screen loads the next queue bill throughgetNextQueueBilland stays on Bill entry. 2. When Auto feed is not checked, the browser navigates to the Inbox screen.
Process flow¶
The diagram shows the main path and its decision points.
flowchart TD
A["Bill entry loads"] --> B{"CBEDiscardBill held?"}
B -->|"No"| X["Discard button hidden"]
B -->|"Yes"| C["User selects Discard"]
C --> D["DiscardBill sets status DIS"]
D --> G{"Auto feed checked?"}
G -->|"Yes"| H["Load next queue bill<br>(stay on Bill entry)"]
G -->|"No"| E["Navigate to Inbox"]
Failure and edge-case behavior¶
- Because the server does not check the permission, any user in the
CBPEnterBillrole who calls the endpoint directly can discard a bill (BR-SCR-006; see Tech debt).
Related documentation¶
- Operations and processes
- Business rules
- Hosted endpoints
- Data model
- Architecture
- Tech debt
- Screen catalog
Note: Statements marked with
†are derived from dependency library documentation via the Legends CLI. Statements marked with*were inferred from code structure or contextual evidence. Statements marked with**could not be confirmed; treat as unknown until verified.
Sources¶
- ClaimBillEntry/Controllers/EntryController.cs
- ClaimBillEntry/js/ClaimBillEntry.entry.js