Review the “Track” / “Pending” status behavior in the X-ray referral section so records do not shift state after logout and login.

XMLWordPrintable

    • Type: Task
    • Resolution: Done
    • Priority: High
    • 2.0
    • Affects Version/s: None
    • None
    • STOP TB Sprint 5

      During field testing, several records in the StopTB App's X-ray referral section were displaying status "Track." Dev team confirmed this happens when the connection is lost — the record gets moved into the manual error section and rendered as "Track" in the UI.

      However, after the user logged out and logged back into the app, the same records reverted to "Pending" status, with no change to connectivity or underlying data in between. So the record's displayed state is flipping purely as a side effect of a session logout/login cycle, not because anything actually changed on the backend.

      Additionally, for a few records, the X-ray status and TrueNat status were shown as "Track" and "Pending" respectively for what should be the same referral case — i.e., the two integrated views are not in sync with each other. 

      Steps to reproduce:

      1. Create an X-ray referral in the StopTB App while the network connection is unstable/drops, so the record lands in the manual error section and shows as "Track."
      2. Without any network or backend change, log out of the app.
      3. Log back in.
      4. Observe that the same record now shows "Pending" instead of "Track."
      5. Separately, check a beneficiary with both X-ray and TrueNat referrals — note the two sections can show differing statuses ("Track" vs "Pending") for what is effectively the same case.

      Expected behavior: A referral's displayed status should reflect its actual state on the backend (synced, pending, or genuinely errored) and should remain stable across a logout/login — login/logout should not itself be a trigger for a state transition. Status should also be consistent across the X-ray and TrueNat views for the same beneficiary/case.

      Actual behavior: Status toggles between "Track" and "Pending" purely based on session logout/login, and can be inconsistent between X-ray and TrueNat sections for the same record.

        1. Image 1.png
          239 kB
          Shivani Garg
        2. Image 2.png
          343 kB
          Shivani Garg

              Assignee:
              Nidhi Saini
              Reporter:
              Rupesh Singh
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: