mxp.plugins.CategoriesInitializer - geosolutions-it/MapStore GitHub Wiki
Needed Files
In order to use this plugin you need to include this files in the build.cfg:
src/mxp/plugins/CategoriesInitializer.js
NOTE: In the default configuration this is already done.
Plugin description
This plugin initializes an array of categories in a GeoStore instance.
Configuration Example
You can configure it adding this plugin with this configuration:
{
"ptype": "mxp_categoryinitializer"
}
The basic parameters are:
- silentErrors: Flag to hide error window. Default is false
- neededCategories: Array of categories to be created if don't exists
- confirmCategoryCreation: Ask the user to create
this.neededCategories
if not present. Otherwise it will create the categories with the credentials configured.
Also you can change this parameters to allow the categories creation without prompt:
- adminAuthorization: Authorization header to use. You can put the header, use the
adminCredentials
oraskForcredentials
- adminCredentials: GeoStore administrator user name and password. It is an object with
user
andpass
- askForcredentials: Ask user admin credentials for categories initializing. Default it's true.
For example, if you put askForcredentials to false, you need to add adminAuthorization or adminCredentials parameters