8.11.0
🚀 Features / Improvements​
- Load single post location: When viewing a single post page, MapSVG can now load only the location for that specific post instead of all locations. You can find that in Actions > Map > On Load (options is visible only if post field is present in the DB or Regions tables)
- AND/OR logic for multiselect filters: Multiselect filters now support choosing between AND and OR logic. Pass an object with
operatorandvaluekeys to control the behavior. For now, you'll need to add a few lines of JS code to the API request middleware code. Soon the options will also be added to the filter settings:
function(data, ctx){
const { request, repository, map } = ctx;
if(repository.schema.objectNamePlural === "objects" && request.action === "index") {
data = {
...data,
filters: {category: {operator: "or", value: data.filters.category}}
};
}
return data;
}