Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
e9d7d8aa
Commit
e9d7d8aa
authored
Mar 04, 2020
by
Adam Hegyi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove release filter from Issues Analytics
parent
9fe7b97d
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
47 additions
and
1 deletion
+47
-1
ee/app/assets/javascripts/issues_analytics/filtered_search_issues_analytics.js
...ipts/issues_analytics/filtered_search_issues_analytics.js
+10
-1
ee/changelogs/unreleased/208903-remove-release-filter-from-issues-analytics.yml
...ed/208903-remove-release-filter-from-issues-analytics.yml
+5
-0
ee/spec/frontend/issues_analytics/filtered_search_issues_analytics_spec.js
...issues_analytics/filtered_search_issues_analytics_spec.js
+32
-0
No files found.
ee/app/assets/javascripts/issues_analytics/filtered_search_issues_analytics.js
View file @
e9d7d8aa
import
IssuableFilteredSearchTokenKeys
from
'
ee_else_ce/filtered_search/issuable_filtered_search_token_keys
'
;
import
IssuableFilteredSearchTokenKeys
from
'
ee_else_ce/filtered_search/issuable_filtered_search_token_keys
'
;
import
FilteredSearchTokenKeys
from
'
~/filtered_search/filtered_search_token_keys
'
;
import
FilteredSearchManager
from
'
~/filtered_search/filtered_search_manager
'
;
import
FilteredSearchManager
from
'
~/filtered_search/filtered_search_manager
'
;
import
{
historyPushState
}
from
'
~/lib/utils/common_utils
'
;
import
{
historyPushState
}
from
'
~/lib/utils/common_utils
'
;
import
issueAnalyticsStore
from
'
./stores
'
;
import
issueAnalyticsStore
from
'
./stores
'
;
const
EXCLUDED_TOKENS
=
[
'
release
'
];
export
default
class
FilteredSearchIssueAnalytics
extends
FilteredSearchManager
{
export
default
class
FilteredSearchIssueAnalytics
extends
FilteredSearchManager
{
constructor
()
{
constructor
()
{
const
issuesAnalyticsTokenKeys
=
new
FilteredSearchTokenKeys
(
IssuableFilteredSearchTokenKeys
.
tokenKeys
.
filter
(({
key
})
=>
!
EXCLUDED_TOKENS
.
includes
(
key
)),
// release filter is not working with the Issues API at the moment
IssuableFilteredSearchTokenKeys
.
alternativeTokenKeys
,
IssuableFilteredSearchTokenKeys
.
conditions
,
);
super
({
super
({
page
:
'
issues_analytics
'
,
page
:
'
issues_analytics
'
,
isGroupDecendent
:
true
,
isGroupDecendent
:
true
,
stateFiltersSelector
:
'
.issues-state-filters
'
,
stateFiltersSelector
:
'
.issues-state-filters
'
,
isGroup
:
true
,
isGroup
:
true
,
filteredSearchTokenKeys
:
IssuableFilteredSearch
TokenKeys
,
filteredSearchTokenKeys
:
issuesAnalytics
TokenKeys
,
});
});
this
.
isHandledAsync
=
true
;
this
.
isHandledAsync
=
true
;
...
...
ee/changelogs/unreleased/208903-remove-release-filter-from-issues-analytics.yml
0 → 100644
View file @
e9d7d8aa
---
title
:
Remove release tag filter from Issues Analytics
merge_request
:
208903
author
:
type
:
changed
ee/spec/frontend/issues_analytics/filtered_search_issues_analytics_spec.js
0 → 100644
View file @
e9d7d8aa
import
FilteredSearchIssueAnalytics
from
'
ee/issues_analytics/filtered_search_issues_analytics
'
;
describe
(
'
FilteredSearchIssueAnalytics
'
,
()
=>
{
describe
(
'
Token keys
'
,
()
=>
{
const
fixture
=
`<div class="filtered-search-box-input-container"><input class="filtered-search" /></div>`
;
let
component
=
null
;
let
availableTokenKeys
=
null
;
beforeEach
(()
=>
{
setFixtures
(
fixture
);
component
=
new
FilteredSearchIssueAnalytics
();
availableTokenKeys
=
component
.
filteredSearchTokenKeys
.
tokenKeys
.
map
(({
key
})
=>
key
);
});
afterEach
(()
=>
{
component
=
null
;
});
it
.
each
`
token | available
${
'
author
'
}
|
${
true
}
${
'
assignee
'
}
|
${
true
}
${
'
milestone
'
}
|
${
true
}
${
'
label
'
}
|
${
true
}
${
'
epic
'
}
|
${
true
}
${
'
weight
'
}
|
${
true
}
${
'
release
'
}
|
${
false
}
`
(
'
includes $token filter $available
'
,
({
token
,
available
})
=>
{
expect
(
availableTokenKeys
.
includes
(
token
)).
toBe
(
available
);
});
});
});
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment