FIX: Fix ESLint issues and use d-icon instead of <i> tags

This commit is contained in:
Rishabh Nambiar 2018-08-30 21:08:12 +05:30
parent d5d933c2a8
commit 5a75b6c1e1
2 changed files with 8 additions and 7 deletions

View File

@ -120,11 +120,12 @@ export default Ember.Controller.extend({
},
sortByProperty(property) {
if (this.sortBy == `${property}:desc`){
this.set('sortBy', [`${property}:asc`]);}
else {
if (this.sortBy[0] === `${property}:desc`) {
this.set('sortBy', [`${property}:asc`]);
} else {
this.set('sortBy', [`${property}:desc`]);
}},
}
},
create() {
const name = this.get("newQueryName").trim();

View File

@ -148,15 +148,15 @@
<table class="recent-queries">
<thead class="heading-container">
<th {{action "sortByProperty" "name"}} class="col heading name">
<i class="fa fa-sort"></i>
{{d-icon "sort"}}
{{i18n 'explorer.query_name'}}
</th>
<th {{action "sortByProperty" "username"}} class="col heading user">
<i class="fa fa-sort"></i>
{{d-icon "sort"}}
{{i18n 'explorer.query_user'}}
</th>
<th {{action "sortByProperty" "last_run_at"}} class="col heading time">
<i class="fa fa-sort"></i>
{{d-icon "sort"}}
{{i18n 'explorer.query_time'}}
</th>
</thead>