Skip to content

[HOLD for payment 2024-07-10] [$250] [Wave Collect] Disable all but the default distance rate when feature is disabled same for categories and tags #39463

Closed

Description

@mountiny

Problem

When the Distance Rates feature is disabled in NewDot, the distance rates remain enabled. Similarly to other features in the App, we should disable the rates when the feature is disabled.

However, this is also not yet implemented optimistically for tags and categories. This is an edge case that helps in cases of rare offline usage, and as such, it was not noted as regression.

When we disable the categories and tags feature in the backend, we also disable any enabled categories and tags. We need to do the same optimistically in the client (failure data should revert the state to the one before toggling the feature off).

Solution

When the distance rates feature is turned off in NewDot, go through all the distance rates on the policy and disable them except the Default Rate if available. If it's not available, keep the first rate that you go over as enabled and disable all the rest. We need to keep one enabled.

For tags and categories, make sure to turn off the requiresCategory and requiresTag optimistically and then all the tags, even multi-level.

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~010ba691024d0e69b3
  • Upwork Job ID: 1775299514448031744
  • Last Price Increase: 2024-06-07
  • Automatic offers:
    • getusha | Reviewer | 102703385
    • dominictb | Contributor | 102703388
Issue OwnerCurrent Issue Owner: @
Issue OwnerCurrent Issue Owner: @kadiealexander

Activity

  1. added
    InternalRequires API changes or must be handled by Expensify staff
    NewFeatureSomething to build that is a new item.
    on Apr 2, 2024
  2. self-assigned this
    on Apr 2, 2024
  3. melvin-bot commented on Apr 2, 2024

    @melvin-bot
  4. melvin-bot commented on Apr 2, 2024

    @melvin-bot

    Triggered auto assignment to Contributor Plus for review of internal employee PR - @getusha (Internal)

  5. melvin-bot commented on Apr 2, 2024

    @melvin-bot
  6. mountiny commented on Apr 4, 2024

    @mountiny
    ContributorAuthor

    Will try to look into this tomorrow

  7. trjExpensify commented on Apr 5, 2024

    @trjExpensify
    Contributor

    Similarly to other features in the App, we should disable the rates when the feature is disabled (we disable all categories, tags and taxes when the feature is disabled)

    Apart from the default or whatever that is, right?

  8. changed the title [-][Wave Collect] [Distance] Disable all but the default distance rate when feature is disabled[/-] [+][Wave Collect] [Distance rates] Disable all but the default distance rate when feature is disabled[/+] on Apr 5, 2024
  9. 85 remaining items

  10. kadiealexander commented on Jul 14, 2024

    @kadiealexander
    Contributor

    @getusha @mountiny do we need a regession test here?

  11. kadiealexander commented on Jul 15, 2024

    @kadiealexander
    Contributor

    The contracts expired so I've resent them here. Payouts due:

    Upwork job is here.

  12. dominictb commented on Jul 15, 2024

    @dominictb
    Contributor

    TL;DR: effective today, Thursday, April 4th, 2024 the initial job price for bugs/feature requests will start at $250.

    @kadiealexander Hi, this issue was created on Apr 3, so according to the official post here, this one's initial price should remain at $500

  13. kadiealexander commented on Jul 16, 2024

    @kadiealexander
    Contributor

    Thanks @dominictb, I've updated the offers.

  14. dominictb commented on Jul 16, 2024

    @dominictb
    Contributor

    @kadiealexander I accepted it, thank you

  15. kadiealexander commented on Jul 17, 2024

    @kadiealexander
    Contributor

    @getusha please share the regression test steps.

  16. getusha commented on Jul 17, 2024

    @getusha
    Contributor

    [@getusha] Please propose regression test steps to ensure the new feature will work correctly on production in further releases.

    Regression Test Proposal

    1. Go offline
    2. Go to workspaces > Select a workspace
    3. Go to categories
    4. Make sure to have one category enabled
    5. Go to more features
    6. Disable & Enable Categories feature
    7. Go to categories
    8. Verify that every category is disabled
    9. Go to distance rates
    10. Make sure to have at least two rates enabled
    11. Go to more features page
    12. Disable & Enable distance rates feature
    13. Go to Distance rates page
    14. Verify that only one distance rate remains enabled
    15. Go to Tags page
    16. Make sure to have at least one tag enabled
    17. Go to more features page
    18. Disable & Enable Tags feature
    19. Go to Tags page
    20. Verify that every options are disabled

    Do we agree 👍 or 👎
    cc @mountiny @dominictb

  17. getusha commented on Jul 18, 2024

    @getusha
    Contributor

    Accepted the offer @kadiealexander

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionDailyKSv2ExternalAdded to denote the issue can be worked on by a contributorNewFeatureSomething to build that is a new item.

Type

No type

Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions