load places

This commit is contained in:
j 2011-06-18 20:48:49 +02:00
parent adbe21b570
commit 5bac6bb01d
2 changed files with 8 additions and 5 deletions

View file

@ -92,8 +92,8 @@ pandora.reloadGroups = function(i) {
}
});
} else if (view == 'map') {
pandora.$ui.list.options({
items: function(data, callback) {
pandora.$ui.map.options({
places: function(data, callback) {
return pandora.api.findPlaces($.extend(data, {
itemQuery: query
}), callback);

View file

@ -138,9 +138,12 @@ pandora.ui.list = function(view) { // fixme: remove view argument
element: pandora.$ui.map = Ox.Map({
height: window.innerHeight - pandora.user.ui.showGroups * pandora.user.ui.groupsSize - 61,
places: function(data, callback) {
return pandora.api.findPlaces($.extend({
query: {conditions: [], operator: ''}
}, data), callback);
var itemQuery = pandora.Query.toObject(),
query = {conditions:[]};
return pandora.api.findPlaces($.extend(data, {
itemQuery: itemQuery,
query: query
}), callback);
},
showTypes: true,
toolbar: true,