Skip to content

[CRITICAL] [VIP-Travel] [HOLD for payment 2024-05-16] Add Terms and Conditions Modal (NewDot) #37102

@stitesExpensify

Description

@stitesExpensify

VIP-Travel Implementation Issue

Tracking Issue: https://github.com/Expensify/Expensify/issues/333471
Project: [#whatsnext] #Travel (view)
Relevant Design Doc Section:

Feature Description

  1. Create a new Right Hand Modal (screen) for our travel Terms and Conditions
  2. Create a new action for AcceptTravelTerms
2024-02-22_12-58-51 2024-02-22_12-59-00
Detailed Instructions A new page, TravelTerms.ts will be created in src/pages/Travel: If the user is not on the travel beta, we’ll display a [blocking View ](https://github.com/Expensify/App/blob/main/src/components/BlockingViews/FullPageNotFoundView.tsx)instead It will include a [HeaderWithBackButton](https://github.com/Expensify/App/blob/main/src/components/HeaderWithBackButton/index.tsx) component with “Before we continue…” as the title. It will include the text displayed above (hyperlinks TBD) and a [checkboxWithLabel](https://github.com/Expensify/App/blob/main/src/components/CheckboxWithLabel.tsx) component for the user to agree with the terms. Lastly, it will include a (disabled until the checkbox is checked) as shown above: On click, it will call a new command, [AcceptTravelTerms](https://docs.google.com/document/d/122DLLTuCsU4NC3c7rNiy4UF8bZxVlLEWSy3yncqCTcQ/edit?pli=1#bookmark=id.1b1k3v847xja), to update NVP.travelSettings.hasAcceptedTerms or provision the workspace, and redirect the user to travel.expensify.com. If network.isOffline is true, it will be disabled, and the usual “You appear to be offline” message will display below.

Manual Test Steps

  1. Log in on a new account
  2. Create a workspace
  3. Go to travel
  4. Click the book travel button
  5. Make sure the T&C appears
  6. Make sure that if you don't check the box you cannot accept t&c
  7. Accept the T&C
  8. Look at the network request and ensure that we returned new policy and user data for the newly provisioned accounts

Automated Tests

Test for AcceptTravelTerms action

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~013a02f3de0cecfaf7
  • Upwork Job ID: 1760758341962240000
  • Last Price Increase: 2024-02-22

Routes table:
https://docs.google.com/document/d/122DLLTuCsU4NC3c7rNiy4UF8bZxVlLEWSy3yncqCTcQ/edit#bookmark=id.gn6jbl2udlnx

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionEngineeringInternalRequires API changes or must be handled by Expensify staffNewFeatureSomething to build that is a new item.ReviewingHas a PR in reviewWeeklyKSv2

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions