ckanext-mapsearch
所属分类:大数据
开发工具:JavaScript
文件大小:0KB
下载次数:0
上传日期:2014-11-07 11:53:36
上 传 者:
sh-1993
说明: CKAN扩展,用于添加以地图为中心的缩放感知搜索,
(A CKAN extension to add an scale-aware map-centred search,)
文件列表:
LICENSE.txt (34520, 2014-11-07)
ckanext-mapsearch/ (0, 2014-11-07)
ckanext-mapsearch/ckanext/ (0, 2014-11-07)
ckanext-mapsearch/ckanext/__init__.py (200, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/ (0, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/__init__.py (200, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/controllers.py (1106, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/ (0, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/ (0, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ (0, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/animated-overlay.gif (1738, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_diagonals-thick_18_b81900_40x40.png (418, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_diagonals-thick_20_666666_40x40.png (312, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_flat_10_000000_40x100.png (205, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_glass_100_f6f6f6_1x400.png (262, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_glass_100_fdf5ce_1x400.png (348, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_glass_65_ffffff_1x400.png (207, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_gloss-wave_35_f6a828_500x100.png (5815, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_highlight-soft_100_eeeeee_1x100.png (278, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-bg_highlight-soft_75_ffe45c_1x100.png (328, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-icons_222222_256x240.png (6922, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-icons_228ef1_256x240.png (4549, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-icons_ef8c08_256x240.png (4549, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-icons_ffd27a_256x240.png (4549, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/images/ui-icons_ffffff_256x240.png (6299, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/jquery_ui_min.css (27155, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/css/style.css (4032, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/ (0, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/filters.js (3229, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/handle_geofacets.js (2912, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/mapsearch.js (6299, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/message.js (491, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/result_navigation.js (3123, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/result_panel.js (5110, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/search_results.js (3475, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/setup.js (4789, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/transport.js (3842, 2014-11-07)
ckanext-mapsearch/ckanext/mapsearch/fanstatic/javascripts/vendor/ (0, 2014-11-07)
... ...
CKAN Mapsearch extension
========================
ABOUT
-----
Mapsearch is a CKAN-extension to add a scale-aware, map-centered search
to the *CKAN spatial extension* [(ckanext-spatial)](https://github.com/ckan/ckanext-spatial).
![Full screenshot](https://raw.githubusercontent.com/bopen/ckanext-mapsearch/master/ckanext-mapsearch/ckanext/mapsearch/public/mapsearch_shot.png)
FEATURES
--------
Its main distinguishing factor is the scale-awareness of the
search-engine.
This scale-awareness lets you see how many results there are on 5
different scales for the same geographic area of interest, by using an
extra area field during indexing. see [this](#4-prepare-the-schema-for-the-extension) paragraph below.
![screenshot scales](https://raw.githubusercontent.com/bopen/ckanext-mapsearch/master/ckanext-mapsearch/ckanext/mapsearch/public/mapsearch_scales.png)
DEMO
----
see a working demo on [bopen.eu](http://ckan.bopen.eu/mapsearch).
INSTALLATION
------------
*ckanext-mapsearch* is installed like any ckan extension. However, as it
depends on *ckanext-spatial* to be installed, make sure mapsearch comes
after ckanext-spatial in the plugin list (see [below](#2-add-the-extension-as-a-plugin)).
It also requires solr >= 3.1, as per http://docs.ckan.org/projects/ckanext-spatial/en/latest/spatial-search.html#choosing-a-backend-for-the-spatial-search.
### 1. install the extension with pip
```
pip install -e git+https://github.com/bopen/ckanext-mapsearch.git#egg=ckanext-mapsearch
```
### 2. add the extension as a plugin
add the plugin to the plugins-line in your configuration *.ini* file.
**NB. It must be included with, but after *spatial\_query***
```
ckan.plugins = stats text_preview resource_proxy recline_preview spatial_metadata spatial_query harvest csw_harvester ckan_harvester mapsearch
```
### 3. configure the extension
- set the initial mapextent
add a line to your ini-file specifying the initial map extent ([bottom-left, upper-right]). To show Europe area on loadpage add the following line:
```
ckanext.mapsearch.initial_map_extent = [[30.4806, -12.9449], [72.9295, 40.7210]]
```
- make sure the spatial extension uses solr-spatial field as the
backend.
**NB.: the search-backend of the spatial extension *must* be set to
‘solr-spatial-field’, as with simple ‘solr’ the extension will work
poorly and with ‘postgis’ it will not work at all!**
```
ckanext.spatial.search_backend = solr-spatial-field
```
### 4. prepare the schema for the extension
the extension needs an extra field in the solr index, add the following
line to the schema.xml file in the ‘\’ section.
```
```
### 5. restart solr
TESTS
-----
there are few basic selenium webdriver tests in `tests` folder.
NB:
- You will need full working instance with a minimum of data to run the tests.
- The tests assume you have an instance running on 'http://localhost:5000/mapsearch'.
However, you can override this by setting the *environment variable* MAPSEARCH_INSTANCE_URL appropriately.
```
export MAPSEARCH_INSTANCE_URL="http://ckan.bopen.eu/mapsearch"
```
LICENSE
=======
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see http://www.gnu.org/licenses/.
Acknowledgements
================
The development of this software, up to version *0.1.2*, has been partially funded by `Filas `_ under `POR FESR Lazio 2007-2013 `_.
近期下载者:
相关文件:
收藏者: