aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/apps/users/search-view.js
diff options
context:
space:
mode:
Diffstat (limited to 'server/sonar-web/src/main/js/apps/users/search-view.js')
-rw-r--r--server/sonar-web/src/main/js/apps/users/search-view.js16
1 files changed, 8 insertions, 8 deletions
diff --git a/server/sonar-web/src/main/js/apps/users/search-view.js b/server/sonar-web/src/main/js/apps/users/search-view.js
index abc63a611b9..c8c0df459ff 100644
--- a/server/sonar-web/src/main/js/apps/users/search-view.js
+++ b/server/sonar-web/src/main/js/apps/users/search-view.js
@@ -30,22 +30,22 @@ export default Marionette.ItemView.extend({
'keyup #users-search-query': 'debouncedOnKeyUp'
},
- initialize: function () {
+ initialize () {
this._bufferedValue = null;
this.debouncedOnKeyUp = _.debounce(this.onKeyUp, 400);
},
- onRender: function () {
+ onRender () {
this.delegateEvents();
},
- onFormSubmit: function (e) {
+ onFormSubmit (e) {
e.preventDefault();
this.debouncedOnKeyUp();
},
- onKeyUp: function () {
- var q = this.getQuery();
+ onKeyUp () {
+ const q = this.getQuery();
if (q === this._bufferedValue) {
return;
}
@@ -56,12 +56,12 @@ export default Marionette.ItemView.extend({
this.searchRequest = this.search(q);
},
- getQuery: function () {
+ getQuery () {
return this.$('#users-search-query').val();
},
- search: function (q) {
- return this.collection.fetch({ reset: true, data: { q: q } });
+ search (q) {
+ return this.collection.fetch({ reset: true, data: { q } });
}
});