Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

[32464] Remove overridden show-all query

Oliver Günther3ab8e79e5df8
diff --git a/frontend/src/app/components/wp-query-select/wp-static-queries.service.ts b/frontend/src/app/components/wp-query-select/wp-static-queries.service.ts
index eb6d61eda08..8209381699a 100644
--- a/frontend/src/app/components/wp-query-select/wp-static-queries.service.ts
+++ b/frontend/src/app/components/wp-query-select/wp-static-queries.service.ts
@@ -41,8 +41,7 @@ export class WorkPackageStaticQueriesService {
private readonly $state:StateService,
private readonly CurrentProject:CurrentProjectService,
private readonly PathHelper:PathHelperService,
- private readonly CurrentUserService:CurrentUserService,
- private readonly BcfDetectorService:BcfDetectorService) {
+ private readonly CurrentUserService:CurrentUserService) {
}
public text = {
@@ -54,7 +53,7 @@ export class WorkPackageStaticQueriesService {
work_packages: this.I18n.t('js.label_work_package_plural'),
gantt: this.I18n.t('js.timelines.gantt_chart'),
latest_activity: this.I18n.t('js.work_packages.default_queries.latest_activity'),
- created_by_me:this.I18n.t('js.work_packages.default_queries.created_by_me'),
+ created_by_me: this.I18n.t('js.work_packages.default_queries.created_by_me'),
assigned_to_me: this.I18n.t('js.work_packages.default_queries.assigned_to_me'),
recently_created: this.I18n.t('js.work_packages.default_queries.recently_created'),
all_open: this.I18n.t('js.work_packages.default_queries.all_open'),
@@ -66,38 +65,28 @@ export class WorkPackageStaticQueriesService {
// All queries are sorted by their update or creation time (so the latest is always the first)
public get all():IAutocompleteItem[] {
let items = [
+ {
+ identifier: 'all_open',
+ label: this.text.all_open,
+ query_props: null
+ },
{
identifier: 'latest_activity',
label: this.text.latest_activity,
query_props: '{"c":["id","subject","type","status","assignee","updatedAt"],"hi":false,"g":"","t":"updatedAt:desc","f":[{"n":"status","o":"o","v":[]}]}'
},
{
- identifier: 'gantt',
- label: this.text.gantt,
- query_props: '{"c":["id","subject","startDate","dueDate"],"tv":true,"tzl":"years","hi":true,"g":"","t":"id:asc","t":"startDate:asc","f":[{"n":"status","o":"o","v":[]}]}'
- },
- {
- identifier: 'recently_created',
- label: this.text.recently_created,
- query_props: '{"c":["id","subject","type","status","assignee","createdAt"],"hi":false,"g":"","t":"createdAt:desc","f":[{"n":"status","o":"o","v":[]}]}'
- }
+ identifier: 'gantt',
+ label: this.text.gantt,
+ query_props: '{"c":["id","subject","startDate","dueDate"],"tv":true,"tzl":"years","hi":true,"g":"","t":"id:asc","t":"startDate:asc","f":[{"n":"status","o":"o","v":[]}]}'
+ },
+ {
+ identifier: 'recently_created',
+ label: this.text.recently_created,
+ query_props: '{"c":["id","subject","type","status","assignee","createdAt"],"hi":false,"g":"","t":"createdAt:desc","f":[{"n":"status","o":"o","v":[]}]}'
+ }
] as IAutocompleteItem[];
- // Modify default "all open" query for BCF
- if (this.BcfDetectorService.isBcfActivated) {
- items.push({
- identifier: 'all_open',
- label: this.text.all_open,
- query_props: '{"hi":true,"hl":"priority","f":[{"n":"status","o":"o","v":[]}],"dr":"card"}'
- });
- } else {
- items.push({
- identifier: 'all_open',
- label: this.text.all_open,
- query_props: null
- });
- }
-
const projectIdentifier = this.CurrentProject.identifier;
if (projectIdentifier) {
items.push({
@@ -126,7 +115,7 @@ export class WorkPackageStaticQueriesService {
}
public getStaticName(query:QueryResource) {
- if(this.$state.params.query_props) {
+ if (this.$state.params.query_props) {
let queryProps = JSON.parse(this.$state.params.query_props);
delete queryProps.pp;
delete queryProps.pa;