Skip to content

Commit 8efcd7c

Browse files
committed
修改gtc example服务地址&去掉token
1 parent 6127c03 commit 8efcd7c

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

examples/mapboxgl/GTC2017.html

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@
1111
<div class="loader loader-curtain"></div>
1212
<div id='map'></div>
1313
<script>
14-
mapboxgl.accessToken = 'pk.eyJ1IjoibWFwYm94IiwiYSI6ImNpejY4M29iazA2Z2gycXA4N2pmbDZmangifQ.-g_vE53SD2WrJ6tFX7QHmA';
15-
var iServerUrl = "http://117.122.248.69:8090/iserver/services/map-chongqing/rest/maps/chongqing3857/tileFeature.mvt?_cache=false&returnAttributes=true&compressTolerance=-1&width=512&height=512&viewBounds={bbox-epsg-3857}";
14+
var iServerUrl = "http://117.122.248.69:8090/iserver/services/map-city/rest/maps/city/tileFeature.mvt?_cache=false&returnAttributes=true&compressTolerance=-1&width=512&height=512&viewBounds={bbox-epsg-3857}";
1615

1716
var buildingLayer, heightField = "floor", ratio = 15, layerId = "buildings",
1817
center = [106.540545, 29.531714];
@@ -38,17 +37,17 @@
3837
map.on('load', function () {
3938
/*绿色风格*/
4039
mapboxgl.supermap.map.setBackground(map, "hsl(47, 26%, 88%)");
41-
mapboxgl.supermap.map.setPaintProperty(map, '水系多边形@chongqing', 'fill', {'fill-color': 'hsl(205, 56%, 73%)'});
42-
mapboxgl.supermap.map.setPaintProperty(map, '植被_多边形_R@chongqing', 'fill', {'fill-color': 'hsl(82, 46%, 72%)', 'fill-opacity': 0.4});
43-
mapboxgl.supermap.map.setPaintProperty(map, ['R_一级道路@chongqing', 'R_二级道路@chongqing'], 'line', {'line-color': '#fff', 'line-width': 2});
44-
mapboxgl.supermap.map.setPaintProperty(map, ['R_三级道路@chongqing', 'R_四级道路@chongqing'], 'line', {'line-color': 'hsl(0, 0%, 97%)', 'line-width': 1});
40+
mapboxgl.supermap.map.setPaintProperty(map, '水系多边形@city', 'fill', {'fill-color': 'hsl(205, 56%, 73%)'});
41+
mapboxgl.supermap.map.setPaintProperty(map, '植被_多边形_R@city', 'fill', {'fill-color': 'hsl(82, 46%, 72%)', 'fill-opacity': 0.4});
42+
mapboxgl.supermap.map.setPaintProperty(map, ['R_一级道路@city', 'R_二级道路@city'], 'line', {'line-color': '#fff', 'line-width': 2});
43+
mapboxgl.supermap.map.setPaintProperty(map, ['R_三级道路@city', 'R_四级道路@city'], 'line', {'line-color': 'hsl(0, 0%, 97%)', 'line-width': 1});
4544

4645
/*切换蓝色风格*/
4746
mapboxgl.supermap.map.setBackground(map, "#042133");
48-
mapboxgl.supermap.map.setPaintProperty(map, '水系多边形@chongqing', 'fill', {'fill-color': '#021019'});
49-
mapboxgl.supermap.map.setPaintProperty(map, '植被_多边形_R@chongqing', 'fill', {'fill-color': '#021019', 'fill-opacity': 0.4});
50-
mapboxgl.supermap.map.setPaintProperty(map, ['R_一级道路@chongqing', 'R_二级道路@chongqing'], 'line', {'line-color': '#021019', 'line-width': 2});
51-
mapboxgl.supermap.map.setPaintProperty(map, ['R_三级道路@chongqing', 'R_四级道路@chongqing'], 'line', {'line-color': '#021019', 'line-width': 1});
47+
mapboxgl.supermap.map.setPaintProperty(map, '水系多边形@city', 'fill', {'fill-color': '#021019'});
48+
mapboxgl.supermap.map.setPaintProperty(map, '植被_多边形_R@city', 'fill', {'fill-color': '#021019', 'fill-opacity': 0.4});
49+
mapboxgl.supermap.map.setPaintProperty(map, ['R_一级道路@city', 'R_二级道路@city'], 'line', {'line-color': '#021019', 'line-width': 2});
50+
mapboxgl.supermap.map.setPaintProperty(map, ['R_三级道路@city', 'R_四级道路@city'], 'line', {'line-color': '#021019', 'line-width': 1});
5251

5352
/*加载三维专题图*/
5453
buildingLayer = new mapboxgl.supermap.RankTheme3DLayer(layerId, map, {

0 commit comments

Comments
 (0)