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

Filter project boards based on labels #21963

Closed

Conversation

techknowlogick
Copy link
Member

Partial implementation of #21846
Without filtering:
Without filtering
With filtering:
With filtering

Per the ticket, this is a naive approach where the filtering is done via client side. The proper approach would be to do it client side, and this can be done once the sorting of tickets issue is solved.

@techknowlogick techknowlogick added type/enhancement An improvement of existing functionality topic/projects labels Nov 28, 2022
@KlavsKlavsen
Copy link

Whats missing for this? We're going to test it out - as we need to "filter" on assignee - so we can use it for standup (as swimlanes are not there) - as a way to isolate to each person when they're doing standup - to show their issues only

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Jan 24, 2023
@techknowlogick
Copy link
Member Author

@KlavsKlavsen What's missing is an actual implementation. This "gets the job done", but in many cases makes page loads too slow to be usable as it needs to process the entire board in client side. The PR is marked as draft to make sure it doesn't accidentally get merged. Project board filtering by label was requested, and so I made this PR for two reasons 1. to have something that meets the definition of done, but more so 2. to really walk through the problem set and fully understand the issue and how best it could be solved.

The blocker is that if the filtering is done server side (which code exists already to be able to do that) is that once filtered the sorting javascript, posts the entire column and if an issue in the column is filtered out then when the post happens it'll remove the filtered issues from the kanban as a whole.

This is something that could be solved, and I've documented my entire process so far so that that next step be taken even without me.

@KlavsKlavsen
Copy link

KlavsKlavsen commented Jul 19, 2023

as I understand it - kanban board (project board) view - today shows ALL tasks.. no matter who they'are assigned to.
So WHY would it be heavy to simply "filter" on client side - based on f.ex. "assignee" ? is it the browser that spends too much CPU processing the "cards" on the board ?

yes - you COULD save backend time - by NOT getting all issues from backend (when you're going to filter anyways) - but this IS still an improvement over current code - and the performance problem of fetching "all issues when you have many" - will still be a problem - with or without this swimlanes in UI filtering.

So IMHO this should be merged (if it runs fast enough on clientside with parsing issues) - and a task for improving this, with allowing filtering on backend instead - should be added for improvement later.

But yes - the "right implementation" - would probably be to extend the API where the UI gets issues from - to support filtering.. and then simply extend UI to add that "filtering param" when you select swimlanes

which API endpoint is being called to get these cards? does not sound like a huge task to extend the backend to support filtering - if it doesn't already.
And then UI will have to build a select list of swimlane filters.. like you already do

@techknowlogick techknowlogick deleted the filter-project-boards branch September 12, 2024 02:38
techknowlogick pushed a commit that referenced this pull request Sep 12, 2024
Works in both organization and repository project boards

Fixes #21846

Replaces #21963
Replaces #27117
 

![image](https://github.com/user-attachments/assets/1837ace8-3de2-444f-a153-e166bd0da2c0)

**Note** that implementation was made intentionally to work same as in
issue list so that URL can be bookmarked for quick access with
predefined filters in URL
@go-gitea go-gitea locked as resolved and limited conversation to collaborators Dec 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. topic/projects type/enhancement An improvement of existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants