Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance Table Column Filtering #887

Open
7 of 13 tasks
joshuadkitenge opened this issue Aug 15, 2024 · 0 comments
Open
7 of 13 tasks

Enhance Table Column Filtering #887

joshuadkitenge opened this issue Aug 15, 2024 · 0 comments
Assignees
Labels
enhancement Improved or refactored feature

Comments

@joshuadkitenge
Copy link
Collaborator

joshuadkitenge commented Aug 15, 2024

Overview

Currently, the table column filtering feature only uses fuzzy text search and some exact select menu search across the columns. To improve usability, we need to assess and update the filter modes and filter variants for each table column. This enhancement will be implemented gradually, one table per pull request (PR).

Objectives

  1. Assess and Implement Appropriate Filter Modes and Variants:

    • Evaluate each table column's data type and user needs to determine the most suitable filter mode and filter variant.
    • Provide clear reasoning for the selection of filter modes and variants for each column in the PR description.
  2. Priority Columns for Update:

    • System Column:
      • Users should be able to filter by multiple systems.
      • Users should be able to exclude specific systems (e.g., "System not equal to Storage").
    • Usage Status Column:
      • Users should be able to filter by multiple usage statuses.
      • Users should be able to exclude specific usage statuses (e.g., "Usage status not equal to Scrapped and Used").

Implementation Steps

  1. Column Assessment:

    • Review the current filter mode and filter variant for each column.
    • Determine the best fit for each column based on its data type and user requirements.
  2. Column Filtering Enhancements:

    • System Column:
      • Implement a filter that allows for multi-selection and exclusion.
      • Example: Users should be able to select multiple systems to include or exclude in their filter criteria.
    • Usage Status Column:
      • Implement a filter that allows for multi-selection and exclusion.
      • Example: Users should be able to select multiple usage statuses to include or exclude in their filter criteria.
  3. Pull Request Process:

    • Implement changes one table at a time.
    • In each PR, include a detailed explanation of why specific filter modes and variants were chosen for each column.
    • Ensure thorough testing to confirm the new filter modes and variants work as expected.

Components Requiring Table Column Filtering Enhancements

  • catalogueCategoryTableView.component.tsx
  • catalogueItemsTable.component.tsx
  • itemsTable.component.tsx
  • manufacturer.component.tsx (Table is within this component)
  • systemsTableView.component.tsx
  • systemItemsTable.component.tsx
  • units.component.tsx (Table is within this component)
  • usageStatuses.component.tsx (Table is within this component)

Tasks

Reference

@joshuadkitenge joshuadkitenge added the enhancement Improved or refactored feature label Aug 15, 2024
asuresh-code added a commit that referenced this issue Sep 5, 2024
asuresh-code added a commit that referenced this issue Sep 18, 2024
…l-facilities/inventory-management-system into enhance-usage-statuses-filtering-#887
asuresh-code added a commit that referenced this issue Sep 18, 2024
…l-facilities/inventory-management-system into enhance-usage-statuses-filtering-#887
asuresh-code added a commit that referenced this issue Oct 3, 2024
…l-facilities/inventory-management-system into enhance-usage-statuses-filtering-#887
asuresh-code added a commit that referenced this issue Oct 4, 2024
…l-facilities/inventory-management-system into enhance-usage-statuses-filtering-#887
asuresh-code added a commit that referenced this issue Oct 15, 2024
* add multi-select, and include/exclude to usage statuses. TODO: move code to utils, and fix undefined bug in UI

* move filter functions to util #887

* removed seconds from dates, to fix between inclusive filters

* fix linting and update snapshots

* Finished moving filtering code to utils file #887

* between and equals filter switches between date and datetime.#887

* implemented equalsDate filter function and toggling between dateTimeRange #979

* finished implementing all filtering functionality #979

* fix linting and failing unit tests #979

* abd

* frf

* fix failing unit tests and linting #979

* finished implemention unit tests, refactored implementation slightly #979

* fix linting #979

* refactored implementation to use basic MRT_Functionality, updated preservedTable to address url not updating for filterfunction changes #979

* fix url state issue, stops showing undefined filter mode and default state does not generate url #979

* added filterfn defintions to all date variants, and fixed linting #979

* add 2 extra filter functions to value column #979

* remove getColumnIds function, removed (as any) from localisation and, ordered usage status column attributes #979

* Update src/utils.test.tsx

add function name to test description

Co-authored-by: Joel Davies <[email protected]>

* Update src/utils.test.tsx

add function name to test description #979

Co-authored-by: Joel Davies <[email protected]>

* added unit tests for preservedTableState #979

* minor formatting changes for readability #979

* address review comments #979

* updated snapshot, and fixed dates #979

---------

Co-authored-by: Joel Davies <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improved or refactored feature
Projects
Status: In Progress
Development

No branches or pull requests

2 participants