├── .gitignore ├── LICENSE ├── MANIFEST.in ├── README.rst ├── README_cn.rst ├── application.py ├── cfg_demo.py ├── config.py ├── database └── meta │ └── maplet_info_tags.xlsx ├── doc ├── PureHTML_Demo │ ├── geojson_ajax.html │ ├── gscript.js │ └── leaflet_maplet.html └── requirements.txt ├── extor ├── __init__.py ├── handlers │ ├── __init__.py │ ├── ext_tutorial_hander.py │ └── list_handler.py ├── model │ ├── __init__.py │ └── ext_category_model.py └── modules │ ├── __init__.py │ └── extends.py ├── helper.py ├── helper_extor.py ├── push_code.sh ├── router.py ├── script_book01_format_name.py ├── script_book02_meta_import.py ├── script_helper ├── request_book_info.py └── script02_gen_book_info2.py ├── script_import_maps.py ├── script_migrate.py ├── script_migrate_maplet.py ├── server.py ├── setup.py ├── static ├── admin-css │ ├── css │ │ ├── admin.css │ │ ├── datepicker3.css │ │ └── styles.css │ └── js │ │ ├── chart-data.js │ │ ├── chart.min.js │ │ ├── easypiechart-data.js │ │ ├── easypiechart.js │ │ ├── html5shiv.min.js │ │ └── respond.min.js ├── dist_me │ ├── app.a151672f186b70be858f28af314a1d7b.css │ ├── app.css │ ├── fonts │ │ ├── MaterialIcons-Regular.012cf6a.woff │ │ ├── iconfont.0fee7bc.ttf │ │ └── iconfont.6a36ee0.eot │ ├── img │ │ ├── googleSatellite.6807c20.jpg │ │ ├── googleStreet.6ebfd50.jpg │ │ ├── googleTerrainSimple.592b9de.jpg │ │ ├── googleTerrainStreet.2fbb7b7.jpg │ │ ├── iconfont.11dddad.svg │ │ ├── iconfont.2bd3fff.svg │ │ ├── qqSatellite.dce1d5b.jpg │ │ ├── qqTerrainStreet.480f0cf.jpg │ │ ├── tianDiTuTerrain.a286eb6.jpg │ │ └── tianDiTuTerrainStreet.abd1f13.jpg │ ├── index.html │ └── js │ │ ├── app.js │ │ ├── manifest.js │ │ └── vendor.js ├── dist_mv │ ├── L.TextIcon.js │ ├── geojson.js │ ├── iconfont │ │ ├── demo.css │ │ ├── demo_fontclass.html │ │ ├── demo_symbol.html │ │ ├── demo_unicode.html │ │ ├── iconfont.css │ │ ├── iconfont.eot │ │ ├── iconfont.js │ │ ├── iconfont.svg │ │ ├── iconfont.ttf │ │ └── iconfont.woff │ ├── texticon.css │ └── view.html ├── favicon.ico ├── fixed │ ├── alipay_maplet.png │ ├── amazon1_raw.png │ ├── amazon2.jpg │ ├── amazon2_raw.jpg │ ├── geodata.png │ └── maplet_qrcode.png ├── imgs │ ├── 1452351792025.png │ ├── index-1.jpg │ ├── index-2.jpg │ ├── index-3.jpg │ ├── index-4.jpg │ ├── index-5.jpg │ ├── index-6.jpg │ └── index-7.jpg ├── jslib │ ├── .eslintrc.js │ ├── Gruntfile.js │ ├── ReadMe.md │ ├── dst │ │ ├── L.Map.Sync.js │ │ ├── fullscreen.js │ │ ├── gscript.js │ │ ├── gson_china.js │ │ ├── gsonedit.js │ │ ├── leafedit.js │ │ ├── leaflet-side-by-side.min.js │ │ └── overlay.js │ ├── dst_v2 │ │ ├── L.Map.Sync.js │ │ ├── app.js │ │ ├── gscript.js │ │ ├── leaflet-side-by-side.min.js │ │ ├── manifest.js │ │ ├── overlay.js │ │ └── vendor.js │ ├── maplet │ │ ├── fullscreenm.js │ │ ├── geojson_edit.js │ │ └── overlaym.js │ ├── package.json │ └── src │ │ ├── Leaflet.Editable.js │ │ ├── Leaflet.Storage │ │ ├── CHANGELOG.md │ │ ├── Gruntfile.js │ │ ├── LICENCE │ │ ├── Makefile │ │ ├── README.rst │ │ ├── contrib │ │ │ ├── css │ │ │ │ └── storage.ui.default.css │ │ │ └── js │ │ │ │ ├── storage.ui.default.js │ │ │ │ └── storage.ui.foundation.js │ │ ├── package.json │ │ ├── src │ │ │ ├── css │ │ │ │ └── storage.css │ │ │ ├── img │ │ │ │ ├── 16-white.png │ │ │ │ ├── 16-white.svg │ │ │ │ ├── 16.png │ │ │ │ ├── 16.svg │ │ │ │ ├── 24-white.png │ │ │ │ ├── 24-white.svg │ │ │ │ ├── 24.png │ │ │ │ ├── 24.svg │ │ │ │ ├── edit-16.png │ │ │ │ ├── icon-bg.png │ │ │ │ ├── marker.png │ │ │ │ └── search.gif │ │ │ ├── js │ │ │ │ ├── leaflet.storage.controls.js │ │ │ │ ├── leaflet.storage.core.js │ │ │ │ ├── leaflet.storage.features.js │ │ │ │ ├── leaflet.storage.forms.js │ │ │ │ ├── leaflet.storage.icon.js │ │ │ │ ├── leaflet.storage.js │ │ │ │ ├── leaflet.storage.layer.js │ │ │ │ ├── leaflet.storage.popup.js │ │ │ │ ├── leaflet.storage.slideshow.js │ │ │ │ ├── leaflet.storage.tableeditor.js │ │ │ │ └── leaflet.storage.xhr.js │ │ │ └── locale │ │ │ │ ├── am_ET.json │ │ │ │ ├── bg.json │ │ │ │ ├── ca.json │ │ │ │ ├── cs_CZ.json │ │ │ │ ├── da.json │ │ │ │ ├── de.json │ │ │ │ ├── en.json │ │ │ │ ├── es.json │ │ │ │ ├── fi.json │ │ │ │ ├── fr.json │ │ │ │ ├── it.json │ │ │ │ ├── ja.json │ │ │ │ ├── lt.json │ │ │ │ ├── nl.json │ │ │ │ ├── pt.json │ │ │ │ ├── ru.json │ │ │ │ ├── uk_UA.json │ │ │ │ ├── vi.json │ │ │ │ ├── zh.json │ │ │ │ └── zh_TW.json │ │ └── test │ │ │ ├── Controls.js │ │ │ ├── DataLayer.js │ │ │ ├── Feature.js │ │ │ ├── Map.js │ │ │ ├── Polygon.js │ │ │ ├── Polyline.js │ │ │ ├── TableEditor.js │ │ │ ├── Util.js │ │ │ ├── _pre.js │ │ │ └── index.html │ │ ├── Leaflet.StyleEditor │ │ ├── Gruntfile.js │ │ ├── LICENSE.md │ │ ├── README.md │ │ ├── bower.json │ │ ├── package.json │ │ └── src │ │ │ ├── css │ │ │ └── Leaflet.StyleEditor.css │ │ │ ├── img │ │ │ ├── icon.png │ │ │ ├── icon.svg │ │ │ └── icon2.png │ │ │ ├── index.html │ │ │ └── javascript │ │ │ ├── Leaflet.StyleEditor.js │ │ │ └── Leaflet.StyleForms.js │ │ ├── Leaflet.draw │ │ ├── BREAKINGCHANGES.md │ │ ├── CHANGELOG.md │ │ ├── Jakefile.js │ │ ├── MIT-LICENSE.md │ │ ├── README.md │ │ ├── TODO.md │ │ ├── bower.json │ │ ├── examples │ │ │ ├── 0.7.x │ │ │ │ ├── basic.html │ │ │ │ ├── edithandlers.html │ │ │ │ ├── full.html │ │ │ │ ├── libs │ │ │ │ │ ├── Leaflet.draw.drag-src.js │ │ │ │ │ ├── images │ │ │ │ │ │ ├── layers-2x.png │ │ │ │ │ │ ├── layers.png │ │ │ │ │ │ ├── marker-icon-2x.png │ │ │ │ │ │ ├── marker-icon.png │ │ │ │ │ │ ├── marker-icon@2x.png │ │ │ │ │ │ └── marker-shadow.png │ │ │ │ │ ├── leaflet-src.js │ │ │ │ │ ├── leaflet.css │ │ │ │ │ ├── leaflet.geometryutil.js │ │ │ │ │ ├── leaflet.snap.js │ │ │ │ │ ├── spectrum.css │ │ │ │ │ └── spectrum.js │ │ │ │ └── snapping.html │ │ │ ├── basic.html │ │ │ ├── edithandlers.html │ │ │ ├── full.html │ │ │ ├── libs │ │ │ │ ├── Leaflet.draw.drag-src.js │ │ │ │ ├── images │ │ │ │ │ ├── layers-2x.png │ │ │ │ │ ├── layers.png │ │ │ │ │ ├── marker-icon-2x.png │ │ │ │ │ ├── marker-icon.png │ │ │ │ │ └── marker-shadow.png │ │ │ │ ├── leaflet-src.js │ │ │ │ ├── leaflet.css │ │ │ │ ├── leaflet.geometryutil.js │ │ │ │ ├── leaflet.snap.js │ │ │ │ ├── spectrum.css │ │ │ │ └── spectrum.js │ │ │ ├── popup.html │ │ │ └── snapping.html │ │ ├── package.json │ │ ├── spec │ │ │ ├── after.js │ │ │ ├── before.js │ │ │ ├── expect.js │ │ │ ├── happen.js │ │ │ ├── index.html │ │ │ ├── karma.conf.js │ │ │ ├── sinon.js │ │ │ ├── spec.hintrc.js │ │ │ └── suites │ │ │ │ ├── DrawControlSpec.js │ │ │ │ ├── EditSpec.js │ │ │ │ ├── GeometryUtilSpec.js │ │ │ │ ├── LatLngUtilSpec.js │ │ │ │ └── SpecHelper.js │ │ └── src │ │ │ ├── Control.Draw.js │ │ │ ├── Leaflet.draw.js │ │ │ ├── Toolbar.js │ │ │ ├── Tooltip.js │ │ │ ├── copyright.js │ │ │ ├── draw │ │ │ ├── DrawToolbar.js │ │ │ └── handler │ │ │ │ ├── Draw.Circle.js │ │ │ │ ├── Draw.Feature.js │ │ │ │ ├── Draw.Marker.js │ │ │ │ ├── Draw.Polygon.js │ │ │ │ ├── Draw.Polyline.js │ │ │ │ ├── Draw.Rectangle.js │ │ │ │ └── Draw.SimpleShape.js │ │ │ ├── edit │ │ │ ├── EditToolbar.js │ │ │ └── handler │ │ │ │ ├── Edit.Circle.js │ │ │ │ ├── Edit.Marker.js │ │ │ │ ├── Edit.Poly.js │ │ │ │ ├── Edit.Rectangle.js │ │ │ │ ├── Edit.SimpleShape.js │ │ │ │ ├── EditToolbar.Delete.js │ │ │ │ └── EditToolbar.Edit.js │ │ │ ├── ext │ │ │ ├── GeometryUtil.js │ │ │ ├── LatLngUtil.js │ │ │ ├── LineUtil.Intersect.js │ │ │ ├── Polygon.Intersect.js │ │ │ ├── Polyline.Intersect.js │ │ │ └── TouchEvents.js │ │ │ └── images │ │ │ └── spritesheet.svg │ │ ├── LeafletPlugin │ │ ├── L.Map.Sync.js │ │ └── leaflet-side-by-side.min.js │ │ ├── chart │ │ ├── backen.js │ │ ├── gnchina.min.js │ │ ├── gson_china.js │ │ ├── sheng │ │ │ ├── j043a.js │ │ │ ├── j05d1.js │ │ │ ├── j061f.js │ │ │ ├── j0946.js │ │ │ ├── j0bad.js │ │ │ ├── j0c65.js │ │ │ ├── j0e59.js │ │ │ ├── j0ed6.js │ │ │ ├── j0f51.js │ │ │ ├── j0fea.js │ │ │ ├── j1341.js │ │ │ ├── j1342.js │ │ │ ├── j1343.js │ │ │ ├── j1344.js │ │ │ ├── j1345.js │ │ │ ├── j1346.js │ │ │ ├── j1347.js │ │ │ ├── j1348.js │ │ │ ├── j1349.js │ │ │ ├── j1350.js │ │ │ ├── j1b2f.js │ │ │ ├── j1e23.js │ │ │ ├── j2906.js │ │ │ ├── j2956.js │ │ │ ├── j2d53.js │ │ │ ├── j35ea.js │ │ │ ├── j3a7b.js │ │ │ ├── j3b04.js │ │ │ ├── j3b71.js │ │ │ ├── j3c97.js │ │ │ ├── j3d8c.js │ │ │ ├── j3e1a.js │ │ │ ├── j3e4a.js │ │ │ ├── j4d95.js │ │ │ ├── j4eac.js │ │ │ ├── j4f8a.js │ │ │ ├── j5061.js │ │ │ ├── j5091.js │ │ │ ├── j5698.js │ │ │ ├── j56b7.js │ │ │ ├── j58bf.js │ │ │ ├── j5972.js │ │ │ ├── j5a9e.js │ │ │ ├── j5d98.js │ │ │ ├── j5e6a.js │ │ │ ├── j6e1a.js │ │ │ ├── j7295.js │ │ │ ├── j7531.js │ │ │ ├── j75e0.js │ │ │ ├── j7e85.js │ │ │ ├── j8230.js │ │ │ ├── j867b.js │ │ │ ├── j8760.js │ │ │ ├── j87fc.js │ │ │ ├── j8c9a.js │ │ │ ├── j8d14.js │ │ │ ├── j9084.js │ │ │ ├── j92e3.js │ │ │ ├── j934b.js │ │ │ ├── j93d1.js │ │ │ ├── j9715.js │ │ │ ├── j97d1.js │ │ │ ├── ja1e8.js │ │ │ ├── ja3f5.js │ │ │ ├── ja92b.js │ │ │ ├── jadc2.js │ │ │ ├── jadce.js │ │ │ ├── jb2a5.js │ │ │ ├── jb519.js │ │ │ ├── jb6d3.js │ │ │ ├── jba53.js │ │ │ ├── jba82.js │ │ │ ├── jbed6.js │ │ │ ├── jc586.js │ │ │ ├── jc670.js │ │ │ ├── jc8ab.js │ │ │ ├── jca42.js │ │ │ ├── jca59.js │ │ │ ├── jcb85.js │ │ │ ├── jcd1a.js │ │ │ ├── jd283.js │ │ │ ├── jd431.js │ │ │ ├── jd7b4.js │ │ │ ├── jdb89.js │ │ │ ├── jdeb4.js │ │ │ ├── jeb27.js │ │ │ ├── jf6ae.js │ │ │ ├── jfb21.js │ │ │ ├── jfbe7.js │ │ │ ├── jfc7a.js │ │ │ └── jfcdb.js │ │ └── ugli.sh │ │ ├── gscript.js │ │ ├── mapshow.js │ │ └── message_cn.js ├── robots.txt ├── tass │ ├── app.8809c97ce45b1829aef73dc75214f066.css │ ├── config.rb │ ├── css │ │ ├── admin.css │ │ ├── app.css │ │ ├── map_styles.css │ │ └── style.css │ ├── ext │ │ ├── __init__.py │ │ ├── loadmore.css │ │ ├── loadmore.js │ │ └── zepto.min.js │ ├── fonts │ │ └── bootstrap │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ └── sass │ │ ├── _bootstrap-variables.sass │ │ ├── _fonts.scss │ │ ├── inc │ │ ├── _carousel.sass │ │ ├── _codemirror.sass │ │ ├── _map.sass │ │ └── _tags.sass │ │ └── style.sass └── ui.js ├── team ├── bukun └── gislite ├── templates ├── admin │ ├── admin.html │ ├── admin_index.html │ ├── category_ajax │ │ └── category_list.html │ ├── link_ajax │ │ ├── link_add.html │ │ ├── link_edit.html │ │ ├── link_list.html │ │ └── link_view.html │ ├── page_ajax │ │ ├── page_add.html │ │ ├── page_edit.html │ │ ├── page_list.html │ │ └── page_view.html │ ├── post_ajax │ │ ├── post_add.html │ │ ├── post_edit.html │ │ ├── post_list.html │ │ ├── post_list_none.html │ │ └── post_view.html │ ├── reply_ajax │ │ └── reply_list.html │ └── user │ │ ├── puser_changeinfo.html │ │ ├── puser_changepass.html │ │ ├── puser_find.html │ │ ├── puser_find_list.html │ │ └── puser_info.html ├── geoinfo │ └── geojson │ │ ├── gson_edit.html │ │ ├── gson_recent.html │ │ └── index.html ├── index │ └── index.html ├── jshtml │ └── init_vipfs_js.html ├── list │ ├── category_list_1.html │ ├── category_list_m.html │ ├── category_list_o.html │ ├── errcat.html │ ├── label.html │ └── post_list.html ├── man_info │ ├── admin_post.html │ ├── post_man_edit.html │ ├── post_man_view.html │ ├── wiki_man_edit.html │ └── wiki_man_view.html ├── map_theme │ └── modules │ │ ├── app_json.html │ │ └── app_layout.html ├── misc │ ├── collect │ │ └── list.html │ ├── entity │ │ ├── entity_add.html │ │ ├── entity_download.html │ │ ├── entity_list.html │ │ └── entity_view.html │ ├── html │ │ └── 404.html │ ├── publish │ │ ├── publish.html │ │ └── publish2.html │ ├── reply │ │ └── show_reply.html │ └── search │ │ └── search_list.html ├── modules_ext │ └── post │ │ ├── showcat_list.html │ │ ├── showsubcat_list.html │ │ └── showsubcat_list_second.html ├── post_1 │ ├── post_add.html │ ├── post_edit.html │ ├── post_index.html │ └── post_view.html ├── post_m │ ├── full_screen.html │ ├── full_screen_draw.html │ ├── mapview │ │ ├── overlay.html │ │ ├── overlay_full.html │ │ ├── split_full.html │ │ └── sync_full.html │ ├── post_add.html │ ├── post_edit.html │ ├── post_index.html │ ├── show_map.html │ ├── tag_list.html │ └── view3d.html ├── post_m_v2 │ ├── full_screen.html │ ├── full_screen_draw.html │ ├── full_screen_draw_v2.html │ ├── mapview │ │ ├── overlay.html │ │ ├── overlay_full.html │ │ ├── split_full.html │ │ └── sync_full.html │ ├── post_edit.html │ └── show_map.html ├── post_man │ ├── post_man_edit.html │ └── post_man_view.html ├── static_pages │ ├── 404.html │ ├── baidu-verify-AE51DC826E.txt │ ├── baidu_verify_DbLlKH6POw.html │ ├── google7ed50801cec3edd3.html │ ├── map │ │ └── img │ │ │ ├── googleSatellite.6807c20.jpg │ │ │ ├── googleStreet.6ebfd50.jpg │ │ │ ├── googleTerrainSimple.592b9de.jpg │ │ │ ├── googleTerrainStreet.2fbb7b7.jpg │ │ │ ├── qqSatellite.dce1d5b.jpg │ │ │ ├── qqTerrainStreet.480f0cf.jpg │ │ │ ├── tianDiTuTerrain.a286eb6.jpg │ │ │ └── tianDiTuTerrainStreet.abd1f13.jpg │ └── sogousiteverification.txt ├── theme │ ├── admin.html │ ├── base.html │ ├── base_edit.html │ ├── base_map.html │ ├── base_zhu.html │ ├── map_calcubic_full.html │ └── overlay.html ├── tmpl_k │ ├── tmplinfo.html │ ├── tpl_add.html │ ├── tpl_edit.html │ ├── tpl_list.html │ ├── tpl_listinfo.html │ └── tpl_view.html ├── user │ ├── info_list │ │ ├── user_most.html │ │ └── user_recent.html │ ├── user_changepass.html │ ├── user_changerole.html │ ├── user_find.html │ ├── user_find_list.html │ ├── user_info.html │ ├── user_login.html │ ├── user_regist.html │ ├── user_relogin.html │ ├── user_reset_password.html │ └── user_show_pass.html ├── wiki_man │ ├── wiki_man_edit.html │ └── wiki_man_view.html └── wiki_page │ ├── page_add.html │ ├── page_edit.html │ ├── page_list.html │ ├── page_view.html │ ├── wiki_add.html │ ├── wiki_edit.html │ ├── wiki_list.html │ ├── wiki_login.html │ └── wiki_view.html ├── torcms_maplet ├── __init__.py ├── core │ ├── __init__.py │ ├── router.py │ ├── tools.py │ └── webdog_to_geojson.py ├── handlers │ ├── __init__.py │ ├── geojson.py │ ├── geojson_v2.py │ ├── geojson_v3.py │ ├── map_handler.py │ └── mapview_handler.py ├── model │ ├── __init__.py │ ├── json_model.py │ ├── layout_model.py │ └── map_tab.py ├── modules │ ├── __init__.py │ ├── map_modules.py │ └── modef.py └── script │ ├── __init__.py │ ├── script_drop_tabels.py │ └── script_init_tabels.py └── urls.py /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | .idea/ 3 | .idea 4 | 5 | # Byte-compiled / optimized / DLL files 6 | __pycache__/ 7 | *.py[cod] 8 | 9 | # C extensions 10 | *.so 11 | 12 | # Distribution / packaging 13 | .Python 14 | env/ 15 | build/ 16 | develop-eggs/ 17 | dist/ 18 | downloads/ 19 | eggs/ 20 | # lib/ 21 | lib64/ 22 | parts/ 23 | sdist/ 24 | var/ 25 | *.egg-info/ 26 | .installed.cfg 27 | *.egg 28 | 29 | # PyInstaller 30 | # Usually these files are written by a python script from a template 31 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 32 | *.manifest 33 | *.spec 34 | 35 | # Installer logs 36 | pip-log.txt 37 | pip-delete-this-directory.txt 38 | 39 | # Unit test / coverage reports 40 | htmlcov/ 41 | .tox/ 42 | .coverage 43 | .cache 44 | nosetests.xml 45 | coverage.xml 46 | 47 | # Translations 48 | *.mo 49 | *.pot 50 | 51 | # Coffee script. 52 | *.map 53 | # Django stuff: 54 | *.log 55 | 56 | # Sphinx documentation 57 | docs/_build/ 58 | 59 | # PyBuilder 60 | target/ 61 | 62 | ### Configure for TorCMS/torlite 63 | 64 | xx* 65 | cfg.py 66 | 67 | .DS_Store 68 | *.db 69 | *.sqlite 70 | *.pkl 71 | 72 | torcms 73 | database/whoosh* 74 | database/whoosh 75 | static/upload/ 76 | static/f2elib/ 77 | 78 | 79 | static/tass/.sass-cache/ 80 | templates/autogen/ 81 | templates/modules 82 | 83 | torcms_helper 84 | 85 | static/jslib/node_modules 86 | # 图书的信息 87 | script_helper/k* -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2015 Bu Kun 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | 23 | -------------------------------------------------------------------------------- /MANIFEST.in: -------------------------------------------------------------------------------- 1 | # include_package_data=True 2 | # recursive-exclude tester * 3 | # recursive-exclude flasky * 4 | # recursive-exclude torcms_maplet * 5 | prune tester* 6 | prune flasky* 7 | 8 | # exclude_package_data=True 9 | -------------------------------------------------------------------------------- /README.rst: -------------------------------------------------------------------------------- 1 | Maplet 2 | ======= 3 | 4 | Source codes for http://www.maphub.cn 5 | 6 | Introduction 7 | ------------------------ 8 | 9 | The CMS was desinged as the container for GIS showing as the very beginning. 10 | It has the basic map showing, map overlaying, GIS data editing funtion now. 11 | And, the CMS could used to publish different kind the information, 12 | such as basic HTML page, JavaScript app, maps, multimedias. 13 | 14 | 15 | Building the environment 16 | --------------------------------- 17 | 18 | :: 19 | 20 | python3 -m venv ~/vpy_maplet 21 | source ~/vpy_maplet/bin/activate 22 | pip3 install -r doc/requirements.txt 23 | git clone https://github.com/bukun/torcms_f2elib.git static/f2elib 24 | git clone https://github.com/bukun/torcms_modules_bootstrap.git templates/modules 25 | 26 | Setup 27 | ----------------------- 28 | 29 | Database 30 | 31 | :: 32 | 33 | \set dbname maplet 34 | CREATE USER :dbname WITH PASSWORD '131322' ; 35 | CREATE DATABASE :dbname OWNER :dbname ; 36 | GRANT ALL PRIVILEGES ON DATABASE :dbname to :dbname ; 37 | \c :dbname ; 38 | create extension hstore; 39 | \q 40 | 41 | Backup the database: postgres user 42 | 43 | :: 44 | 45 | pg_dump -h localhost -U maplet maplet > pg_maplet-`date +%F`.sql 46 | 47 | Import the database backup file: postgres user 48 | 49 | :: 50 | 51 | psql -d maplet -U maplet -f pg_maplet-xx.sql 52 | -------------------------------------------------------------------------------- /application.py: -------------------------------------------------------------------------------- 1 | # -*- coding:utf-8 -*- 2 | 3 | 4 | import os 5 | import tornado.web 6 | from torcms.modules.modef import core_modules 7 | import torcms.core.uifunction as uifuncs 8 | # from extor.modules.map_modules import * 9 | from torcms_maplet.modules.modef import maplet_modules 10 | from config import SITE_CFG 11 | from urls import urls 12 | from torcms.modules.modef import core_modules as cmodules 13 | from extor.modules.extends import Ext_category_menu,Ext_category_list 14 | 15 | # cur_modues = {'app_layout': app_layout, 16 | # 'app_json': app_json, 17 | # } 18 | 19 | 20 | # Above Python 3.5. 21 | cmodules = {**core_modules, **maplet_modules} 22 | 23 | cmodules['ext_category_menu'] = Ext_category_menu 24 | cmodules['ext_category_list'] = Ext_category_list 25 | 26 | SETTINGS = { 27 | "template_path": os.path.join(os.path.dirname(__file__), "templates"), 28 | "static_path": os.path.join(os.path.dirname(__file__), "static"), 29 | 'debug': SITE_CFG['DEBUG'], 30 | "cookie_secret": SITE_CFG['cookie_secret'], 31 | "login_url": "/user/login", 32 | 'ui_modules': cmodules, 33 | 'ui_methods': uifuncs, 34 | } 35 | 36 | app = tornado.web.Application( 37 | handlers=urls, 38 | **SETTINGS 39 | ) -------------------------------------------------------------------------------- /cfg_demo.py: -------------------------------------------------------------------------------- 1 | # -*- coding:utf-8 -*- 2 | 3 | ''' 4 | User defined Configuration for the application. 5 | ''' 6 | 7 | DB_CFG = { 8 | 'db': 'maplet', 9 | 'user': 'maplet', 10 | 'pass': '131322', 11 | } 12 | 13 | SMTP_CFG = { 14 | 'name': '云算笔记', 15 | 'host': "smtp.ym.163.com", 16 | 'user': "admin@yunsuan.org", 17 | 'pass': "pass", 18 | 'postfix': 'yunsuan.org', 19 | } 20 | 21 | SITE_CFG = { 22 | 'site_url': 'http://127.0.0.1:8777', 23 | 'cookie_secret': 'sadfasdf', 24 | 'DEBUG': True, 25 | 'wcs': 'wcs.osgeo.cn' 26 | } 27 | ROLE_CFG = { 28 | 'add': '1000', 29 | 'edit': '2000', 30 | 'delete': '3000', 31 | } -------------------------------------------------------------------------------- /config.py: -------------------------------------------------------------------------------- 1 | # -*- coding:utf-8 -*- 2 | import cfg 3 | from torcms.core.tools import get_cfg 4 | 5 | DB_CON, SMTP_CFG, SITE_CFG, ROLE_CFG = get_cfg() 6 | 7 | DB_CFG = { 8 | 'conn': DB_CON, 9 | 'kind': 'p', # 'p' for PostgresQL, 's' for SQLite. 10 | } 11 | 12 | wcs_svr = cfg.SITE_CFG['wcs'] 13 | 14 | CMS_CFG = { 15 | 'list_num': 15, 16 | 'site_type': 2, 17 | 'tpl2': ['9', 'm', 'k'], 18 | 'redis_kw': 'lsadfkj'} 19 | 20 | router_post = {'1': 'post', 21 | 'm': 'map', 22 | 'k': 'books'} 23 | 24 | post_type = { 25 | '1': '[{0}]'.format('文档'), 26 | 'm': '[{0}]'.format('地图'), 27 | 'k': '[{0}]'.format('图书'), 28 | } 29 | 30 | kind_arr = ['m', 'k'] 31 | post_emails = ['gislite@osgeo.cn', '118171@qq.com'] 32 | email_cfg = { 33 | 'title': '好久没登录了', 34 | 'content': 35 | '''
40 |
标题 | 19 |分类 | 20 |时间 | 21 |操作 | 22 |
---|---|---|---|
27 |
|
34 |
{{gson.title if gson.title else gson.uid }} | 21 |{{gson.user_id}} | 22 |{{gson.time_update}} | 23 |
序号 | 18 |文件 | 19 |用户名 | 20 |数量 | 21 |
{{ ii }} | 26 |{{ x.entity_path }} | 27 |{{ userinfo.user_name }} | 28 |{{ x.count }} | 29 |
对不起,由于未知原因,找不到您要找的页面。
15 |{{ kwd['info'] }}
21 | {% end %} 22 | {% if 'link' in kwd %} 23 | 24 | {% end %} 25 | {% end %} 26 |{{ username }} 3 |
4 | 5 |{% raw unescape(reply.cnt_html) %}
6 |发布于 9 | {{ str(date).split('.')[0] }} 10 | 11 | 12 | 13 | {{ vote }} 14 |
15 | 16 |17 |
非常抱歉,由于下面原因,网站出错了。
14 | 15 | 16 | 17 |