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
0
Merge Requests
0
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
Léo-Paul Géneau
gitlab-ce
Commits
98cb6101
Commit
98cb6101
authored
Dec 12, 2016
by
Clement Ho
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor static data to get information from other variables instead
parent
e9886b57
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
app/assets/javascripts/filtered_search/dropdown_user.js.es6
app/assets/javascripts/filtered_search/dropdown_user.js.es6
+2
-2
app/assets/javascripts/filtered_search/filtered_search_dropdown.js.es6
...vascripts/filtered_search/filtered_search_dropdown.js.es6
+1
-1
No files found.
app/assets/javascripts/filtered_search/dropdown_user.js.es6
View file @
98cb6101
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
project_id: this.getProjectId(),
project_id: this.getProjectId(),
current_user: true,
current_user: true,
},
},
searchValueFunction: this.getSearchInput,
searchValueFunction: this.getSearchInput
.bind(this)
,
loadingTemplate: this.loadingTemplate,
loadingTemplate: this.loadingTemplate,
},
},
};
};
...
@@ -37,7 +37,7 @@
...
@@ -37,7 +37,7 @@
}
}
getSearchInput() {
getSearchInput() {
const query =
document.querySelector('.filtered-search')
.value;
const query =
this.input
.value;
const { value } = gl.FilteredSearchTokenizer.getLastTokenObject(query);
const { value } = gl.FilteredSearchTokenizer.getLastTokenObject(query);
const valueWithoutColon = value.slice(1);
const valueWithoutColon = value.slice(1);
const hasPrefix = valueWithoutColon[0] === '@';
const hasPrefix = valueWithoutColon[0] === '@';
...
...
app/assets/javascripts/filtered_search/filtered_search_dropdown.js.es6
View file @
98cb6101
...
@@ -5,7 +5,7 @@
...
@@ -5,7 +5,7 @@
class FilteredSearchDropdown {
class FilteredSearchDropdown {
constructor(droplab, dropdown, input) {
constructor(droplab, dropdown, input) {
this.droplab = droplab;
this.droplab = droplab;
this.hookId =
'filtered-search'
;
this.hookId =
input.getAttribute('data-id')
;
this.input = input;
this.input = input;
this.dropdown = dropdown;
this.dropdown = dropdown;
this.loadingTemplate = `<div class="filter-dropdown-loading">
this.loadingTemplate = `<div class="filter-dropdown-loading">
...
...
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