pbootcms网站模板|日韩1区2区|织梦模板||网站源码|日韩1区2区|jquery建站特效-html5模板网

    1. <i id='yu3gc'><tr id='yu3gc'><dt id='yu3gc'><q id='yu3gc'><span id='yu3gc'><b id='yu3gc'><form id='yu3gc'><ins id='yu3gc'></ins><ul id='yu3gc'></ul><sub id='yu3gc'></sub></form><legend id='yu3gc'></legend><bdo id='yu3gc'><pre id='yu3gc'><center id='yu3gc'></center></pre></bdo></b><th id='yu3gc'></th></span></q></dt></tr></i><div class="3ftzxj5" id='yu3gc'><tfoot id='yu3gc'></tfoot><dl id='yu3gc'><fieldset id='yu3gc'></fieldset></dl></div>
    2. <legend id='yu3gc'><style id='yu3gc'><dir id='yu3gc'><q id='yu3gc'></q></dir></style></legend>
      <tfoot id='yu3gc'></tfoot>

      <small id='yu3gc'></small><noframes id='yu3gc'>

        • <bdo id='yu3gc'></bdo><ul id='yu3gc'></ul>
      1. 傳單:更新 GeoJson 過濾器?

        Leaflet: Update GeoJson filter?(傳單:更新 GeoJson 過濾器?)
        <legend id='7xdsR'><style id='7xdsR'><dir id='7xdsR'><q id='7xdsR'></q></dir></style></legend>

        <tfoot id='7xdsR'></tfoot>

          <i id='7xdsR'><tr id='7xdsR'><dt id='7xdsR'><q id='7xdsR'><span id='7xdsR'><b id='7xdsR'><form id='7xdsR'><ins id='7xdsR'></ins><ul id='7xdsR'></ul><sub id='7xdsR'></sub></form><legend id='7xdsR'></legend><bdo id='7xdsR'><pre id='7xdsR'><center id='7xdsR'></center></pre></bdo></b><th id='7xdsR'></th></span></q></dt></tr></i><div class="v7txnfb" id='7xdsR'><tfoot id='7xdsR'></tfoot><dl id='7xdsR'><fieldset id='7xdsR'></fieldset></dl></div>
            <tbody id='7xdsR'></tbody>

              <small id='7xdsR'></small><noframes id='7xdsR'>

                <bdo id='7xdsR'></bdo><ul id='7xdsR'></ul>
                • 本文介紹了傳單:更新 GeoJson 過濾器?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  我想用數據填充 GeoJson 層,然后動態過濾要顯示的特征.

                  I would like to populate a GeoJson layer with data and then dynamically filter what features to show.

                  我已經讓過濾器功能工作,但我不知道如何更改過濾器然后刷新圖層.

                  I have gotten the filter function to work but I do not know how to change the filter and then refresh the layer.

                  添加數據后有什么方法可以更新過濾器?

                  Is there any way I can update the filter after I have added the data?

                  推薦答案

                  我通過將每個功能類型添加到不同的 LayerGroup 基于特征的屬性.例如

                  I did this by adding each feature type to a different LayerGroup based on a property of the feature. e.g.

                  GeoJSON

                  var data =[
                    {
                     type: "Feature",
                     properties: {
                        type: "type1"
                     },
                     geometry: {
                        type: "Point",
                        coordinates: [-1.252,52.107]
                     }
                    },
                    {
                     type: "Feature",
                     properties: {
                        type: "type2"
                     },
                     geometry: {
                        type: "Point",
                        coordinates: [-2.252,54.107]
                     }
                    }
                  ];
                  

                  創建 GeoJSON 層

                  //array to store layers for each feature type
                  var mapLayerGroups = [];
                  
                  //draw GEOJSON - don't add the GEOJSON layer to the map here
                  L.geoJson(data, {onEachFeature: onEachFeature})//.addTo(map);
                  
                  /*
                   *for all features create a layerGroup for each feature type and add the feature to the    layerGroup
                  */
                  function onEachFeature(feature, featureLayer) {
                  
                      //does layerGroup already exist? if not create it and add to map
                      var lg = mapLayerGroups[feature.properties.type];
                  
                      if (lg === undefined) {
                          lg = new L.layerGroup();
                          //add the layer to the map
                          lg.addTo(map);
                          //store layer
                          mapLayerGroups[feature.properties.type] = lg;
                      }
                  
                      //add the feature to the layer
                      lg.addLayer(featureLayer);      
                  }
                  

                  然后您可以調用 Leaflet map.addLayer/removeLayer 函數,例如

                  Then you can call the Leaflet map.addLayer/removeLayer functions e.g.

                  //Show layerGroup with feature of "type1"
                  showLayer("type1");
                  
                  /*
                  * show/hide layerGroup   
                  */
                  function showLayer(id) {
                      var lg = mapLayerGroups[id];
                      map.addLayer(lg);   
                  }
                  function hideLayer(id) {
                      var lg = mapLayerGroups[id];
                      map.removeLayer(lg);   
                  }
                  

                  這篇關于傳單:更新 GeoJson 過濾器?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  Check if a polygon point is inside another in leaflet(檢查一個多邊形點是否在傳單中的另一個內部)
                  Changing leaflet markercluster icon color, inheriting the rest of the default CSS properties(更改傳單標記群集圖標顏色,繼承其余默認 CSS 屬性)
                  Trigger click on leaflet marker(觸發點擊傳單標記)
                  How can I change the default loading tile color in LeafletJS?(如何更改 LeafletJS 中的默認加載磁貼顏色?)
                  Add external geojson to leaflet layer(將外部geojson添加到傳單層)
                  Adding Leaflet layer control to sidebar(將 Leaflet 圖層控件添加到側邊欄)

                    <bdo id='xe3GL'></bdo><ul id='xe3GL'></ul>

                      1. <tfoot id='xe3GL'></tfoot>
                        <legend id='xe3GL'><style id='xe3GL'><dir id='xe3GL'><q id='xe3GL'></q></dir></style></legend>
                        <i id='xe3GL'><tr id='xe3GL'><dt id='xe3GL'><q id='xe3GL'><span id='xe3GL'><b id='xe3GL'><form id='xe3GL'><ins id='xe3GL'></ins><ul id='xe3GL'></ul><sub id='xe3GL'></sub></form><legend id='xe3GL'></legend><bdo id='xe3GL'><pre id='xe3GL'><center id='xe3GL'></center></pre></bdo></b><th id='xe3GL'></th></span></q></dt></tr></i><div class="npx9ttz" id='xe3GL'><tfoot id='xe3GL'></tfoot><dl id='xe3GL'><fieldset id='xe3GL'></fieldset></dl></div>

                            <small id='xe3GL'></small><noframes id='xe3GL'>

                              <tbody id='xe3GL'></tbody>
                            主站蜘蛛池模板: 利浦顿蒸汽发生器厂家-电蒸汽发生器/燃气蒸汽发生器_湖北利浦顿热能科技有限公司官网 | HDPE土工膜,复合土工膜,防渗膜价格,土工膜厂家-山东新路通工程材料有限公司 | 桨叶搅拌机_螺旋挤压/方盒旋切造粒机厂家-无锡市鸿诚输送机械有限公司 | 不锈钢管件(不锈钢弯头,不锈钢三通,不锈钢大小头),不锈钢法兰「厂家」-浙江志通管阀 | 维泰克Veertek-锂电池微短路检测_锂电池腐蚀检测_锂电池漏液检测 | 吸污车_吸粪车_抽粪车_电动三轮吸粪车_真空吸污车_高压清洗吸污车-远大汽车制造有限公司 | 河南膏药贴牌-膏药代加工-膏药oem厂家-洛阳今世康医药科技有限公司 | 工业洗衣机_工业洗涤设备_上海力净工业洗衣机厂家-洗涤设备首页 bkzzy在职研究生网 - 在职研究生招生信息咨询平台 | 青岛空压机,青岛空压机维修/保养,青岛空压机销售/出租公司,青岛空压机厂家电话 | 上海洗地机-洗地机厂家-全自动洗地机-手推式洗地机-上海滢皓洗地机 | 武汉创亿电气设备有限公司_电力检测设备生产厂家 | 珠海冷却塔降噪维修_冷却塔改造报价_凉水塔风机维修厂家- 广东康明节能空调有限公司 | 亿立分板机_曲线_锯片式_走刀_在线式全自动_铣刀_在线V槽分板机-杭州亿协智能装备有限公司 | 道达尔润滑油-食品级润滑油-道达尔导热油-合成导热油,深圳道达尔代理商合-深圳浩方正大官网 | 小区健身器材_户外健身器材_室外健身器材_公园健身路径-沧州浩然体育器材有限公司 | 沟盖板_复合沟盖板厂_电力盖板_树脂雨水篦子-淄博拜斯特 | 彼得逊采泥器-定深式采泥器-电动土壤采样器-土壤样品风干机-常州索奥仪器制造有限公司 | 车间除尘设备,VOCs废气处理,工业涂装流水线,伸缩式喷漆房,自动喷砂房,沸石转轮浓缩吸附,机器人喷粉线-山东创杰智慧 | 悬浮拼装地板_篮球场木地板翻新_运动木地板价格-上海越禾运动地板厂家 | 不锈钢复合板厂家_钛钢复合板批发_铜铝复合板供应-威海泓方金属复合材料股份有限公司 | 探鸣起名网-品牌起名-英文商标起名-公司命名-企业取名包满意 | 圆窗水平仪|伊莉莎冈特elesa+ganter | 空压机商城|空气压缩机|空压机配件-压缩机网旗下商城 | 洗石机-移动滚筒式,振动,螺旋,洗矿机-青州冠诚重工机械有限公司 | 铝板冲孔网,不锈钢冲孔网,圆孔冲孔网板,鳄鱼嘴-鱼眼防滑板,盾构走道板-江拓数控冲孔网厂-河北江拓丝网有限公司 | 全温恒温摇床-水浴气浴恒温摇床-光照恒温培养摇床-常州金坛精达仪器制造有限公司 | 黑龙江京科脑康医院-哈尔滨精神病医院哪家好_哈尔滨精神科医院排名_黑龙江精神心理病专科医院 | 盛源真空泵|空压机-浙江盛源空压机制造有限公司-【盛源官网】 | 热处理炉-退火炉-回火炉设备厂家-丹阳市电炉厂有限公司 | 钢托盘,钢制托盘,立库钢托盘,金属托盘制造商_南京飞天金属制品实业有限公司 | RO反渗透设备_厂家_价格_河南郑州江宇环保科技有限公司 | 斗式提升机,斗式提升机厂家-淄博宏建机械有限公司 | 暖气片十大品牌厂家_铜铝复合暖气片厂家_暖气片什么牌子好_欣鑫达散热器 | 双舌接地线-PC68数字式高阻计-ZC36|苏海百科 | 数显恒温油浴-电砂浴-高温油浴振荡器-常州迈科诺仪器有限公司 | 三板富 | 专注于新三板的第一垂直服务平台| 首页|专注深圳注册公司,代理记账报税,注册商标代理,工商变更,企业400电话等企业一站式服务-慧用心 | 外贮压-柜式-悬挂式-七氟丙烷-灭火器-灭火系统-药剂-价格-厂家-IG541-混合气体-贮压-非贮压-超细干粉-自动-灭火装置-气体灭火设备-探火管灭火厂家-东莞汇建消防科技有限公司 | 硫化罐_蒸汽硫化罐_大型硫化罐-山东鑫泰鑫智能装备有限公司 | 电梯装饰-北京万达中意电梯装饰有限公司 | CPSE安博会 |