Fixed rss widget.

This commit is contained in:
Martin Edenhofer 2012-11-27 01:10:06 +01:00
parent 9818facbf6
commit 5687bd9b4b

View file

@ -15,6 +15,7 @@ class App.DashboardRss extends App.Controller
# get data from cache
cache = App.Store.get( 'dashboard_rss' )
if cache
cache.head = 'Heise ATOM'
@render( cache )
# init fetch via ajax, all other updates on time via websockets
@ -36,6 +37,7 @@ class App.DashboardRss extends App.Controller
)
else
App.Store.write( 'dashboard_rss', data )
data.head = 'Heise ATOM'
@render(data)
error: =>
@render(
@ -47,6 +49,6 @@ class App.DashboardRss extends App.Controller
render: (data) ->
@html App.view('dashboard/rss')(
head: data.head,
items: data.item || []
items: data.items || []
message: data.message
)