fix: support manual accident addresses and expose final Fanavaran completion

Accept and persist address-only locations across user and expert flows, preserve workflow authorization, and include addresses in reports and Fanavaran review. Expose persisted final submission completion so the expert panel can prevent repeat sends.
This commit is contained in:
SepehrYahyaee
2026-11-21 09:45:13 +03:30
parent b63525c863
commit c6022a1646
15 changed files with 244 additions and 25 deletions
@@ -14,6 +14,14 @@ describe("buildInsurerFileReport", () => {
return field?.value;
};
it("shows an address-only accident location in the exported report", () => {
const address = "تهران، خیابان آزادی، مقابل دانشگاه";
const report = buildInsurerFileReport({
blame: { type: "CAR_BODY", parties: [{ role: "FIRST", location: { address } }] },
});
expect(getFieldValue(report, PR.accidentSection, PR.location)).toBe(address);
});
it("separates insurance blocks and exposes Fanavaran/timeline/evaluation data", () => {
const fileCreatedAt = new Date("2026-08-10T09:53:23.588Z");
const evaluationSubmittedAt = new Date("2026-08-10T12:30:45.000Z");