remove unneeded request
This commit is contained in:
Родитель
7bf99d4db5
Коммит
38f0ef937e
11
app.js
11
app.js
|
@ -13,7 +13,6 @@
|
|||
'getTickets.done': 'onGetTicketsDone',
|
||||
'getOrganizationTickets.done': 'onGetOrganizationTicketsDone',
|
||||
'getTicketAudits.done': 'getTicketAuditsDone',
|
||||
'getCurrentUserLocale.done': 'onGetCurrentUserLocaleDone',
|
||||
|
||||
// UI
|
||||
'click .expand-bar': 'onClickExpandBar',
|
||||
|
@ -28,10 +27,6 @@
|
|||
},
|
||||
|
||||
requests: {
|
||||
getCurrentUserLocale: {
|
||||
url: '/api/v2/users/me.json'
|
||||
},
|
||||
|
||||
getLocales: {
|
||||
url: '/api/v2/locales.json'
|
||||
},
|
||||
|
@ -262,7 +257,7 @@
|
|||
this.storage.selectedKeys = JSON.parse(this.setting('selectedFields') || defaultSelection);
|
||||
var defaultOrgSelection = '[]';
|
||||
this.storage.selectedOrgKeys = JSON.parse(this.setting('orgFields') || defaultOrgSelection);
|
||||
if (!this.locale) { this.countedAjax('getCurrentUserLocale'); }
|
||||
if (!this.locale) { this.locale = this.currentUser().locale(); }
|
||||
if (this.ticket().requester()) {
|
||||
this.requesterEmail = this.ticket().requester().email();
|
||||
this.countedAjax('getUser', this.ticket().requester().id());
|
||||
|
@ -371,10 +366,6 @@
|
|||
|
||||
// REQUESTS ================================================================
|
||||
|
||||
onGetCurrentUserLocaleDone: function(data) {
|
||||
this.locale = data.user.locale;
|
||||
},
|
||||
|
||||
onGetLocalesDone: function(data) {
|
||||
var locales = {};
|
||||
_.each(data.locales, function(obj) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче