@kq_npm/client3d_webgl_vue 0.0.9-beta → 0.1.1-beta

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/_libs/ol/ol.js +65 -5
  2. package/adddata/index.js +2 -2
  3. package/adddata/style/adddata.css +1 -1
  4. package/baseterraingallery/style/baseterraingallery.css +1 -1
  5. package/boxclip/style/boxclip.css +1 -1
  6. package/comparemap/index.js +22 -4
  7. package/excavatefillanalysis/style/excavatefillanalysis.css +1 -1
  8. package/flight/index.js +3 -1
  9. package/flight/style/flight.css +1 -1
  10. package/floodanalysis/index.js +30 -4
  11. package/floodanalysis/style/floodanalysis.css +1 -1
  12. package/gpuspatialquery/style/gpuspatialquery.css +1 -1
  13. package/index.js +267 -95
  14. package/isolineanalysis/index.js +72 -36
  15. package/isolineanalysis/style/isolineanalysis.css +1 -1
  16. package/measure/index.js +3 -1
  17. package/measure/style/measure.css +1 -1
  18. package/modelselect/style/modelselect.css +1 -1
  19. package/package.json +1 -1
  20. package/particleeffect/style/particleeffect.css +1 -1
  21. package/planeclip/style/planeclip.css +1 -1
  22. package/profileanalysis/style/profileanalysis.css +1 -1
  23. package/roller/style/roller.css +1 -1
  24. package/scenceview/index.js +109 -45
  25. package/screenshot/style/screenshot.css +1 -1
  26. package/shadowanalysis/style/shadowanalysis.css +1 -1
  27. package/sightlineanalysis/style/sightlineanalysis.css +1 -1
  28. package/skylineanalysis/style/skylineanalysis.css +1 -1
  29. package/slopeanalysis/index.js +28 -4
  30. package/slopeanalysis/style/slopeanalysis.css +1 -1
  31. package/style.css +1 -1
  32. package/terrainoperation/style/terrainoperation.css +1 -1
  33. package/viewshedanalysis/style/viewshedanalysis.css +1 -1
  34. package/weathereffect/style/weathereffect.css +1 -1
package/index.js CHANGED
@@ -923,8 +923,8 @@ class LayerManager {
923
923
  //图层树数据
924
924
  //图层列表数据(不包含文件夹节点,不包含融合子图层),特殊图层数据(BaseLayer、OnLineLayer)除外
925
925
  //图层原数据列表(包含文件夹节点,融合子图层)
926
- //影像图层guid集合
927
926
  //置顶图层guid
927
+ //记录置顶图层index
928
928
  //地形集合
929
929
  constructor(scenceView) {
930
930
  _defineProperty(this, "_scenceView", null);
@@ -937,10 +937,10 @@ class LayerManager {
937
937
 
938
938
  _defineProperty(this, "_layerListData_old", []);
939
939
 
940
- _defineProperty(this, "_imageryLayerGuids", []);
941
-
942
940
  _defineProperty(this, "_frontLayerGuid", null);
943
941
 
942
+ _defineProperty(this, "_frontLayerIndex", null);
943
+
944
944
  _defineProperty(this, "_emptyTerrainProvider", new Cesium.EllipsoidTerrainProvider({}));
945
945
 
946
946
  _defineProperty(this, "_terrainProviders", []);
@@ -1005,9 +1005,8 @@ class LayerManager {
1005
1005
 
1006
1006
  that._viewer.imageryLayers.add(imageryLayer);
1007
1007
  }
1008
-
1009
- that._imageryLayerGuids.push(layer.guid);
1010
1008
  });
1009
+ that.recordImageryLayerOriginIndex();
1011
1010
 
1012
1011
  if (rect) {
1013
1012
  that._viewer.camera.flyTo({
@@ -1078,6 +1077,8 @@ class LayerManager {
1078
1077
  } else if (visible) {
1079
1078
  //如果不存在该图层则添加
1080
1079
  if (this._layerListData[i].serverType === "kqserver") {
1080
+ //添加图层之前重置图层顺序
1081
+ this.resetLayerIndex();
1081
1082
  var imageryProvider = new Cesium.Kq3dKQGISMapServerImageryProviderExt({
1082
1083
  url: this._layerListData[i].url,
1083
1084
  ua_token: this._layerListData[i].accessToken,
@@ -1085,8 +1086,15 @@ class LayerManager {
1085
1086
  });
1086
1087
  var imageryLayer = new Cesium.ImageryLayer(imageryProvider);
1087
1088
  imageryLayer.name = this._layerListData[i].guid;
1089
+ var addIndex = this.getImageryLayerAddIndex(ids[z]);
1090
+
1091
+ if (addIndex > -1) {
1092
+ this._viewer.imageryLayers.add(imageryLayer, addIndex);
1093
+ } else {
1094
+ this._viewer.imageryLayers.add(imageryLayer);
1095
+ }
1088
1096
 
1089
- this._viewer.imageryLayers.add(imageryLayer);
1097
+ this.recordImageryLayerOriginIndex();
1090
1098
  }
1091
1099
  }
1092
1100
  }
@@ -1097,27 +1105,68 @@ class LayerManager {
1097
1105
 
1098
1106
  getImageryLayerAddIndex(guid) {
1099
1107
  let layers = [];
1100
- let layerListIndex = -1;
1101
- let data = this._layerListData; //从_layerListData中找出所有ImageryLayer图层
1108
+ let layerIndex = -1;
1109
+ let layerAddIndex = -1; //从_layerListData中找出所有ImageryLayer图层
1102
1110
 
1103
- data.forEach((layer, index) => {
1111
+ this._layerListData.forEach(layer => {
1104
1112
  if (layer.serverType === "kqserver" || layer.serverType === "imagerylayer") {
1105
1113
  layers.push(layer);
1106
1114
 
1107
1115
  if (layer.guid === guid) {
1108
- layerListIndex = index;
1116
+ layerIndex = layers.length - 1;
1109
1117
  }
1110
1118
  }
1111
1119
  });
1112
1120
 
1113
- if (layerListIndex > -1) {
1114
- //搜索左边相邻显示的图层
1115
- let isLeftLayerShow = false;
1121
+ if (layerIndex > -1) {
1122
+ var isLeftShow = false;
1123
+ var adjacentLayerShowIndex = -1; //搜索左边相邻显示的图层
1116
1124
 
1117
- for (var i = layerListIndex - 1; i >= 0; i--) {
1118
- if (data[i].visible) {}
1125
+ for (var i = layerIndex - 1; i >= 0; i--) {
1126
+ if (layers[i].visible) {
1127
+ adjacentLayerShowIndex = i;
1128
+ isLeftShow = true;
1129
+ break;
1130
+ }
1131
+ }
1132
+
1133
+ if (adjacentLayerShowIndex === -1) {
1134
+ //搜索右边相邻显示的图层
1135
+ for (var j = layerIndex + 1; j < layers.length; j++) {
1136
+ if (layers[j].visible) {
1137
+ adjacentLayerShowIndex = j;
1138
+ break;
1139
+ }
1140
+ }
1141
+ }
1142
+
1143
+ if (adjacentLayerShowIndex > -1) {
1144
+ var adjacentLayer = this.getLayerByGuid(layers[adjacentLayerShowIndex].guid);
1145
+
1146
+ if (adjacentLayer) {
1147
+ var adjacentLayerIndex = adjacentLayer._layerIndex;
1148
+
1149
+ if (isLeftShow) {
1150
+ layerAddIndex = adjacentLayerIndex + 1;
1151
+ } else {
1152
+ if (this.getBaseLayerIndex() === adjacentLayerIndex) {
1153
+ layerAddIndex = adjacentLayerIndex;
1154
+ } else {
1155
+ layerAddIndex = adjacentLayerIndex - 1;
1156
+ }
1157
+ }
1158
+ }
1119
1159
  }
1120
1160
  }
1161
+
1162
+ return layerAddIndex;
1163
+ } //记录ImageryLayer原始index
1164
+
1165
+
1166
+ recordImageryLayerOriginIndex() {
1167
+ this._viewer.imageryLayers._layers.forEach(layer => {
1168
+ layer._originIndex = layer._layerIndex;
1169
+ });
1121
1170
  } //通过guid获取图层对象
1122
1171
 
1123
1172
 
@@ -1291,15 +1340,6 @@ class LayerManager {
1291
1340
  // });
1292
1341
  // return baseIndex;
1293
1342
  return 1;
1294
- } //获取图层原始Index
1295
-
1296
-
1297
- getLayerOldIndex(guid) {
1298
- let baseIndex = this.getBaseLayerIndex();
1299
-
1300
- let layerIndex = this._imageryLayerGuids.indexOf(guid);
1301
-
1302
- return baseIndex + layerIndex;
1303
1343
  } //设置图层置顶或取消置顶
1304
1344
 
1305
1345
 
@@ -1314,34 +1354,40 @@ class LayerManager {
1314
1354
  if (this._frontLayerGuid) {
1315
1355
  // 如果已经有置顶图层 先把已经置顶的图层还原 再继续操作
1316
1356
  let frontLayer = this.getLayerByGuid(this._frontLayerGuid);
1317
- let frontOldIndex = this.getLayerOldIndex(this._frontLayerGuid);
1318
- var length = frontLayer._layerIndex - frontOldIndex;
1319
1357
 
1320
- for (let i = 0; i < length; i++) {
1321
- if (frontLayer instanceof Cesium.ImageryLayer) {
1322
- this._viewer.imageryLayers.lower(frontLayer);
1358
+ if (this._frontLayerIndex !== null) {
1359
+ var length = frontLayer._layerIndex - this._frontLayerIndex;
1360
+
1361
+ for (let i = 0; i < length; i++) {
1362
+ if (frontLayer instanceof Cesium.ImageryLayer) {
1363
+ this._viewer.imageryLayers.lower(frontLayer);
1364
+ }
1323
1365
  }
1324
1366
  }
1325
1367
  }
1326
1368
 
1327
1369
  if (layer instanceof Cesium.ImageryLayer) {
1370
+ this._frontLayerGuid = guid;
1371
+ this._frontLayerIndex = layer._layerIndex;
1372
+
1328
1373
  this._viewer.imageryLayers.raiseToTop(layer);
1329
1374
  }
1330
-
1331
- this._frontLayerGuid = guid;
1332
1375
  } else {
1333
1376
  //取消置顶
1334
1377
  if (this._frontLayerGuid !== guid) return;
1335
- let oldIndex = this.getLayerOldIndex(guid);
1336
- let length = layer._layerIndex - oldIndex;
1337
1378
 
1338
- for (let j = 0; j < length; j++) {
1339
- if (layer instanceof Cesium.ImageryLayer) {
1340
- this._viewer.imageryLayers.lower(layer);
1379
+ if (this._frontLayerIndex !== null) {
1380
+ let length = layer._layerIndex - this._frontLayerIndex;
1381
+
1382
+ for (let j = 0; j < length; j++) {
1383
+ if (layer instanceof Cesium.ImageryLayer) {
1384
+ this._viewer.imageryLayers.lower(layer);
1385
+ }
1341
1386
  }
1342
1387
  }
1343
1388
 
1344
1389
  this._frontLayerGuid = null;
1390
+ this._frontLayerIndex = null;
1345
1391
  }
1346
1392
  }
1347
1393
  } //图层上移
@@ -1370,18 +1416,30 @@ class LayerManager {
1370
1416
 
1371
1417
 
1372
1418
  resetLayerIndex() {
1373
- let that = this;
1374
- let oldIndex, layer; //重置影像图层顺序
1419
+ this._layerListData.forEach(layer => {
1420
+ if (layer.serverType === "kqserver" || layer.serverType === "imagerylayer") {
1421
+ var imageryLayer = this.getLayerByGuid(layer.guid);
1375
1422
 
1376
- that._imageryLayerGuids.forEach(guid => {
1377
- oldIndex = that.getLayerOldIndex(guid);
1378
- layer = that.getLayerByGuid(guid);
1379
- let length = layer._layerIndex - oldIndex;
1423
+ if (imageryLayer) {
1424
+ if (imageryLayer._layerIndex > imageryLayer._originIndex) {
1425
+ var length = imageryLayer._layerIndex - imageryLayer._originIndex;
1380
1426
 
1381
- for (let j = 0; j < length; j++) {
1382
- that._viewer.imageryLayers.lower(layer);
1427
+ for (var i = 0; i < length; i++) {
1428
+ this._viewer.imageryLayers.lower(imageryLayer);
1429
+ }
1430
+ } else if (imageryLayer._layerIndex < imageryLayer._originIndex) {
1431
+ var length = imageryLayer._originIndex - imageryLayer._layerIndex;
1432
+
1433
+ for (var j = 0; j < length; j++) {
1434
+ this._viewer.imageryLayers.raise(imageryLayer);
1435
+ }
1436
+ }
1437
+ }
1383
1438
  }
1384
- });
1439
+ }, this);
1440
+
1441
+ this._frontLayerGuid = null;
1442
+ this._frontLayerIndex = null;
1385
1443
  } //设置图层透明度
1386
1444
 
1387
1445
 
@@ -1430,6 +1488,12 @@ class LayerManager {
1430
1488
  }
1431
1489
  }
1432
1490
 
1491
+ if (layer.serverType === "imagerylayer") {
1492
+ this._viewer.imageryLayers._layers.forEach(layer => {
1493
+ if (!layer._originIndex) layer._originIndex = layer._layerIndex;
1494
+ });
1495
+ }
1496
+
1433
1497
  this._scenceView.fire("resetLayerDatas");
1434
1498
  } //设置地形
1435
1499
 
@@ -2809,7 +2873,9 @@ const Measurevue_type_script_setup_true_lang_js_default_ = {
2809
2873
  const _component_kq_divider = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.resolveComponent)("kq-divider");
2810
2874
 
2811
2875
  return (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createElementBlock)("section", {
2812
- class: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.normalizeClass)(["kq-measure3d", __props.showShadow ? 'shadow' : null])
2876
+ class: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.normalizeClass)(["kq-measure3d", {
2877
+ 'kq-shadow': __props.showShadow
2878
+ }])
2813
2879
  }, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createElementVNode)("div", Measurevue_type_script_setup_true_lang_js_hoisted_1, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createElementVNode)("div", Measurevue_type_script_setup_true_lang_js_hoisted_2, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createElementVNode)("p", Measurevue_type_script_setup_true_lang_js_hoisted_3, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(language).mode), 1
2814
2880
  /* TEXT */
2815
2881
  ), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createVNode)(_component_kq_select, {
@@ -3427,7 +3493,9 @@ const Flightvue_type_script_setup_true_lang_js_default_ = {
3427
3493
  const _component_kq_divider = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.resolveComponent)("kq-divider");
3428
3494
 
3429
3495
  return (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createElementBlock)("section", {
3430
- class: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.normalizeClass)(["kq-flight3d", __props.showShadow ? 'shadow' : null])
3496
+ class: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.normalizeClass)(["kq-flight3d", {
3497
+ 'kq-shadow': __props.showShadow
3498
+ }])
3431
3499
  }, [!(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(isAdd) ? ((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createElementBlock)("div", Flightvue_type_script_setup_true_lang_js_hoisted_1, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createElementVNode)("div", Flightvue_type_script_setup_true_lang_js_hoisted_2, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createVNode)(_component_kq_button, {
3432
3500
  onClick: addPath,
3433
3501
  title: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(language).addPath
@@ -9378,7 +9446,8 @@ ExcavateFillAnalysis.install = (Vue, opts) => {
9378
9446
 
9379
9447
  ;// CONCATENATED MODULE: ./src/webgl/floodanalysis/FloodAnalysisViewModel.js
9380
9448
 
9381
- //地形淹没分析逻辑类
9449
+ //地形淹没分析逻辑类
9450
+
9382
9451
  class FloodAnalysisViewModel {
9383
9452
  //地形淹没
9384
9453
  //模型淹没
@@ -9393,9 +9462,21 @@ class FloodAnalysisViewModel {
9393
9462
 
9394
9463
  _defineProperty(this, "_mode", 0);
9395
9464
 
9465
+ _defineProperty(this, "_colorImages", [{
9466
+ value: "0",
9467
+ src: const_image_namespaceObject.RED_TO_PURPLE_URL
9468
+ }, {
9469
+ value: "1",
9470
+ src: const_image_namespaceObject.PURPLE_TO_YELLOW_URL
9471
+ }, {
9472
+ value: "2",
9473
+ src: const_image_namespaceObject.GREEN_TO_BLUE_URL
9474
+ }]);
9475
+
9396
9476
  options.viewer = scenceView._viewer;
9397
9477
  options.viewer.scene.globe.depthTestAgainstTerrain = true;
9398
9478
  this._mode = options.mode;
9479
+ options.colorImage = this.getImagePath(options.colorImage);
9399
9480
  this._floodModelAnalysis = new Cesium.Kq3dFloodModelAnalysis(options);
9400
9481
  var that = this;
9401
9482
  this._measureHandler = new Cesium.Kq3dMeasureHandler(scenceView._viewer, {
@@ -9438,6 +9519,19 @@ class FloodAnalysisViewModel {
9438
9519
  }
9439
9520
  }
9440
9521
  });
9522
+ } //获取图片路径
9523
+
9524
+
9525
+ getImagePath(value) {
9526
+ var imagePath = '';
9527
+
9528
+ var image = this._colorImages.find(item => item.value === value);
9529
+
9530
+ if (image) {
9531
+ imagePath = image.src;
9532
+ }
9533
+
9534
+ return imagePath;
9441
9535
  } //开始分析
9442
9536
 
9443
9537
 
@@ -9593,7 +9687,7 @@ const FloodAnalysisvue_type_script_setup_true_lang_js_default_ = {
9593
9687
  alpha: formItem.floodAlpha,
9594
9688
  minHeight: formItem.floodMinHeight,
9595
9689
  maxHeight: formItem.floodMaxHeight,
9596
- colorImage: getImagePath(formItem.floodColorImage)
9690
+ colorImage: formItem.floodColorImage
9597
9691
  };
9598
9692
  viewModel = new FloodAnalysisViewModel(scenceView, options);
9599
9693
  }
@@ -10131,6 +10225,17 @@ class SlopeAnalysisViewModel {
10131
10225
 
10132
10226
  _defineProperty(this, "_defaultPositions", [new Cesium.Cartesian3(320344.97912128427, 5634145.630522612, 2962308.690344629), new Cesium.Cartesian3(324448.6451820951, 5639835.805638826, 2951088.4423702545), new Cesium.Cartesian3(320344.97912128427, 5634145.630522612, 2962308.690344629)]);
10133
10227
 
10228
+ _defineProperty(this, "_colorImages", [{
10229
+ value: "0",
10230
+ src: const_image_namespaceObject.RED_TO_PURPLE_URL
10231
+ }, {
10232
+ value: "1",
10233
+ src: const_image_namespaceObject.PURPLE_TO_YELLOW_URL
10234
+ }, {
10235
+ value: "2",
10236
+ src: const_image_namespaceObject.GREEN_TO_BLUE_URL
10237
+ }]);
10238
+
10134
10239
  this._globaOptions.viewer = scenceView._viewer;
10135
10240
  this._globaOptions.viewModel = {
10136
10241
  fillStyle: viewModel.fillStyle,
@@ -10145,7 +10250,8 @@ class SlopeAnalysisViewModel {
10145
10250
  minSlope: viewModel.minSlope,
10146
10251
  maxSlope: viewModel.maxSlope,
10147
10252
  slopeColorText: viewModel.slopeColorText,
10148
- slopeColorAlpha: viewModel.slopeColorAlpha
10253
+ slopeColorAlpha: viewModel.slopeColorAlpha,
10254
+ colorImage: this.getImagePath(viewModel.colorImage)
10149
10255
  };
10150
10256
  this._globaOptions.viewer.scene.globe.depthTestAgainstTerrain = true; //开启深度检测
10151
10257
 
@@ -10195,6 +10301,19 @@ class SlopeAnalysisViewModel {
10195
10301
  that._globaOptions._drawManager.clear();
10196
10302
  }
10197
10303
  });
10304
+ } //获取图片路径
10305
+
10306
+
10307
+ getImagePath(value) {
10308
+ var imagePath = '';
10309
+
10310
+ var image = this._colorImages.find(item => item.value === value);
10311
+
10312
+ if (image) {
10313
+ imagePath = image.src;
10314
+ }
10315
+
10316
+ return imagePath;
10198
10317
  } // 开始分析
10199
10318
 
10200
10319
 
@@ -10439,9 +10558,8 @@ const SlopeAnalysisvue_type_script_setup_true_lang_js_default_ = {
10439
10558
  if (scenceView) {
10440
10559
  language.value = scenceView._language;
10441
10560
  refactorArr();
10442
- viewModel = new SlopeAnalysisViewModel(scenceView, formItem);
10443
- var imageUrl = getImagePath(formItem.colorImage);
10444
- viewModel.setColorImage(imageUrl);
10561
+ viewModel = new SlopeAnalysisViewModel(scenceView, formItem); // var imageUrl = getImagePath(formItem.colorImage);
10562
+ // viewModel.setColorImage(imageUrl);
10445
10563
  }
10446
10564
  });
10447
10565
  }); // 刷新自定义样式数组
@@ -11086,16 +11204,45 @@ class IsolineAnalysisViewModel {
11086
11204
 
11087
11205
  _defineProperty(this, "_surfaceLineColorTable", ["#2a2828", "#2747E0", "#D33B7D", "#D33038", "#FF9742"]);
11088
11206
 
11207
+ _defineProperty(this, "_colorImages", [{
11208
+ value: 0,
11209
+ src: const_image_namespaceObject.RED_TO_PURPLE_URL
11210
+ }, {
11211
+ value: 1,
11212
+ src: const_image_namespaceObject.PURPLE_TO_YELLOW_URL
11213
+ }, {
11214
+ value: 2,
11215
+ src: const_image_namespaceObject.GREEN_TO_BLUE_URL
11216
+ }]);
11217
+
11089
11218
  _defineProperty(this, "_options", null);
11090
11219
 
11091
11220
  this._options = options;
11092
11221
  this._options.viewer = scenceView._viewer;
11093
- this._options.viewer.scene.globe.depthTestAgainstTerrain = true; // scenceView._viewer.imageryLayers.addImageryProvider(new Cesium.SingleTileImageryProvider({
11222
+ this._options.viewer.scene.globe.depthTestAgainstTerrain = true;
11223
+ this._options.colorImage = this.getImagePath(this._options.colorImage);
11224
+
11225
+ if (options.firstCurve.color) {
11226
+ options.firstCurve.color = Cesium.Color.fromCssColorString(options.firstCurve.color);
11227
+ }
11228
+
11229
+ if (options.rememberCurve.color) {
11230
+ options.rememberCurve.color = Cesium.Color.fromCssColorString(options.rememberCurve.color);
11231
+ }
11232
+
11233
+ if (options.timeCurve.color) {
11234
+ options.timeCurve.color = Cesium.Color.fromCssColorString(options.timeCurve.color);
11235
+ }
11236
+
11237
+ if (options.helpCurve.color) {
11238
+ options.helpCurve.color = Cesium.Color.fromCssColorString(options.helpCurve.color);
11239
+ } // scenceView._viewer.imageryLayers.addImageryProvider(new Cesium.SingleTileImageryProvider({
11094
11240
  // url: './images/5e1e7ff00b274.jpg"'
11095
11241
  // }));
11096
11242
  // options.positions = Cesium.Cartesian3.fromDegreesArray([86.207634, 28.056729, 86.102906, 28.00936, 86.08717, 27.91235, 86.125613, 27.819748, 86.198224, 27.795282, 86.296004, 27.781972, 86.350588, 27.789578, 86.392595, 27.844577, 86.45492, 27.953339, 86.447793, 28.072028, 86.391228, 28.124686, 86.307634, 28.121425, 86.224272, 28.086173, 86.207, 28.062356, 86.206765, 28.062273]);
11097
11243
  // this._elevation = new Cesium.Kq3dContourAnalysis(options);
11098
11244
 
11245
+
11099
11246
  this._drawManager = scenceView._drawManager;
11100
11247
  } // 设置等高面区间
11101
11248
 
@@ -11142,6 +11289,19 @@ class IsolineAnalysisViewModel {
11142
11289
  this._elevation.colorImage = this._surfaceColorImage;
11143
11290
  break;
11144
11291
  }
11292
+ } //获取图片路径
11293
+
11294
+
11295
+ getImagePath(value) {
11296
+ var imagePath = "";
11297
+
11298
+ var image = this._colorImages.find(item => item.value === value);
11299
+
11300
+ if (image) {
11301
+ imagePath = image.src;
11302
+ }
11303
+
11304
+ return imagePath;
11145
11305
  } //修改填充图片
11146
11306
 
11147
11307
 
@@ -11149,24 +11309,16 @@ class IsolineAnalysisViewModel {
11149
11309
  var path = "";
11150
11310
 
11151
11311
  switch (value) {
11152
- case 1:
11312
+ case 0:
11153
11313
  path = const_image_namespaceObject.RED_TO_PURPLE_URL;
11154
11314
  break;
11155
11315
 
11156
- case 2:
11157
- path = const_image_namespaceObject.PURPLE_TO_YELLOW_URL;
11158
- break;
11159
-
11160
- case 3:
11161
- path = const_image_namespaceObject.PURPLE_TO_YELLOW_URL;
11162
- break;
11163
-
11164
- case 4:
11316
+ case 1:
11165
11317
  path = const_image_namespaceObject.PURPLE_TO_YELLOW_URL;
11166
11318
  break;
11167
11319
 
11168
- default:
11169
- path = const_image_namespaceObject.PURPLE_TO_YELLOW_URL;
11320
+ case 2:
11321
+ path = const_image_namespaceObject.GREEN_TO_BLUE_URL;
11170
11322
  break;
11171
11323
  }
11172
11324
 
@@ -11219,6 +11371,20 @@ class IsolineAnalysisViewModel {
11219
11371
 
11220
11372
  that._drawManager.clear();
11221
11373
 
11374
+ switch (that._options.filltype) {
11375
+ case 0:
11376
+ that._options.type = Cesium.Kq3dContourAnalysisType.LINE;
11377
+ break;
11378
+
11379
+ case 1:
11380
+ that._options.type = Cesium.Kq3dContourAnalysisType.SURFACE;
11381
+ break;
11382
+
11383
+ case 2:
11384
+ that._options.type = Cesium.Kq3dContourAnalysisType.SUFACE_LINE;
11385
+ break;
11386
+ }
11387
+
11222
11388
  that._elevation = new Cesium.Kq3dContourAnalysis(that._options);
11223
11389
  }
11224
11390
  });
@@ -11453,13 +11619,13 @@ const IsolineAnalysisvue_type_script_setup_true_lang_js_default_ = {
11453
11619
  colorTable: "#FF0000"
11454
11620
  }]);
11455
11621
  const colorImages = [{
11456
- value: 0,
11622
+ value: "0",
11457
11623
  src: const_image_namespaceObject.RED_TO_PURPLE_URL
11458
11624
  }, {
11459
- value: 1,
11625
+ value: "1",
11460
11626
  src: const_image_namespaceObject.PURPLE_TO_YELLOW_URL
11461
11627
  }, {
11462
- value: 2,
11628
+ value: "2",
11463
11629
  src: const_image_namespaceObject.GREEN_TO_BLUE_URL
11464
11630
  }];
11465
11631
  let activeName = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.ref)("line"); // 获取组件传参
@@ -11497,46 +11663,34 @@ const IsolineAnalysisvue_type_script_setup_true_lang_js_default_ = {
11497
11663
  minHeight: formItem.minHeight,
11498
11664
  maxHeight: formItem.maxHeight,
11499
11665
  spaceing: 600,
11500
- width: 2.0,
11501
- colorLabel: "#ffff00",
11502
- color: Cesium.Color.fromCssColorString("#ffff00"),
11503
- filltype: formItem.filltype,
11504
- type: Cesium.Kq3dContourAnalysisType.LINE,
11666
+ filltype: formItem.fillType,
11667
+ fillStyle: formItem.fillStyle,
11505
11668
  colorTableValue: [0.0, 0.1, 0.2, 0.3, 0.4],
11506
11669
  colorTable: formItem.colorTable,
11507
- firstCurveText: "#ffff00",
11508
- rememberCurveText: "#ffff00",
11509
- timeCurveText: "#00ff00",
11510
- helpCurveText: "#0000ff",
11511
- firstCurveWidth: 2,
11512
- rememberCurveWidth: 4,
11513
- timeCurveWidth: 1,
11514
- helpCurveWidth: 1,
11515
11670
  firstCurve: {
11516
- color: Cesium.Color.fromCssColorString(formItem.firstCurveColor),
11671
+ color: formItem.firstCurveColor,
11517
11672
  show: formItem.firstCurve,
11518
11673
  width: formItem.firstCurveWidth
11519
11674
  },
11520
11675
  rememberCurve: {
11521
- color: Cesium.Color.fromCssColorString(formItem.rememberCurveColor),
11676
+ color: formItem.rememberCurveColor,
11522
11677
  show: formItem.rememberCurve,
11523
11678
  width: formItem.rememberCurveWidth
11524
11679
  },
11525
11680
  timeCurve: {
11526
- color: Cesium.Color.fromCssColorString(formItem.intervalCurveColor),
11681
+ color: formItem.intervalCurveColor,
11527
11682
  show: formItem.intervalCurve,
11528
11683
  width: formItem.intervalCurveWidth
11529
11684
  },
11530
11685
  helpCurve: {
11531
- color: Cesium.Color.fromCssColorString(formItem.extraCurveColor),
11686
+ color: formItem.extraCurveColor,
11532
11687
  show: formItem.extraCurve,
11533
11688
  width: formItem.extraCurveWidth
11534
11689
  },
11535
- surfaceAlpha: formItem.surfaceAlpha
11690
+ surfaceAlpha: formItem.surfaceAlpha,
11691
+ colorImage: formItem.colorImage
11536
11692
  };
11537
11693
  viewModel = new IsolineAnalysisViewModel(scenceView, options);
11538
- var imageUrl = getImagePath(formItem.colorImage);
11539
- viewModel.setFillStyleImage(imageUrl);
11540
11694
  }
11541
11695
  });
11542
11696
  }); // 刷新自定义样式数组
@@ -15618,8 +15772,7 @@ class AddDataViewModel {
15618
15772
  });
15619
15773
  imageryLayer.name = layer.guid;
15620
15774
 
15621
- this._viewer.imageryLayers.add(imageryLayer); //this._layerManager._imageryLayerGuids.push(layer.guid);
15622
-
15775
+ this._viewer.imageryLayers.add(imageryLayer);
15623
15776
  }, this);
15624
15777
 
15625
15778
  if (mapInfo.rect84) {
@@ -15630,6 +15783,7 @@ class AddDataViewModel {
15630
15783
 
15631
15784
  mapServerInfo.layerTreeData.forEach(node => {
15632
15785
  node.lsType = "ls";
15786
+ node.serverType = "imagerylayer";
15633
15787
 
15634
15788
  this._layerManager.addTempLayerNode(node, 1);
15635
15789
  }, this);
@@ -18380,6 +18534,10 @@ const CompareMapvue_type_script_setup_true_lang_js_default_ = {
18380
18534
  showShadow: {
18381
18535
  type: Boolean,
18382
18536
  default: false
18537
+ },
18538
+ offsetTop: {
18539
+ type: String,
18540
+ default: "16px"
18383
18541
  }
18384
18542
  },
18385
18543
  emits: ["back"],
@@ -18389,6 +18547,7 @@ const CompareMapvue_type_script_setup_true_lang_js_default_ = {
18389
18547
  emit
18390
18548
  }) {
18391
18549
  const props = __props;
18550
+ let offsetTop = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.ref)("auto");
18392
18551
  let language = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.ref)({});
18393
18552
  let btnShow = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.ref)(false); // 分屏返回按钮
18394
18553
 
@@ -18406,6 +18565,7 @@ const CompareMapvue_type_script_setup_true_lang_js_default_ = {
18406
18565
  let tree3Index = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.ref)(2);
18407
18566
  let tree4Index = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.ref)(3);
18408
18567
  (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.onMounted)(() => {
18568
+ offsetTop.value = props.offsetTop;
18409
18569
  gis_utils_namespaceObject.utils.getWebMap(null, scenceView => {
18410
18570
  if (scenceView) {
18411
18571
  language.value = scenceView._language;
@@ -18464,7 +18624,10 @@ const CompareMapvue_type_script_setup_true_lang_js_default_ = {
18464
18624
  resetMode();
18465
18625
  });
18466
18626
  expose({
18467
- changeMode
18627
+ changeMode,
18628
+ goBack,
18629
+ resetMode,
18630
+ setLayerState
18468
18631
  });
18469
18632
  return (_ctx, _cache) => {
18470
18633
  const _component_kq_icon = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.resolveComponent)("kq-icon");
@@ -18474,18 +18637,24 @@ const CompareMapvue_type_script_setup_true_lang_js_default_ = {
18474
18637
  return (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createElementBlock)("section", CompareMapvue_type_script_setup_true_lang_js_hoisted_1, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(showTree1) ? ((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createBlock)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(CompareMapTree), {
18475
18638
  key: 0,
18476
18639
  class: "layer-tree-1",
18640
+ style: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.normalizeStyle)({
18641
+ 'top': (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(offsetTop)
18642
+ }),
18477
18643
  index: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(tree1Index),
18478
18644
  setLayerState: setLayerState
18479
18645
  }, null, 8
18480
18646
  /* PROPS */
18481
- , ["index"])) : (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createCommentVNode)("v-if", true), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(showTree2) ? ((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createBlock)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(CompareMapTree), {
18647
+ , ["style", "index"])) : (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createCommentVNode)("v-if", true), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(showTree2) ? ((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createBlock)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(CompareMapTree), {
18482
18648
  key: 1,
18483
18649
  class: "layer-tree-2",
18650
+ style: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.normalizeStyle)({
18651
+ 'top': (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(offsetTop)
18652
+ }),
18484
18653
  index: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(tree2Index),
18485
18654
  setLayerState: setLayerState
18486
18655
  }, null, 8
18487
18656
  /* PROPS */
18488
- , ["index"])) : (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createCommentVNode)("v-if", true), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(showTree3) ? ((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createBlock)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(CompareMapTree), {
18657
+ , ["style", "index"])) : (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createCommentVNode)("v-if", true), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(showTree3) ? ((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createBlock)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(CompareMapTree), {
18489
18658
  key: 2,
18490
18659
  class: "layer-tree-3",
18491
18660
  index: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(tree3Index),
@@ -18503,6 +18672,9 @@ const CompareMapvue_type_script_setup_true_lang_js_default_ = {
18503
18672
  circle: "",
18504
18673
  title: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(language).return,
18505
18674
  class: "close-button",
18675
+ style: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.normalizeStyle)({
18676
+ 'top': (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(offsetTop)
18677
+ }),
18506
18678
  onClick: _cache[0] || (_cache[0] = $event => goBack())
18507
18679
  }, {
18508
18680
  default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.createVNode)(_component_kq_icon, null, {
@@ -18516,7 +18688,7 @@ const CompareMapvue_type_script_setup_true_lang_js_default_ = {
18516
18688
 
18517
18689
  }, 8
18518
18690
  /* PROPS */
18519
- , ["title"]), [[external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.vShow, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(btnShow)]])]);
18691
+ , ["title", "style"]), [[external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.vShow, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_namespaceObject.unref)(btnShow)]])]);
18520
18692
  };
18521
18693
  }
18522
18694