Skip to content

Add Duration Range Filter to Finished Games Search #1023

@MichaelDeitz

Description

@MichaelDeitz

The backend now supports filtering finished matches by minimum and maximum duration (in seconds).
The website UI should expose this filter so users can search for games within a specific duration range.

Backend Work (already completed)
New Query Parameters
The /api/matches endpoint now accepts:

  • minDuration — minimum match duration in seconds
  • maxDuration — maximum match duration in seconds

Model Field Used
The backend filters on:
Matchup.Duration (TimeSpan)
which maps to the stored durationInSeconds field in MongoDB

Here is where it is expected to be.

Image

Frontend Work Needed
Add two numeric inputs for:

  • Min Duration (seconds)
  • Max Duration (seconds)
    These should be placed in the Matches filter panel, in the same section as the MMR range filters (see screenshot).
    When values are entered, the frontend should append them to the API request:
    minDuration=
    maxDuration=

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions