Pay online¶
Steps¶
- The user selects Pay Online.
PaymentModal.jspoststotalAmount,maxAmountandpolicyNumto/NDReimbursement/PayOnlinewith no anti-forgery token (BR-APP-006). - The handler requires
0 < total <= max(BR-SCR-007); otherwise it returns null.maxand the policy number come from the client (TD-APP-006). OneIncServicecreates the payment request throughOneIncAPIClient.CreateMakePaymentRequest(known from the call site inOneIncService.cs; package internals are unknown**), and the script opens the portalOne modal.- If the call throws, the handler logs the exception and returns null, the same result as a failed amount check. Pending online payments later block the claims-saved state (BR-SCR-008).
Process flow¶
The diagram shows the amount check, the payment-request call and the null result returned when validation fails or an exception is caught.
flowchart TD
A["Pay Online"] --> B["POST PayOnline"]
B --> C{"0 < total <= max?"}
C -- No --> D["Return null"]
C -- Yes --> E["Create payment request via OneIncAPIClient"]
E -- "Success" --> F["Open payment modal"]
E -- "Exception caught, logged" --> D
Note: Statements marked with
**could not be confirmed; treat as unknown until verified.
Related documentation¶
Sources¶
- src/NDReimbursementWebApp/Pages/NDReimbursement.cshtml.cs
- src/NDReimbursementWebApp/wwwroot/js/PaymentModal.js
- src/NDReimbursementWebApp/Services/OneIncService.cs