Changeset 3382 for sandbox/camptocamp/mapfish_workshop_fossgis2010/printing_src/creating_webservice.txt
- Timestamp:
- 03/02/10 06:26:55 (2 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
sandbox/camptocamp/mapfish_workshop_fossgis2010/printing_src/creating_webservice.txt
r3378 r3382 31 31 CREATE DATABASE mapfish_workshop TEMPLATE=template_postgis; 32 32 33 Then, open the explorer, go into the `` C:\MapFish\mapfish_workshop\data``33 Then, open the explorer, go into the ``/home/live/mapfish/mapfish_workshop_fossgis2010/data`` 34 34 folder and extract the ``countries.zip`` file. And enter the following commands 35 35 to import the ``countries`` Shapefile as a table named ``countries`` in the 36 36 ``mapfish_workshop`` database:: 37 37 38 C:\MapFish>cd mapfish_workshop\data39 C:\MapFish\mapfish_workshop\data>"C:\Program Files\PostgreSQL\8.3\bin\shp2pgsql.exe" -s 4326 -I countries.shp countries | "C:\Program Files\PostgreSQL\8.3\bin\psql.exe"-d mapfish_workshop -U postgres38 cd /home/live/mapfish/mapfish_workshop_fossgis2010/data 39 ~mapfish/mapfish_workshop_fossgis2010/data$ shp2pgsql -s 4326 -I countries.shp countries | psql -d mapfish_workshop -U postgres 40 40 41 41 You can start pgAdmin and connect to the ``mapfish_workshop`` database to check … … 85 85 2. generate the web service code with the ``mf-layer`` command:: 86 86 87 <env> C:\MapFish\MapFishApp>paster mf-layer countries87 <env> ~mapfish/MapFishApp>paster mf-layer countries 88 88 89 89 3. configure a route to the ``countries`` controller, this is done by adding … … 98 98 restart ``MapFishApp`` with:: 99 99 100 <env> C:\MapFish\MapFishApp>paster serve --reload development.ini100 <env> ~mapfish/MapFishApp>paster serve --reload development.ini 101 101 102 102 You can now open http://localhost:5000/countries?limit=1 in your browser, you
