aboutsummaryrefslogtreecommitdiffstats
path: root/server/sonar-web/src/main/js/apps/quality-profiles/profiles-view.js
diff options
context:
space:
mode:
Diffstat (limited to 'server/sonar-web/src/main/js/apps/quality-profiles/profiles-view.js')
-rw-r--r--server/sonar-web/src/main/js/apps/quality-profiles/profiles-view.js22
1 files changed, 11 insertions, 11 deletions
diff --git a/server/sonar-web/src/main/js/apps/quality-profiles/profiles-view.js b/server/sonar-web/src/main/js/apps/quality-profiles/profiles-view.js
index 7ece0ed72c3..7ded221819f 100644
--- a/server/sonar-web/src/main/js/apps/quality-profiles/profiles-view.js
+++ b/server/sonar-web/src/main/js/apps/quality-profiles/profiles-view.js
@@ -35,27 +35,27 @@ export default Marionette.CompositeView.extend({
'filter': 'filterByLanguage'
},
- childViewOptions: function (model) {
+ childViewOptions (model) {
return {
collectionView: this,
highlighted: model.get('key') === this.highlighted
};
},
- highlight: function (key) {
+ highlight (key) {
this.highlighted = key;
this.render();
},
- attachHtml: function (compositeView, childView, index) {
- var $container = this.getChildViewContainer(compositeView),
- model = this.collection.at(index);
+ attachHtml (compositeView, childView, index) {
+ const $container = this.getChildViewContainer(compositeView);
+ const model = this.collection.at(index);
if (model != null) {
- var prev = this.collection.at(index - 1),
- putLanguage = prev == null;
+ const prev = this.collection.at(index - 1);
+ let putLanguage = prev == null;
if (prev != null) {
- var lang = model.get('language'),
- prevLang = prev.get('language');
+ const lang = model.get('language');
+ const prevLang = prev.get('language');
if (lang !== prevLang) {
putLanguage = true;
}
@@ -67,12 +67,12 @@ export default Marionette.CompositeView.extend({
compositeView._insertAfter(childView);
},
- destroyChildren: function () {
+ destroyChildren () {
Marionette.CompositeView.prototype.destroyChildren.apply(this, arguments);
this.$('.js-list-language').remove();
},
- filterByLanguage: function (language) {
+ filterByLanguage (language) {
if (language) {
this.$('[data-language]').addClass('hidden');
this.$('[data-language="' + language + '"]').removeClass('hidden');