forked from 0x2620/pandora
load places
This commit is contained in:
parent
f4bd971f0a
commit
30fa62962d
2 changed files with 8 additions and 5 deletions
|
@ -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);
|
||||
|
|
|
@ -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,
|
||||
|
|
Loading…
Reference in a new issue