Handlebars.registerHelper('json', function(obj) {
- return JSON.stringify(obj);
+ return $.toJSON(obj);
});
}
}
- debug("triggerSearch(" + mkws.query + "): filters = " + JSON.stringify(mkws.filters) + ", pp2filter = " + pp2filter + ", pp2limit = " + pp2limit);
+ debug("triggerSearch(" + mkws.query + "): filters = " + $.toJSON(mkws.filters) + ", pp2filter = " + pp2filter + ", pp2limit = " + pp2limit);
my_paz.search(mkws.query, recPerPage, mkws.sort, pp2filter, undefined, { limit: pp2limit });
}
if (filter.field &&
field == filter.field &&
value == filter.value) {
- debug("delimitTarget() removing filter " + JSON.stringify(filter));
+ debug("delimitTarget() removing filter " + $.toJSON(filter));
} else {
- debug("delimitTarget() keeping filter " + JSON.stringify(filter));
+ debug("delimitTarget() keeping filter " + $.toJSON(filter));
newFilters.push(filter);
}
}
for (var i in mkws.filters) {
var filter = mkws.filters[i];
if (filter.id) {
- debug("delimitTarget() removing filter " + JSON.stringify(filter));
+ debug("delimitTarget() removing filter " + $.toJSON(filter));
} else {
- debug("delimitTarget() keeping filter " + JSON.stringify(filter));
+ debug("delimitTarget() keeping filter " + $.toJSON(filter));
newFilters.push(filter);
}
}