Skip to content

[Due for payment 2025-04-16] [$250] Fix error message when accepting Travel terms #57114

Description

@rlinoz

Context:
When calling AcceptSpotnanaTerms in NewDot we rely on the backend getting the active policyID from the user instead of passing it, even though the command accepts a policyID.

Problem:
When the user doesn't have a group policy selected as their default we throw an error and show a not so helpful error message.

https://expensify.slack.com/archives/C05S5EV2JTX/p1739889849699789

Solution:

Update the frontend to

  1. Check if the active policyID is a group policy, if it is then continue no changes needed
  2. If it is not and the user is a member of a single group policy, send that policyID to AcceptSpotnanaTerms
  3. If it is not and the user is a member of multiple group policies show an error message asking them to select a default group policy

You need to set a default workspace to enable Expensify Travel. Go to Settings > Workspaces > click the three vertical dots next to a workspace > Set as default workspace, then try again!

Debes establecer un espacio de trabajo predeterminado para habilitar Expensify Travel. Ve a Configuración > Espacios de trabajo > haz clic en los tres puntos verticales junto a un espacio de trabajo > Establecer como espacio de trabajo predeterminado y luego inténtalo de nuevo.

  1. If the user is not a member of a group policy show the upgrade modal, already working no changes needed.
Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021892240013233729852
  • Upwork Job ID: 1892240013233729852
  • Last Price Increase: 2025-02-19
  • Automatic offers:
    • twilight2294 | Contributor | 106254071
Issue OwnerCurrent Issue Owner: @RachCHopkins

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions