diff --git a/static/js/pandora.js b/static/js/pandora.js index 49ef65d7..3e8b4b43 100644 --- a/static/js/pandora.js +++ b/static/js/pandora.js @@ -51,6 +51,19 @@ Ox.load({ site: data.site, user: data.user.level == 'guest' ? Ox.clone(data.site.user) : data.user }); + // ---- fixme: remove, server sends wrong data + pandora.site.user.ui.lists = { + "": { + "columns": ["title", "director", "country", "year", "language", "runtime", "genre"], + "columnWidth": {}, + "listView": "grid", + "selected": [], + "sort": [ + {"key": "director", "operator": ""} + ] + } + }; + // ---- Ox.print("USER.UI.LISTS", data.user.ui.lists, "SITE.USER.UI.LISTS", data.site.user.ui.lists) Ox.extend(pandora.site, { findKeys: Ox.map(data.site.itemKeys, function(key) { diff --git a/static/js/pandora/Query.js b/static/js/pandora/Query.js index 0db63cb7..61824adc 100644 --- a/static/js/pandora/Query.js +++ b/static/js/pandora/Query.js @@ -230,6 +230,13 @@ pandora.Query = (function() { !pandora.user.ui.lists[data.list] && pandora.UI.set( 'lists|' + data.list, pandora.site.user.ui.lists[''] ); + /* + // ---- fixme: remove, server sends wrong data + !pandora.user.ui.lists[data.list].sort && pandora.UI.set( + 'lists|' + data.list, pandora.site.user.ui.lists[''] + ); + // ---- + */ Ox.print('@@@@@', data.lists, pandora.user.ui.lists[data.list]) pandora.UI.set({list: data.list}); pandora.user.ui.find = data.find;