Fix initial spinning issue for suppliers lists index

This commit is contained in:
2015-10-07 18:39:22 +02:00
parent ec323746fd
commit b163304b46
@@ -2,7 +2,7 @@ App.ListsIndexController = Ember.Controller.extend
loading: true loading: true
date: (new Date()).toISOString().substr(0,10) # 2015-11-02 date: (new Date()).toISOString().substr(0,10) # 2015-11-02
dateChanged: (-> dateChanged: (->
return unless date = @get('date') return @set('loading', false) unless date = @get('date')
@set 'loading', true @set 'loading', true
@store.query 'list', date: date @store.query 'list', date: date
.then => @set('loading', false) .then => @set('loading', false)