Feature #7360
closedIssue custom query: default query per instance, project and user
Added by Mike Kokhanov almost 14 years ago. Updated 7 months ago.
0%
Description
It would be nice to be able to create a default custom query, so when I get to issue list of a project, I don't need to select my preferable custom query from the list.
Files
Related issues
Updated by Robin McKenzie over 13 years ago
+1 definitely, been wanting this for ages! Ideally each user would be able to determine their own custom query for each project, rather than it being a project-level setting.
Updated by Vincent Frédérick over 13 years ago
+1 Indeed would be nice for a user to set is default query for a given project. So a user could create a query to see only his tickets or the ticket related to a version he is currently working on. In fact he can already do all of this. Only thing missing is to automatically have that list query displayed when he clicks on "Issues".
Updated by Adam Soltys almost 13 years ago
+1
And, if the query is a public query, then you should have the option of specifying whether it's the default for everyone or just your own personal default.
Updated by Keven Marin over 12 years ago
+1 for that feature that we should not forget.
Updated by Rafael B. over 11 years ago
+1
Reducing just one click seems like such a waste of coding time, but clicking a couple of hundred times every week twice as much is such a waste of effort. This would be a huge usability improvement.
Updated by kangbo kimk over 11 years ago
+1 Very much important. One must click his favorite issus pages when new html page open. It takes a lot of time from many users by redoing that.
Updated by Matthieu Poncin over 11 years ago
+1 And if the query is public, it would be usefull to have an option to put the query default for every users.
Updated by Daniel Felix almost 11 years ago
Yes this could be quite useful. I have some projects which needs a special filter or a special column display (due to some custom fields) to get displayed correct. If there would be a default view, for each user in each project or a default project with the new role wide filters, this would be great.
Updated by Tim Craig over 10 years ago
+1 Important everyone views important information on issues list without having to select custom query every time.
Updated by Enmos Proje over 10 years ago
+1
Each time we open the tasks list, every one of us has to rearrange the list before starting to use it. We have custom queries but you forget to select them. This feature would save a huge amount of time and bad language :)
Updated by Florian Kaiser over 10 years ago
+1
That would save me a lot of time.
Updated by Katsuya HIDAKA over 10 years ago
+1
I also hope strongly that this feature is implemented. So, i made the redmine_default_custom_query plugin as an alternative.
Updated by Florian Kaiser over 10 years ago
Hidaka Katsuya wrote:
+1
I also hope strongly that this feature is implemented. So, I made the redmine_default_custom_query plugin as an alternative.
Maybe you can send a patch file to the redmine developers so they can add it easily.
Updated by Katsuya HIDAKA about 10 years ago
Florian Kaiser wrote:
Maybe you can send a patch file to the redmine developers so they can add it easily.
Yes, i'll try.
Updated by Go MAEDA over 9 years ago
- Has duplicate Feature #12689: Default query for every Project added
Updated by Go MAEDA over 9 years ago
- Has duplicate Feature #7244: Default query per project added
Updated by Go MAEDA over 9 years ago
- Related to Feature #5515: user select default issue query added
Updated by Toshi MARUYAMA over 9 years ago
- Related to Feature #4015: Make app settings overridable at project level added
Updated by Sebastian Paluch almost 9 years ago
+1
This would really make everything more readable and would make life easier for our everyday users.
Updated by Go MAEDA over 8 years ago
- Related to Feature #22156: Is there a way to set the filter status to be “Any” by default? added
Updated by Takenori TAKAKI over 8 years ago
I made a patch. It integrates Katsuya Hidaka's plugin (redmine_default_custom_query) to Redmine.
I do appreciate Katsuya Hidaka's work. and I would be happy if I could see the feature in Redmine 3.3.0.
this patch is compatibled with latest trunk r15273. and It also includes the test code.
Updated by Takenori TAKAKI over 8 years ago
I have arranged my patch ( default_custom_query_trunk_r15273.patch ) for berow:
- add 'default_query_id' to "Project(projects) "
- change position of the 'default-query drop-down', to 'Information Tab'
- remove permission & module "Manage default query"
- improve code a little bit, and add tests
- Compatible with latest trunk (r15303)
Updated by Go MAEDA over 8 years ago
- Target version set to 3.3.0
default_custom_query_trunk_r15303.patch works fine and passed all test.
This is a great feature. Many users hope for this feature (this issue have got 24 "+1"s and the original plugin redmine_default_custom_query written by Katsuya HIDAKA have got 25 stars on GitHub).
It would be great if we could see this feature in the next release. Now I am setting target version to 3.3.0.
Updated by Go MAEDA over 8 years ago
- File default-query-settings.png default-query-settings.png added
- File default-query-list.png default-query-list.png added
Screenshots of the patch, contributed by Katsuya HIDAKA and Takenori TAKAKI.
Updated by Katsuya HIDAKA over 8 years ago
+1 I'm creator of Default Custom Query plugin. I think that this patch (based on Default Custom Query plugin and written by Takenori Takaki) is one of the best way for providing customization of default issues for each project. I hope that this feature is merged!!
Updated by Jean-Philippe Lang over 8 years ago
- Target version changed from 3.3.0 to 3.4.0
As requested above, we should provide different level of default query: per project (as implemented in the patch) but also by user. We should also be able to provide default queries for the global issue list.
Updated by Go MAEDA over 8 years ago
- Has duplicate Feature #16102: Default Filters for queries in a project added
Updated by Go MAEDA about 8 years ago
- Related to Defect #13508: About default filter for assignee added
Updated by Go MAEDA almost 8 years ago
- Has duplicate Feature #2829: Ability to set default search filter for Issues added
Updated by Go MAEDA almost 8 years ago
- Has duplicate Feature #7993: Select Default Report (or Custom Report quick links) added
Updated by Go MAEDA almost 8 years ago
- Has duplicate Feature #9279: How to Apply custom queries for issues as default view for this project added
Updated by Go MAEDA almost 8 years ago
- Related to Feature #7659: Add the possibility to sort issues by last_update date, by default added
Updated by Toshi MARUYAMA over 7 years ago
- Related to Feature #3967: Ability to define default columns to display based on project added
Updated by Mischa The Evil over 7 years ago
- Target version set to Unplanned backlogs
Let's try to keep this on the roadmap; setting target to unplanned.
Updated by Go MAEDA about 7 years ago
- Related to Defect #14753: Remember issue filter for each project added
Updated by Go MAEDA about 7 years ago
- Related to Feature #27128: Ability to choose default sort by column for all projects added
Updated by Toshi MARUYAMA almost 7 years ago
- Related to deleted (Feature #22156: Is there a way to set the filter status to be “Any” by default?)
Updated by Toshi MARUYAMA almost 7 years ago
- Has duplicate Feature #22156: Is there a way to set the filter status to be “Any” by default? added
Updated by Mizuki ISHIKAWA over 6 years ago
+1
The patch of #7360#note-36 which was not working according to version upgrade was fixed to work on trunk.
I would like the continuation of work to realize this feature.
Updated by Go MAEDA over 6 years ago
- Has duplicate Feature #16249: Configure columns per project added
Updated by Marcel Müller almost 6 years ago
+1 !
Is there any reason this feature / patch got rejected? Would be really useful to have something like this... Maybe 4.1.0?!
Updated by LEXO IT Services Switzerland over 5 years ago
+1!
I hope that this feature will be release soon too. It's very annoying. It should be possible to define a global default filter and then save a dedicated filter per project.
Updated by Michael Barry over 5 years ago
I would like to throw my +1 into the ring! This functionality would be super beneficial to have native to Redmine. Crossing my fingers for 4.1.0 (or sooner!)...
Updated by Ryoji Takeuchi about 5 years ago
+1
Is this patch workable on 4.0.4 ? Because "redmine_default_custom_query" is conflict with DMSF. So I am seeking another solution with same function.
Updated by Marcel Müller over 4 years ago
I really would like to see this integrated in redmine by default. It was more or less accepted in https://www.redmine.org/issues/7360#note-40 - any idea why its now on unplanned backlog?
Updated by Go MAEDA over 4 years ago
Marcel Müller wrote:
I really would like to see this integrated in redmine by default. It was more or less accepted in https://www.redmine.org/issues/7360#note-40 - any idea why its now on unplanned backlog?
The current patch was rejected by Jean-Philippe Lang in #7360#note-40 because of the lack of per-user default query and a default query for the cross-project issues list.
To push this issue forward, someone needs to implement at least those features.
Updated by Olivier Chabert over 4 years ago
Hi,
You can find an updated version of patch for this feature.
This patch work with last commit r19977 on trunk branch.
this patch provide also different level of default query (as requested on #7360#note-40): * per project (as implemented in the original patch) * per user * and in the global redmine settings for the global issue list
thank you for your reviews on this patch ;)
Updated by Olivier Chabert about 4 years ago
Hello,
Does anyone have time to review my patch ?
thanks ;)
Updated by Ribald Drobens about 4 years ago
+1, absolutely! Seeing all issues ordered by issue # per default is definitively suboptimal behaviour in my eyes.
Updated by Jan Vonde over 3 years ago
Oliver Cordero Chabert: Thanks for your effort. Can you confirm that the patch works with Redmine 4.1.2?
Michael Glyebov Kokhanov: Please can you review this patch, comment, or forward this to someone else for reviewing?
Updated by Jens Krämer over 3 years ago
- File 0001-implements-global-per-project-and-per-user-default-i.patch 0001-implements-global-per-project-and-per-user-default-i.patch added
We're planning to introduce this feature in Planio , so I took the liberty to look over Olivier's patch (thank you for that!) and, among other things, rebased it on current master.
Further, I added some tests and German translations, fixed any rubocop warnings, implemented copying of the default query assignment when copying a project including queries, and changed the naming of preferences / fields to be consistently default_issue_query
.
Updated by Jan Vonde over 3 years ago
Jens Priesen Krämer: Do you know anything I can do to get the patch into the main code?
Updated by Go MAEDA over 3 years ago
- Target version changed from Unplanned backlogs to 5.0.0
Setting the target version to 5.0.0.
Updated by Marius BĂLTEANU over 3 years ago
The patch looks good to me, nice work!
Only one thing, is not better to show the Default query field inside Issues list defaults section in admin? The settings are quite related:
Current proposal:
My proposal:
Updated by Go MAEDA over 3 years ago
- File 7360.patch 7360.patch added
Marius BALTEANU wrote:
Only one thing, is not better to show the Default query field inside Issues list defaults section in admin? The settings are quite related:
+1
The setting "Default query" is exactly "Issue list defaults"!
I have updated the patch as such and changed the date of the migration file to the current date.
Although an earlier version of the patch contributed by Katsuya HIDAKA and Takenori TAKAKI was rejected by JPL 5 years ago (#7360#note-40), I got approval from Jean-Philippe Lang to commit the latest patch the day before yesterday. I would like to commit the patch within the next few days.
Updated by Go MAEDA over 3 years ago
- Status changed from New to Closed
- Assignee set to Go MAEDA
- Resolution set to Fixed
Committed the patch. Thank you to all those who contributed to this great feature, and special thanks to Katsuya HIDAKA, the author of Redmine Default Custom Query.
Now you can set the default issue query per app/project/user. The project-level default query always overrides the app-level one, and the user-level one always overrides the project-level and app-level ones.
You can configure default queries in the following places:
- App-level: Administration > Issue tracking > Default Query
- Project-level: Settings (project) > Issue tracking > Default issue query
- User-level: My account > Default issue query
Updated by Go MAEDA over 3 years ago
- Has duplicate Feature #15566: Setup a default issue report for each project added
Updated by Go MAEDA over 3 years ago
- File fix-performance-when-rendering-sidebar.patch fix-performance-when-rendering-sidebar.patch added
- Status changed from Closed to Reopened
The current code executes as many SQL statements as the number of queries displayed in the sidebar. It may cause a performance issue when many custom queries are displayed in the sidebar.
The attached patch fixes the problem.
Before:
IssueQuery Load (0.1ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" = ? LIMIT ? [["type", "IssueQuery"], ["id", 4], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] Rendered issues/_sidebar.html.erb (Duration: 33.7ms | Allocations: 5906)
After:
IssueQuery Load (0.1ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" = ? LIMIT ? [["type", "IssueQuery"], ["id", 4], ["LIMIT", 1]] CACHE IssueQuery Load (0.0ms) SELECT "queries".* FROM "queries" WHERE "queries"."type" = ? AND "queries"."id" IS NULL LIMIT ? [["type", "IssueQuery"], ["LIMIT", 1]] Rendered issues/_sidebar.html.erb (Duration: 18.3ms | Allocations: 3276)
Updated by Go MAEDA over 3 years ago
- File fix-performance-when-rendering-sidebar-v2.patch fix-performance-when-rendering-sidebar-v2.patch added
Go MAEDA wrote:
The current code executes as many SQL statements as the number of queries displayed in the sidebar. It may cause a performance issue when many custom queries are displayed in the sidebar.
The attached patch fixes the problem.
Attaching a simpler and more efficient version of the patch.
Updated by Mischa The Evil over 3 years ago
Go MAEDA wrote:
Attaching a simpler and more efficient version of the patch.
FWIW, the following assignment:
default_query =
default_query_by_class[query.class] ||
default_query_by_class[query.class] = query.class.default(project: @project)
can (possibly) be shortened to:
default_query =
default_query_by_class[query.class] ||= query.class.default(project: @project)
Ref. on StackOverflow.
Updated by Go MAEDA over 3 years ago
- Status changed from Reopened to Closed
Committed patch #7360#note-88 with the change suggested by Mischa The Evil in #7360#note-89.
Updated by Mischa The Evil over 3 years ago
- Related to Feature #35795: Settings for global and user default custom ProjectQuery added
Updated by Marius BĂLTEANU about 3 years ago
Before committing #35795, I would like to change the local setting_default_issue_query
to setting_default_query
in order to not add a new key (setting_default_project_query
) to locales with the same translation ("Default query").
Go Maeda, do you see any problem?
Updated by Marius BĂLTEANU about 3 years ago
- Status changed from Closed to Reopened
Updated by Marius BĂLTEANU about 3 years ago
- Related to deleted (Feature #27128: Ability to choose default sort by column for all projects)
Updated by Marius BĂLTEANU about 3 years ago
- Has duplicate Feature #27128: Ability to choose default sort by column for all projects added
Updated by Go MAEDA about 3 years ago
- Assignee changed from Go MAEDA to Marius BĂLTEANU
Marius BALTEANU wrote:
Before committing #35795, I would like to change the local
setting_default_issue_query
tosetting_default_query
in order to not add a new key (setting_default_project_query
) to locales with the same translation ("Default query").Go Maeda, do you see any problem?
I think there isn't any problem. And all existing translations for the key don't include a word corresponding to 'issue', so it is safe to simply change the name of the key.
config/locales/bg.yml: setting_default_issue_query: Заявка по подразбиране config/locales/de.yml: setting_default_issue_query: Standardabfrage config/locales/fr.yml: setting_default_issue_query: Rapport par défaut config/locales/gl.yml: setting_default_issue_query: Consulta por defecto config/locales/ja.yml: setting_default_issue_query: デフォルトのクエリ config/locales/zh-TW.yml: setting_default_issue_query: 預設查詢
Updated by Marius BĂLTEANU about 3 years ago
- Status changed from Reopened to Closed
- Assignee changed from Marius BĂLTEANU to Go MAEDA
Go MAEDA wrote:
I think there isn't any problem. And all existing translations for the key don't include a word corresponding to 'issue', so it is safe to simply change the name of the key.
Thanks, change committed.
Updated by Marius BĂLTEANU about 3 years ago
- Subject changed from Issue Custom Query: Default Query to Issue custom query: default query per instance, project and user
Updated by Marius BĂLTEANU about 3 years ago
- Has duplicate Feature #36198: Set standard columns in the ticket listing options based on projects added
Updated by Marius BĂLTEANU almost 3 years ago
- Related to Defect #36389: Filter parameters of Query string do not work when default query is enabled added
Updated by Marius BĂLTEANU almost 3 years ago
- Status changed from Closed to Reopened
I'm reopening this in order to validate the fix for the issue reported in #36389.
Jens Krämer, can you take a look, please?
Updated by Go MAEDA almost 3 years ago
- Related to Patch #36503: Reduce extra queries in IssueQuery.default added
Updated by Marius BĂLTEANU over 2 years ago
- Status changed from Reopened to Closed
I've committed the fix.
Updated by Holger Just about 2 years ago
- Related to Defect #37603: Missing translation for label_default_queries.for_this_user added
Updated by Holger Just about 1 year ago
- Has duplicate Defect #39041: Default Tickets View added
Updated by Dmitry Nekrasov 10 months ago
Can get default query working only on user level and on global level (all issues of all projects).
Selecting on default query project level does not work, even if public query is selected.
Environment:
Redmine version 5.1.1.stable
Ruby version 2.7.4-p191 (2021-07-07) [x86_64-linux-gnu]
Rails version 6.1.7.6
Environment production
Database adapter Mysql2
Mailer queue ActiveJob::QueueAdapters::AsyncAdapter
Mailer delivery smtp
Redmine settings:
Redmine theme Zenmine-510 (includes JavaScript)
SCM:
Git 2.30.2
Filesystem
Redmine plugins:
additional_tags 3.0.9
additionals 3.0.8
computed_custom_field 1.0.7
mega_calendar 1.9.6
redmine_checklists 3.1.22
redmine_custom_workflows 2.0.8
redmine_image_clipboard_paste 3.3.0
redmine_impersonate 2.0.0
redmine_issue_dynamic_edit 0.8.1
redmine_issue_view_columns 1.0.1
redmine_issues_tree 0.0.15
redmine_mentions 0.0.1
redmine_messenger 1.0.15
redmine_wysiwyg_editor 0.32.0
redmine_x_lightbox2 1.0.0
Updated by Dmitry Nekrasov 7 months ago
- File Снимок экрана 2024-04-17 в 11.32.47.PNG Снимок экрана 2024-04-17 в 11.32.47.PNG added
- File Снимок экрана 2024-04-17 в 11.32.34.PNG Снимок экрана 2024-04-17 в 11.32.34.PNG added
Redmine 5.1.1.stable — setting default query on project level is still broken: you can select public query in project settings, but it is not applied by default on project ISSUES page.
Updated by Marius BĂLTEANU 7 months ago
Dmitry Nekrasov wrote in #note-107:
Redmine 5.1.1.stable — setting default query on project level is still broken: you can select public query in project settings, but it is not applied by default on project ISSUES page.
There are no known issues with the default query feature and we have also automated tests. Most probably, your problem is generated by one of your plugins. You should try without.
If the issue still persists without plugins, please open a new issue.