Skip to content

[Insights: Violations][R2] Offer never for the any-approval date filter #104235

Open

Description

@neil-marcellini

(Neil's AI agent)

Follow-up to #99930 and its PR #101058.

Problem

The any-approval date filter doesn't offer never, so there's no way to search for expenses that were never approved. App left it out because Auth used to turn never into a condition that couldn't match. https://github.com/Expensify/Auth/pull/25114 (in production since 2026-10-16) fixed that: on its own, never matches expenses whose report has no approve or forward action.

Solution

  • Remove the ANY_APPROVAL case from getDatePresets, so it falls through to the default presets, which include never. That covers both autocomplete and the date picker.
  • Update the getDatePresets test to expect never.
  • Add any-approval:never to the query round-trip tests.

Tests

  1. Type type:expense any-approval: in the search bar and verify never is suggested.
  2. Open the Any approval date picker in the advanced filters and verify Never is offered.
  3. Search type:expense any-approval:never and verify only expenses on reports with no approval are returned.
Issue OwnerCurrent Issue Owner: @nkdengineer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions