Skip to content

fix: user officer users and experiment table filter - #1232

Merged
yoganandaness merged 30 commits into
developfrom
SWAP-4929-user-officer-experiment-table-filter
Jan 21, 2026
Merged

fix: user officer users and experiment table filter#1232
yoganandaness merged 30 commits into
developfrom
SWAP-4929-user-officer-experiment-table-filter

Conversation

@yoganandaness

@yoganandaness yoganandaness commented Oct 20, 2025

Copy link
Copy Markdown
Contributor

Description

Persisting the Experiment table filters and searches in the query params, so that refreshing the page retains the data rather than starting from scratch. In addition to that, additional fetching query have been avoided.

Motivation and Context

Improve usability of experiment table

How Has This Been Tested

Manually

Fixes

Changes

In Experiment Table, query params persisting have been implemented .

Depends on

Tests included/Docs Updated?

  • I have added tests to cover my changes.
  • All relevant doc has been updated

@yoganandaness
yoganandaness requested a review from a team as a code owner October 20, 2025 11:39
@yoganandaness
yoganandaness requested review from ACLay and removed request for a team October 20, 2025 11:39
@yoganandaness yoganandaness changed the title Swap 4929 user officer experiment table filter Swap 4929 user officer users and experiment table filter Oct 20, 2025
@yoganandaness yoganandaness changed the title Swap 4929 user officer users and experiment table filter improvement: user officer users and experiment table filter Oct 27, 2025
@yoganandaness yoganandaness changed the title improvement: user officer users and experiment table filter fix: user officer users and experiment table filter Oct 27, 2025
@yoganandaness
yoganandaness force-pushed the SWAP-4929-user-officer-experiment-table-filter branch from c5e6a2f to 0003da9 Compare October 28, 2025 17:46
@yoganandaness
yoganandaness force-pushed the SWAP-4929-user-officer-experiment-table-filter branch from 5e8415b to 8ea968b Compare October 29, 2025 10:29
@yoganandaness
yoganandaness enabled auto-merge (squash) October 31, 2025 13:15
@github-actions

github-actions Bot commented Nov 4, 2025

Copy link
Copy Markdown
Contributor

⚠️ Automatic rebase failed due to conflicts. Please rebase manually.

2 similar comments
@github-actions

github-actions Bot commented Nov 4, 2025

Copy link
Copy Markdown
Contributor

⚠️ Automatic rebase failed due to conflicts. Please rebase manually.

@github-actions

github-actions Bot commented Nov 4, 2025

Copy link
Copy Markdown
Contributor

⚠️ Automatic rebase failed due to conflicts. Please rebase manually.

@github-actions

github-actions Bot commented Nov 4, 2025

Copy link
Copy Markdown
Contributor

⚠️ Automatic rebase failed due to conflicts. Please rebase manually.

@github-actions

github-actions Bot commented Nov 4, 2025

Copy link
Copy Markdown
Contributor

⚠️ Automatic rebase failed due to conflicts. Please rebase manually.

@yoganandaness
yoganandaness removed the request for review from ACLay January 15, 2026 16:44
@yoganandaness

Copy link
Copy Markdown
Contributor Author

@janosbabik @TCMeldrum

Requesting you to re-review this, as there had been significant changes since the last review.

@yoganandaness

Copy link
Copy Markdown
Contributor Author

@TCMeldrum There has been continuous failure in the test case on the stfc side especially on the generalFAPS. I cannot replicate it in my local machine

Would it be possible to check it out and let me know the cause of the issue, if possible with the error stacktrace. Thanks

@TCMeldrum

Copy link
Copy Markdown
Contributor

It is beacause in stfcUserDataSource getUsers we are still filtering users on the filter string but you have change the filter to searchText so the search on the FapChair box isnt working.

@Field(() => PaginationSortDirection, { nullable: true })
public sortDirection?: PaginationSortDirection;

@Field({ nullable: true })

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we still need the filter string now we have searchText what is the difference

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Absolutely not. Should be removed.

@yoganandaness

Copy link
Copy Markdown
Contributor Author

It is beacause in stfcUserDataSource getUsers we are still filtering users on the filter string but you have change the filter to searchText so the search on the FapChair box isnt working.

You are right and thanks a lot for diagnosing it. It is my bad and i have missed to clean it up on stfc datasource. Thanks

…ub.com:UserOfficeProject/user-office-core into SWAP-4929-user-officer-experiment-table-filter
@yoganandaness

Copy link
Copy Markdown
Contributor Author

@TCMeldrum Now that the test cases are passing. Requesting you to re-review and approve.

userRole,
subtractUsers,
orderBy,
orderDirection = 'desc',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: Is that intended to remove the default value? I would suggest keeping it because if you only specify orderBy, the ordering will not take place, which is a bit unexpecged.

And if this has the default value below we don't need to check if it is set

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure, if i got your suggestion in a right way

But, the changes includes

  1. Renaming orderBy to sortField and orderDirection to sortDirection.
  2. sortField has been defaulted to created_at, which loads results based on creation date in the ascending order.
  3. When sortDirection is not provided, the default sort direction is Desc.

…re into SWAP-4929-user-officer-experiment-table-filter
@yoganandaness
yoganandaness enabled auto-merge (squash) January 21, 2026 12:31
@yoganandaness
yoganandaness merged commit 32e55d9 into develop Jan 21, 2026
22 checks passed
@yoganandaness
yoganandaness deleted the SWAP-4929-user-officer-experiment-table-filter branch January 21, 2026 14:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants