This repository has been archived by the owner on May 6, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 43
WFSGrid Plugin
Riccardo Mari edited this page Feb 18, 2014
·
6 revisions
This plugin allows you to display WFS features in a custom grid inside MapComposer. You can also add some action columns to the grid, that allow you to visualize and zoom to features.
Include in buildjs these files:
gxp/src/script/plugins/WFSGrid.js
...
"customPanels":[
{
"xtype": "panel",
"title": "WFSGrid Panel",
"border": false,
"id": "gridcontainer",
"region": "south",
"layout": "fit",
"split":true,
"height": 330,
"collapsed": true,
"collapsible": true,
"header": true
}
]
...
"customTools":[
...
{
"ptype": "gxp_wfsgrid",
"wfsURL": "http://localhost:8080/geoserver/wfs",
"featureType": "states",
"outputTarget": "gridcontainer",
"name": "States",
"fields": [
{
"name": "state_name",
"mapping": "STATE_NAME"
},
{
"name": "state_fips",
"mapping": "STATE_FIPS"
},
{
"name": "sub_region",
"mapping": "SUB_REGION"
}
],
"columns": [
{
"header": "State name",
"dataIndex": "state_name"
},
{
"header": "State fips",
"dataIndex": "state_fips"
},
{
"header": "Sub region",
"dataIndex": "sub_region"
}
],
"paging": false,
"actionColumns": [{
"type": "checkDisplay",
"layerName": "Highlight Layer",
"sourceSRS": "EPSG:4326"
},
{
"type": "zoom",
"sourceSRS": "EPSG:4326"
}]
}
...
]