Commit 26c3b7b1979beb6b36e76146367d1dc0c0eeec69
1 parent
a5475297
Exists in
master
and in
112 other branches
prevent clics on services without results
Showing
1 changed file
with
1 additions
and
2 deletions
Show diff stats
js/app/controllers/EpnTapModule.js
... | ... | @@ -166,9 +166,8 @@ Ext.define('amdaDesktop.EpnTapModule', { |
166 | 166 | this.granulesStore.selectedService = record.data.id; |
167 | 167 | Ext.Ajax.suspendEvent('requestexception'); |
168 | 168 | Ext.Ajax.abortAll(); |
169 | - var nbRes = record.get('nb_results'); | |
170 | 169 | |
171 | - if(nbRes > 0 && !isNaN(nbRes)) { // TODO replace !isNaN(nbRes) by this.selectedService.get('success') | |
170 | + if(record.get('nb_results') > 0) { | |
172 | 171 | this.granulesStore.load({ |
173 | 172 | params: {'action': 'getGranules'}, |
174 | 173 | callback: function (records, operation, success) { |
... | ... |