---
id: OV-C2-POS-003
title: "Fully Online: draft mirrored to server and local, flushed on completion"
product: mobile
module: offline-visitation
type: functional
priority: P1
risk: high
status: draft
automationStatus: planned
sourceRefs:
  tsd: PK144
  tsdSection: C2
  tsdScenario: C2.3
  prd: PK144
  jira: null
automationRef: null
lifecycleStatus: active
lifecycleReason: "AI-generated draft from PK144 TSD C2.3 (mirror + flush); pending QA review."
lastReviewedAt: null
reviewedBy: null
supersededBy: null
duplicateOf: null
blockedBy: null
preconditionRefs:
  - PRE-OV-logged-in-online
tags:
  - mobile
  - offline-visitation
  - visitation
  - pk144
  - staging
---
## Objective
Verify online draft saving mirrors to backend and local, and local copies flush on successful completion.

## Preconditions
- See [[PRE-OV-logged-in-online]]
- And the employee is in an active online visitation

## Steps
1. When the employee taps "Simpan" to save a draft
2. When the visit successfully completes via Kirim → Ringkasan → Check Out

## Expected Result
- Then the draft is sent to backend with status Draf
- And a local copy of the draft is written to the device (mirror)
- And on successful completion all local draft copies are automatically flushed from the device

## Source Traceability
- TSD: PK144
- Section: C2 - Visitation Flow
- Scenario: C2.3 - Fully Online: Draft mirror (server + local)
- Acceptance Criteria: M.13 AC3

## Evidence Required
- Backend draft status + local storage inspection before and after completion.

## Notes / Gaps
- Testing Concern #13 (Critical): server-local draft conflict resolution is unresolved.
- Persist-on-abandon counterpart is OV-C2-POS-004.
