@kq_npm/client3d_webgl_vue 4.5.37 → 4.5.38
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.
- package/adddata/index.js +9 -16
- package/boxclip/index.js +30 -13
- package/clientPrint/index.js +294 -140
- package/geologicalbodyanalysis/index.js +25 -4
- package/index.js +289 -135
- package/measure/index.js +3 -2
- package/modelfilter/index.js +29 -9
- package/modelselect/index.js +31 -8
- package/package.json +1 -1
- package/planeclip/index.js +30 -12
- package/sceneapp/index.js +293 -139
- package/sceneview/index.js +293 -139
- package/windyslicing/index.js +3 -1
package/clientPrint/index.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
(function webpackUniversalModuleDefinition(root, factory) {
|
|
2
2
|
if(typeof exports === 'object' && typeof module === 'object')
|
|
3
|
-
module.exports = factory(require("vue"), require("
|
|
3
|
+
module.exports = factory(require("vue"), require("@kq_npm/client_common_vue/init.js"), require("@kq_npm/client_common_vue/_utils/mitt"), require("@kq_npm/client_common_vue/_utils/gis-utils"), require("@kq_npm/client_common_vue/_utils/util"), require("@kq_npm/client_common_vue/_types/global-event"), require("@kq_npm/client_common_vue/_utils/const-image"), require("@kq_npm/client_common_vue/_utils/webmapservice"), require("@kq_npm/client_common_vue"), require("@kq_npm/client_common_vue/_lang/index.js"), require("@kq_npm/client_common_vue/_mixin/render"), require("@kq_npm/client_common_vue/_utils/dictionaries"), require("@kq_npm/client3d_webgl_vue"));
|
|
4
4
|
else if(typeof define === 'function' && define.amd)
|
|
5
|
-
define("@kq_npm/client3d_webgl_vue", ["vue", "
|
|
5
|
+
define("@kq_npm/client3d_webgl_vue", ["vue", "@kq_npm/client_common_vue/init.js", "@kq_npm/client_common_vue/_utils/mitt", "@kq_npm/client_common_vue/_utils/gis-utils", "@kq_npm/client_common_vue/_utils/util", "@kq_npm/client_common_vue/_types/global-event", "@kq_npm/client_common_vue/_utils/const-image", "@kq_npm/client_common_vue/_utils/webmapservice", "@kq_npm/client_common_vue", "@kq_npm/client_common_vue/_lang/index.js", "@kq_npm/client_common_vue/_mixin/render", "@kq_npm/client_common_vue/_utils/dictionaries", "@kq_npm/client3d_webgl_vue"], factory);
|
|
6
6
|
else if(typeof exports === 'object')
|
|
7
|
-
exports["@kq_npm/client3d_webgl_vue"] = factory(require("vue"), require("
|
|
7
|
+
exports["@kq_npm/client3d_webgl_vue"] = factory(require("vue"), require("@kq_npm/client_common_vue/init.js"), require("@kq_npm/client_common_vue/_utils/mitt"), require("@kq_npm/client_common_vue/_utils/gis-utils"), require("@kq_npm/client_common_vue/_utils/util"), require("@kq_npm/client_common_vue/_types/global-event"), require("@kq_npm/client_common_vue/_utils/const-image"), require("@kq_npm/client_common_vue/_utils/webmapservice"), require("@kq_npm/client_common_vue"), require("@kq_npm/client_common_vue/_lang/index.js"), require("@kq_npm/client_common_vue/_mixin/render"), require("@kq_npm/client_common_vue/_utils/dictionaries"), require("@kq_npm/client3d_webgl_vue"));
|
|
8
8
|
else
|
|
9
|
-
root["@kq_npm/client3d_webgl_vue"] = factory(root["Vue"], root["
|
|
10
|
-
})(this, function(__WEBPACK_EXTERNAL_MODULE__1895__,
|
|
9
|
+
root["@kq_npm/client3d_webgl_vue"] = factory(root["Vue"], root["@kq_npm/client_common_vue/init.js"], root["@kq_npm/client_common_vue/_utils/mitt"], root["@kq_npm/client_common_vue/_utils/gis-utils"], root["@kq_npm/client_common_vue/_utils/util"], root["@kq_npm/client_common_vue/_types/global-event"], root["@kq_npm/client_common_vue/_utils/const-image"], root["@kq_npm/client_common_vue/_utils/webmapservice"], root["@kq_npm/client_common_vue"], root["@kq_npm/client_common_vue/_lang/index.js"], root["@kq_npm/client_common_vue/_mixin/render"], root["@kq_npm/client_common_vue/_utils/dictionaries"], root["@kq_npm/client3d_webgl_vue"]);
|
|
10
|
+
})(this, function(__WEBPACK_EXTERNAL_MODULE__1895__, __WEBPACK_EXTERNAL_MODULE__7997__, __WEBPACK_EXTERNAL_MODULE__8905__, __WEBPACK_EXTERNAL_MODULE__7135__, __WEBPACK_EXTERNAL_MODULE__3458__, __WEBPACK_EXTERNAL_MODULE__3536__, __WEBPACK_EXTERNAL_MODULE__6277__, __WEBPACK_EXTERNAL_MODULE__3217__, __WEBPACK_EXTERNAL_MODULE__7064__, __WEBPACK_EXTERNAL_MODULE__5775__, __WEBPACK_EXTERNAL_MODULE__9678__, __WEBPACK_EXTERNAL_MODULE__3569__, __WEBPACK_EXTERNAL_MODULE__6459__) {
|
|
11
11
|
return /******/ (function() { // webpackBootstrap
|
|
12
12
|
/******/ var __webpack_modules__ = ({
|
|
13
13
|
|
|
@@ -1157,7 +1157,8 @@ return (_ctx, _cache) => {
|
|
|
1157
1157
|
(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("p", _hoisted_4, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).mode), 1 /* TEXT */),
|
|
1158
1158
|
(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_select, {
|
|
1159
1159
|
modelValue: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(mode),
|
|
1160
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => ((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.isRef)(mode) ? (mode).value = $event : mode = $event))
|
|
1160
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => ((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.isRef)(mode) ? (mode).value = $event : mode = $event)),
|
|
1161
|
+
disabled: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(isActive)
|
|
1161
1162
|
}, {
|
|
1162
1163
|
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [
|
|
1163
1164
|
((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.openBlock)(true), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementBlock)(external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.Fragment, null, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.renderList)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(modeList), (item) => {
|
|
@@ -1169,7 +1170,7 @@ return (_ctx, _cache) => {
|
|
|
1169
1170
|
}), 128 /* KEYED_FRAGMENT */))
|
|
1170
1171
|
]),
|
|
1171
1172
|
_: 1 /* STABLE */
|
|
1172
|
-
}, 8 /* PROPS */, ["modelValue"])
|
|
1173
|
+
}, 8 /* PROPS */, ["modelValue", "disabled"])
|
|
1173
1174
|
])
|
|
1174
1175
|
]),
|
|
1175
1176
|
(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_5, [
|
|
@@ -1810,7 +1811,7 @@ element_plus_dist_index_full_js__WEBPACK_IMPORTED_MODULE_0__.ElMessage.install =
|
|
|
1810
1811
|
|
|
1811
1812
|
/***/ }),
|
|
1812
1813
|
|
|
1813
|
-
/***/
|
|
1814
|
+
/***/ 1358:
|
|
1814
1815
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
1815
1816
|
|
|
1816
1817
|
"use strict";
|
|
@@ -1839,9 +1840,9 @@ var util_ = __webpack_require__(3458);
|
|
|
1839
1840
|
var message = __webpack_require__(1705);
|
|
1840
1841
|
// EXTERNAL MODULE: external "@kq_npm/client_common_vue/_utils/const-image"
|
|
1841
1842
|
var const_image_ = __webpack_require__(6277);
|
|
1842
|
-
|
|
1843
|
-
var
|
|
1844
|
-
var
|
|
1843
|
+
;// CONCATENATED MODULE: external "papaparse"
|
|
1844
|
+
var external_papaparse_namespaceObject = require("papaparse");
|
|
1845
|
+
var external_papaparse_default = /*#__PURE__*/__webpack_require__.n(external_papaparse_namespaceObject);
|
|
1845
1846
|
;// CONCATENATED MODULE: ./src/webgl/adddata/AddDataViewModel.js
|
|
1846
1847
|
/*
|
|
1847
1848
|
* Copyright (C) 2019 KQ GEO Technologies Co., Ltd.
|
|
@@ -1989,7 +1990,7 @@ class AddDataViewModel {
|
|
|
1989
1990
|
});
|
|
1990
1991
|
} else if (ext === "csv") {
|
|
1991
1992
|
(0,util_.readFile)(file, res => {
|
|
1992
|
-
var features =
|
|
1993
|
+
var features = external_papaparse_default().parse(res, {
|
|
1993
1994
|
skipEmptyLines: true,
|
|
1994
1995
|
header: true
|
|
1995
1996
|
}).data;
|
|
@@ -4924,6 +4925,7 @@ var message = __webpack_require__(1705);
|
|
|
4924
4925
|
*/
|
|
4925
4926
|
//Box裁剪逻辑类
|
|
4926
4927
|
|
|
4928
|
+
|
|
4927
4929
|
class BoxClipViewModel {
|
|
4928
4930
|
_viewer = null; //三维viewer对象
|
|
4929
4931
|
_options = {}; //Box裁剪存储参数对象
|
|
@@ -4950,13 +4952,14 @@ class BoxClipViewModel {
|
|
|
4950
4952
|
_drawManager = null; //绘制管理对象
|
|
4951
4953
|
_removeEventListener = null; //绘制完成监听事件
|
|
4952
4954
|
_language = {};
|
|
4953
|
-
|
|
4955
|
+
callbackParams = null;
|
|
4956
|
+
constructor(scenceView, options, callbackParams) {
|
|
4954
4957
|
this._language = scenceView._language;
|
|
4955
4958
|
this._options = Object.assign({}, options, this._defaultOptions);
|
|
4956
4959
|
this._viewer = scenceView._viewer;
|
|
4960
|
+
this.callbackParams = callbackParams;
|
|
4957
4961
|
// this._viewer.enabledFXAA = true;
|
|
4958
4962
|
this._options.viewer = this._viewer;
|
|
4959
|
-
|
|
4960
4963
|
this._drawManager = scenceView._drawManager;
|
|
4961
4964
|
let that = this;
|
|
4962
4965
|
this._removeEventListener = this._drawManager.drawFinishedEvent.addEventListener(shape => {
|
|
@@ -4967,14 +4970,25 @@ class BoxClipViewModel {
|
|
|
4967
4970
|
that._drawManager.clear();
|
|
4968
4971
|
}
|
|
4969
4972
|
});
|
|
4973
|
+
// 事件绑定this
|
|
4974
|
+
this._resetListData = this._resetListData.bind(this);
|
|
4975
|
+
// 添加图层数据源变化监听
|
|
4976
|
+
gis_utils_.mapViewUtils.bindViewEvents("resetLayerDatas", this._resetListData, scenceView._viewerId);
|
|
4977
|
+
}
|
|
4978
|
+
_resetListData(e) {
|
|
4979
|
+
// 如果图层变化事件是自己触发的 则不继续执行 避免死循环
|
|
4980
|
+
if (e.eventTarget && e.eventTarget === this) {
|
|
4981
|
+
return;
|
|
4982
|
+
}
|
|
4983
|
+
this.callbackParams && this.callbackParams("setData")
|
|
4970
4984
|
}
|
|
4971
|
-
|
|
4972
4985
|
// 查找所有3dtiles模型对象
|
|
4973
4986
|
findLayers() {
|
|
4974
4987
|
let tilesets = [];
|
|
4975
4988
|
const primitives = this._options.viewer.scene.primitives._primitives;
|
|
4976
4989
|
for (let m = 0; m < primitives.length; m++) {
|
|
4977
4990
|
if (primitives[m] instanceof Cesium.Cesium3DTileset) {
|
|
4991
|
+
if(!primitives[m].show) continue;
|
|
4978
4992
|
tilesets.push({
|
|
4979
4993
|
guid: primitives[m].guid,
|
|
4980
4994
|
name: primitives[m].name ? primitives[m].name : primitives[m].guid
|
|
@@ -4999,7 +5013,7 @@ class BoxClipViewModel {
|
|
|
4999
5013
|
var flag = false;
|
|
5000
5014
|
var models = this._options.viewer.scene.primitives._primitives;
|
|
5001
5015
|
for (let i = 0; i < models.length; i++) {
|
|
5002
|
-
if (models[i]._url) {
|
|
5016
|
+
if (models[i]._url && models[i].show) {
|
|
5003
5017
|
flag = true;
|
|
5004
5018
|
}
|
|
5005
5019
|
}
|
|
@@ -5030,6 +5044,7 @@ class BoxClipViewModel {
|
|
|
5030
5044
|
//移除监听事件
|
|
5031
5045
|
this._removeEventListener && this._removeEventListener();
|
|
5032
5046
|
this._removeEventListener = null;
|
|
5047
|
+
gis_utils_.mapViewUtils.offViewEvents("resetLayerDatas", this._resetListData, this._viewer._container.id);
|
|
5033
5048
|
}
|
|
5034
5049
|
|
|
5035
5050
|
// 设置裁剪对象
|
|
@@ -5243,20 +5258,23 @@ headerTempTitle.value = language.value.boxClip;
|
|
|
5243
5258
|
axisZ: formItem.clipHeight,
|
|
5244
5259
|
angle: formItem.clipRotation
|
|
5245
5260
|
};
|
|
5246
|
-
viewModel = new BoxClipViewModel(scenceView, options);
|
|
5261
|
+
viewModel = new BoxClipViewModel(scenceView, options, callbackParams);
|
|
5247
5262
|
}
|
|
5248
5263
|
});
|
|
5249
5264
|
setTimeout(() => {
|
|
5250
|
-
|
|
5251
|
-
tiles.value = viewModel.findLayers(); // 获取所有tileset对象
|
|
5252
|
-
if (tiles.value.length > 0) {
|
|
5253
|
-
formItem.tileset = tiles.value[0].guid;
|
|
5254
|
-
paramsChanged("tileset");
|
|
5255
|
-
}
|
|
5256
|
-
}
|
|
5265
|
+
callbackParams();
|
|
5257
5266
|
}, 1000);
|
|
5258
5267
|
});
|
|
5259
|
-
|
|
5268
|
+
function callbackParams (key, val) {
|
|
5269
|
+
if (viewModel) {
|
|
5270
|
+
tiles.value = viewModel.findLayers(); // 获取所有tileset对象
|
|
5271
|
+
formItem.tileset = "";
|
|
5272
|
+
if (tiles.value.length > 0) {
|
|
5273
|
+
formItem.tileset = tiles.value[0].guid;
|
|
5274
|
+
}
|
|
5275
|
+
paramsChanged("tileset");
|
|
5276
|
+
}
|
|
5277
|
+
}
|
|
5260
5278
|
/**
|
|
5261
5279
|
* @description 监听header生成
|
|
5262
5280
|
*/
|
|
@@ -5875,7 +5893,7 @@ BoxClip.install = (Vue, opts) => {
|
|
|
5875
5893
|
|
|
5876
5894
|
/***/ }),
|
|
5877
5895
|
|
|
5878
|
-
/***/
|
|
5896
|
+
/***/ 5603:
|
|
5879
5897
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
5880
5898
|
|
|
5881
5899
|
"use strict";
|
|
@@ -5889,9 +5907,9 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
5889
5907
|
|
|
5890
5908
|
// EXTERNAL MODULE: external {"root":"Vue","commonjs":"vue","commonjs2":"vue","amd":"vue"}
|
|
5891
5909
|
var external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_ = __webpack_require__(1895);
|
|
5892
|
-
|
|
5893
|
-
var
|
|
5894
|
-
var
|
|
5910
|
+
;// CONCATENATED MODULE: external "html2canvas-pro"
|
|
5911
|
+
var external_html2canvas_pro_namespaceObject = require("html2canvas-pro");
|
|
5912
|
+
var external_html2canvas_pro_default = /*#__PURE__*/__webpack_require__.n(external_html2canvas_pro_namespaceObject);
|
|
5895
5913
|
// EXTERNAL MODULE: ./src/common/_ui/message/index.js
|
|
5896
5914
|
var message = __webpack_require__(1705);
|
|
5897
5915
|
// EXTERNAL MODULE: external "@element-plus/icons-vue"
|
|
@@ -6880,7 +6898,7 @@ function getPic() {
|
|
|
6880
6898
|
loadState.value = true;
|
|
6881
6899
|
// 延时1000ms,等待图片读入到blob文件对象,然后使用URL.createObjectURL转换成src可用的地址
|
|
6882
6900
|
setTimeout(() => {
|
|
6883
|
-
|
|
6901
|
+
external_html2canvas_pro_default()(printMap.value, {
|
|
6884
6902
|
taintTest: true, // 检测每张图片都已经加载完成
|
|
6885
6903
|
logging: true, // 启用日志记录以进行调试 (发现加上对去白边有帮助)
|
|
6886
6904
|
allowTaint: true, // 否允许跨源图像污染画布
|
|
@@ -9627,7 +9645,7 @@ Compass.install = (Vue, opts) => {
|
|
|
9627
9645
|
/* harmony import */ var _webgl_fixedzoomin__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7671);
|
|
9628
9646
|
/* harmony import */ var _webgl_resetview__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1364);
|
|
9629
9647
|
/* harmony import */ var _webgl_compass__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1899);
|
|
9630
|
-
/* harmony import */ var _webgl_clientPrint__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(
|
|
9648
|
+
/* harmony import */ var _webgl_clientPrint__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5603);
|
|
9631
9649
|
/* harmony import */ var _webgl_baseterraingallery__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(8180);
|
|
9632
9650
|
/* harmony import */ var _webgl_measure__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(9870);
|
|
9633
9651
|
/* harmony import */ var _webgl_flight__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(9395);
|
|
@@ -9659,7 +9677,7 @@ Compass.install = (Vue, opts) => {
|
|
|
9659
9677
|
/* harmony import */ var _webgl_isolineanalysis__WEBPACK_IMPORTED_MODULE_34__ = __webpack_require__(6209);
|
|
9660
9678
|
/* harmony import */ var _webgl_boxclip__WEBPACK_IMPORTED_MODULE_35__ = __webpack_require__(5066);
|
|
9661
9679
|
/* harmony import */ var _webgl_planeclip__WEBPACK_IMPORTED_MODULE_36__ = __webpack_require__(6597);
|
|
9662
|
-
/* harmony import */ var _webgl_adddata__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(
|
|
9680
|
+
/* harmony import */ var _webgl_adddata__WEBPACK_IMPORTED_MODULE_37__ = __webpack_require__(1358);
|
|
9663
9681
|
/* harmony import */ var _webgl_particleeffect__WEBPACK_IMPORTED_MODULE_38__ = __webpack_require__(4545);
|
|
9664
9682
|
/* harmony import */ var _webgl_weathereffect__WEBPACK_IMPORTED_MODULE_39__ = __webpack_require__(8498);
|
|
9665
9683
|
/* harmony import */ var _webgl_comparemap__WEBPACK_IMPORTED_MODULE_40__ = __webpack_require__(8752);
|
|
@@ -12905,16 +12923,19 @@ var message = __webpack_require__(1705);
|
|
|
12905
12923
|
*/
|
|
12906
12924
|
//地质体分析逻辑类
|
|
12907
12925
|
|
|
12926
|
+
|
|
12908
12927
|
class GeologicalBodyAnalysisViewModel {
|
|
12909
12928
|
_viewer = null; //三维viewer对象
|
|
12910
12929
|
_options = {}; //地质体分析存储参数对象
|
|
12911
12930
|
_geologyBody = null; //地质体分析三维对象
|
|
12912
12931
|
_measureHandler = null;
|
|
12913
12932
|
_language = {};
|
|
12914
|
-
|
|
12933
|
+
callbackParams = null;
|
|
12934
|
+
constructor(scenceView, options, callbackParams) {
|
|
12915
12935
|
this._language = scenceView._language;
|
|
12916
12936
|
this._options = options;
|
|
12917
12937
|
this._viewer = scenceView._viewer;
|
|
12938
|
+
this.callbackParams = callbackParams;
|
|
12918
12939
|
this._measureHandler = new Cesium.Kq3dMeasureHandler(scenceView._viewer);
|
|
12919
12940
|
this._measureHandler.measureEvent.addEventListener(function (result) {
|
|
12920
12941
|
if(result.measureResult.labels) result.measureResult.labels.show = false;
|
|
@@ -12960,8 +12981,18 @@ class GeologicalBodyAnalysisViewModel {
|
|
|
12960
12981
|
}
|
|
12961
12982
|
}
|
|
12962
12983
|
});
|
|
12984
|
+
// 事件绑定this
|
|
12985
|
+
this._resetListData = this._resetListData.bind(this);
|
|
12986
|
+
// 添加图层数据源变化监听
|
|
12987
|
+
gis_utils_.mapViewUtils.bindViewEvents("resetLayerDatas", this._resetListData, scenceView._viewerId);
|
|
12988
|
+
}
|
|
12989
|
+
_resetListData(e) {
|
|
12990
|
+
// 如果图层变化事件是自己触发的 则不继续执行 避免死循环
|
|
12991
|
+
if (e.eventTarget && e.eventTarget === this) {
|
|
12992
|
+
return;
|
|
12993
|
+
}
|
|
12994
|
+
this.callbackParams && this.callbackParams("setData")
|
|
12963
12995
|
}
|
|
12964
|
-
|
|
12965
12996
|
// 查找所有地质体对象
|
|
12966
12997
|
findLayers() {
|
|
12967
12998
|
let geologys = [];
|
|
@@ -12969,6 +13000,7 @@ class GeologicalBodyAnalysisViewModel {
|
|
|
12969
13000
|
for (let i = 0; i < geologyBodyCollection.length; i++) {
|
|
12970
13001
|
if(geologyBodyCollection[i].geologyPrimitiveCollection) {
|
|
12971
13002
|
if(!geologyBodyCollection[i].guid) geologyBodyCollection[i].guid = Cesium.createGuid();
|
|
13003
|
+
if(geologyBodyCollection[i]?.show == false) continue;
|
|
12972
13004
|
geologys.push({
|
|
12973
13005
|
guid: geologyBodyCollection[i].guid,
|
|
12974
13006
|
name: geologyBodyCollection[i].name ? geologyBodyCollection[i].name : geologyBodyCollection[i].guid
|
|
@@ -13031,6 +13063,7 @@ class GeologicalBodyAnalysisViewModel {
|
|
|
13031
13063
|
this.clear();
|
|
13032
13064
|
this._measureHandler && this._measureHandler.destroy();
|
|
13033
13065
|
this._measureHandler = null;
|
|
13066
|
+
gis_utils_.mapViewUtils.offViewEvents("resetLayerDatas", this._resetListData, this._viewer._container.id);
|
|
13034
13067
|
}
|
|
13035
13068
|
}
|
|
13036
13069
|
|
|
@@ -13164,7 +13197,7 @@ headerTempTitle.value = language.value.geologyBodyAnalysis;
|
|
|
13164
13197
|
//父组 件ScenceView初始化完成后执行
|
|
13165
13198
|
gis_utils_.utils.getWebMap(null, scenceView => {
|
|
13166
13199
|
if (scenceView) {
|
|
13167
|
-
viewModel = new GeologicalBodyAnalysisViewModel(scenceView, formItem);
|
|
13200
|
+
viewModel = new GeologicalBodyAnalysisViewModel(scenceView, formItem, callbackParams);
|
|
13168
13201
|
}
|
|
13169
13202
|
});
|
|
13170
13203
|
setTimeout(() => {
|
|
@@ -13177,7 +13210,13 @@ headerTempTitle.value = language.value.geologyBodyAnalysis;
|
|
|
13177
13210
|
}
|
|
13178
13211
|
}, 1000);
|
|
13179
13212
|
});
|
|
13180
|
-
|
|
13213
|
+
function callbackParams (key, val) {
|
|
13214
|
+
if (viewModel) {
|
|
13215
|
+
tiles.value = viewModel.findLayers(); // 获取所有tileset对象
|
|
13216
|
+
formItem.geology = null;
|
|
13217
|
+
paramsChanged("geology");
|
|
13218
|
+
}
|
|
13219
|
+
}
|
|
13181
13220
|
/**
|
|
13182
13221
|
* @description 监听header生成
|
|
13183
13222
|
*/
|
|
@@ -21217,12 +21256,13 @@ var gis_utils_ = __webpack_require__(7135);
|
|
|
21217
21256
|
// EXTERNAL MODULE: ./src/common/_ui/message/index.js
|
|
21218
21257
|
var message = __webpack_require__(1705);
|
|
21219
21258
|
;// CONCATENATED MODULE: ./src/webgl/modelfilter/ModelFilterViewModel.js
|
|
21220
|
-
/*
|
|
21221
|
-
* Copyright (C) 2019 KQ GEO Technologies Co., Ltd.
|
|
21222
|
-
* All rights reserved.
|
|
21223
|
-
*/
|
|
21259
|
+
/*
|
|
21260
|
+
* Copyright (C) 2019 KQ GEO Technologies Co., Ltd.
|
|
21261
|
+
* All rights reserved.
|
|
21262
|
+
*/
|
|
21224
21263
|
//模型滤镜逻辑类
|
|
21225
21264
|
|
|
21265
|
+
|
|
21226
21266
|
class ModelFilterViewModel {
|
|
21227
21267
|
_viewer = null; //三维viewer对象
|
|
21228
21268
|
_options = {}; //Box裁剪存储参数对象
|
|
@@ -21233,19 +21273,31 @@ class ModelFilterViewModel {
|
|
|
21233
21273
|
saturation:1,
|
|
21234
21274
|
gamma: 1
|
|
21235
21275
|
}
|
|
21236
|
-
|
|
21237
|
-
constructor(scenceView, options) {
|
|
21276
|
+
callbackParams = null;
|
|
21277
|
+
constructor(scenceView, options, callbackParams) {
|
|
21238
21278
|
this._options = Object.assign({}, options, this._defaultOptions);
|
|
21239
21279
|
this._viewer = scenceView._viewer;
|
|
21240
21280
|
this._options.viewer = this._viewer;
|
|
21281
|
+
this.callbackParams = callbackParams;
|
|
21282
|
+
// 事件绑定this
|
|
21283
|
+
this._resetListData = this._resetListData.bind(this);
|
|
21284
|
+
// 添加图层数据源变化监听
|
|
21285
|
+
gis_utils_.mapViewUtils.bindViewEvents("resetLayerDatas", this._resetListData, scenceView._viewerId);
|
|
21286
|
+
}
|
|
21287
|
+
_resetListData(e) {
|
|
21288
|
+
// 如果图层变化事件是自己触发的 则不继续执行 避免死循环
|
|
21289
|
+
if (e.eventTarget && e.eventTarget === this) {
|
|
21290
|
+
return;
|
|
21291
|
+
}
|
|
21292
|
+
this.callbackParams && this.callbackParams("setData")
|
|
21241
21293
|
}
|
|
21242
|
-
|
|
21243
21294
|
// 查找所有3dtiles模型对象
|
|
21244
21295
|
findLayers() {
|
|
21245
21296
|
let tilesets = [];
|
|
21246
21297
|
const primitives = this._viewer.scene.primitives._primitives;
|
|
21247
21298
|
for (let m = 0; m < primitives.length; m++) {
|
|
21248
21299
|
if (primitives[m] instanceof Cesium.Cesium3DTileset) {
|
|
21300
|
+
if(!primitives[m].show) continue;
|
|
21249
21301
|
tilesets.push({
|
|
21250
21302
|
guid: primitives[m].guid,
|
|
21251
21303
|
name: primitives[m].name ? primitives[m].name : primitives[m].guid
|
|
@@ -21306,6 +21358,7 @@ class ModelFilterViewModel {
|
|
|
21306
21358
|
|
|
21307
21359
|
//销毁
|
|
21308
21360
|
destroy() {
|
|
21361
|
+
gis_utils_.mapViewUtils.offViewEvents("resetLayerDatas", this._resetListData, this._viewer._container.id);
|
|
21309
21362
|
this.clear();
|
|
21310
21363
|
}
|
|
21311
21364
|
}
|
|
@@ -21449,7 +21502,7 @@ headerTempTitle.value = language.value.modelFilterPick;
|
|
|
21449
21502
|
saturation: formItem.saturation,
|
|
21450
21503
|
gamma: formItem.gamma
|
|
21451
21504
|
};
|
|
21452
|
-
viewModel = new ModelFilterViewModel(scenceView, options);
|
|
21505
|
+
viewModel = new ModelFilterViewModel(scenceView, options, callbackParams);
|
|
21453
21506
|
}
|
|
21454
21507
|
});
|
|
21455
21508
|
setTimeout(() => {
|
|
@@ -21458,7 +21511,13 @@ headerTempTitle.value = language.value.modelFilterPick;
|
|
|
21458
21511
|
}
|
|
21459
21512
|
}, 1000);
|
|
21460
21513
|
});
|
|
21461
|
-
|
|
21514
|
+
function callbackParams (key, val) {
|
|
21515
|
+
if (viewModel) {
|
|
21516
|
+
tiles.value = viewModel.findLayers(); // 获取所有tileset对象
|
|
21517
|
+
formItem.tileset = "";
|
|
21518
|
+
paramsChanged("tileset");
|
|
21519
|
+
}
|
|
21520
|
+
}
|
|
21462
21521
|
/**
|
|
21463
21522
|
* @description 监听header生成
|
|
21464
21523
|
*/
|
|
@@ -22660,6 +22719,9 @@ class ModelSelectViewModel {
|
|
|
22660
22719
|
_modeFiledArray = null; // 模型属性唯一值字段集合
|
|
22661
22720
|
_modeFiled = "id"; // 模型属性匹配字段
|
|
22662
22721
|
_language = {};
|
|
22722
|
+
selectedKey = null;
|
|
22723
|
+
oldColor = null;
|
|
22724
|
+
selectedFeature = null;
|
|
22663
22725
|
constructor(scenceView, pickCallFunc) {
|
|
22664
22726
|
this._language = scenceView._language;
|
|
22665
22727
|
this._viewer = scenceView._viewer;
|
|
@@ -22688,15 +22750,30 @@ class ModelSelectViewModel {
|
|
|
22688
22750
|
})
|
|
22689
22751
|
}
|
|
22690
22752
|
if (properties.indexOf(that._modeFiled) > -1) {
|
|
22691
|
-
let id = pickedObject.getProperty(that._modeFiled);
|
|
22753
|
+
// let id = pickedObject.getProperty(that._modeFiled);
|
|
22754
|
+
var newKey = pickedObject ? pickedObject.getProperty(that._modeFiled) : null;
|
|
22755
|
+
if (newKey != that.selectedKey) {
|
|
22756
|
+
if (that.selectedFeature) {
|
|
22757
|
+
that.selectedFeature.color = that.oldColor;
|
|
22758
|
+
that.selectedFeature = null;
|
|
22759
|
+
that.selectedKey = null;
|
|
22760
|
+
}
|
|
22761
|
+
|
|
22762
|
+
if (newKey != null) {
|
|
22763
|
+
that.selectedKey = newKey;
|
|
22764
|
+
that.selectedFeature = pickedObject;
|
|
22765
|
+
that.oldColor = that.selectedFeature.color;
|
|
22766
|
+
that.selectedFeature.color = Cesium.Color.fromCssColorString(that._highlightColor);
|
|
22767
|
+
}
|
|
22768
|
+
}
|
|
22692
22769
|
// that.clear();
|
|
22693
|
-
that._highlight = new Cesium.Kq3dHighlight({
|
|
22694
|
-
|
|
22695
|
-
|
|
22696
|
-
|
|
22697
|
-
|
|
22698
|
-
|
|
22699
|
-
});
|
|
22770
|
+
// that._highlight = new Cesium.Kq3dHighlight({
|
|
22771
|
+
// viewer: that._viewer,
|
|
22772
|
+
// tileset: pickedObject.tileset,
|
|
22773
|
+
// attrName: that._modeFiled,
|
|
22774
|
+
// attrValue: [id],
|
|
22775
|
+
// color: [Cesium.Color.fromCssColorString(that._highlightColor)]
|
|
22776
|
+
// });
|
|
22700
22777
|
let attrs = {};
|
|
22701
22778
|
properties.forEach(prop => {
|
|
22702
22779
|
attrs[prop] = pickedObject.getProperty(prop);
|
|
@@ -22749,6 +22826,11 @@ class ModelSelectViewModel {
|
|
|
22749
22826
|
this._highlight = null;
|
|
22750
22827
|
this.setCursor("default");
|
|
22751
22828
|
this._isPick = false;
|
|
22829
|
+
if (this.selectedFeature) {
|
|
22830
|
+
this.selectedFeature.color = this.oldColor;
|
|
22831
|
+
this.selectedFeature = null;
|
|
22832
|
+
this.selectedKey = null;
|
|
22833
|
+
}
|
|
22752
22834
|
}
|
|
22753
22835
|
|
|
22754
22836
|
//销毁
|
|
@@ -24069,6 +24151,7 @@ var message = __webpack_require__(1705);
|
|
|
24069
24151
|
*/
|
|
24070
24152
|
//平面裁剪逻辑类
|
|
24071
24153
|
|
|
24154
|
+
|
|
24072
24155
|
class PlaneClipViewModel {
|
|
24073
24156
|
_viewer = null; //三维viewer对象
|
|
24074
24157
|
_options = {}; //平面裁剪存储参数对象
|
|
@@ -24099,13 +24182,15 @@ class PlaneClipViewModel {
|
|
|
24099
24182
|
_drawManager = null; //绘制管理对象
|
|
24100
24183
|
_removeEventListener = null; //绘制完成事件监听
|
|
24101
24184
|
_language = {};
|
|
24102
|
-
|
|
24185
|
+
callbackParams = null;
|
|
24186
|
+
constructor(scenceView, options, callbackParams) {
|
|
24103
24187
|
this._options = Object.assign({}, options, this._defaultOptions);
|
|
24104
24188
|
this._viewer = scenceView._viewer;
|
|
24105
24189
|
// this._viewer.enabledFXAA = true;
|
|
24106
24190
|
this._options.viewer = this._viewer;
|
|
24107
24191
|
this._language = scenceView._language;
|
|
24108
24192
|
this._drawManager = scenceView._drawManager;
|
|
24193
|
+
this.callbackParams = callbackParams;
|
|
24109
24194
|
let that = this;
|
|
24110
24195
|
this._removeEventListener = this._drawManager.drawFinishedEvent.addEventListener(shape => {
|
|
24111
24196
|
if (shape) {
|
|
@@ -24115,14 +24200,25 @@ class PlaneClipViewModel {
|
|
|
24115
24200
|
that._drawManager.clear();
|
|
24116
24201
|
}
|
|
24117
24202
|
});
|
|
24203
|
+
// 事件绑定this
|
|
24204
|
+
this._resetListData = this._resetListData.bind(this);
|
|
24205
|
+
// 添加图层数据源变化监听
|
|
24206
|
+
gis_utils_.mapViewUtils.bindViewEvents("resetLayerDatas", this._resetListData, scenceView._viewerId);
|
|
24207
|
+
}
|
|
24208
|
+
_resetListData(e) {
|
|
24209
|
+
// 如果图层变化事件是自己触发的 则不继续执行 避免死循环
|
|
24210
|
+
if (e.eventTarget && e.eventTarget === this) {
|
|
24211
|
+
return;
|
|
24212
|
+
}
|
|
24213
|
+
this.callbackParams && this.callbackParams("setData")
|
|
24118
24214
|
}
|
|
24119
|
-
|
|
24120
24215
|
// 查找所有3dtiles模型对象
|
|
24121
24216
|
findLayers() {
|
|
24122
24217
|
let tilesets = [];
|
|
24123
24218
|
const primitives = this._options.viewer.scene.primitives._primitives;
|
|
24124
24219
|
for (let m = 0; m < primitives.length; m++) {
|
|
24125
24220
|
if (primitives[m] instanceof Cesium.Cesium3DTileset) {
|
|
24221
|
+
if(!primitives[m].show) continue;
|
|
24126
24222
|
tilesets.push({
|
|
24127
24223
|
guid: primitives[m].guid,
|
|
24128
24224
|
name: primitives[m].name ? primitives[m].name : primitives[m].guid
|
|
@@ -24147,7 +24243,7 @@ class PlaneClipViewModel {
|
|
|
24147
24243
|
var flag = false;
|
|
24148
24244
|
var models = this._options.viewer.scene.primitives._primitives;
|
|
24149
24245
|
for (let i = 0; i < models.length; i++) {
|
|
24150
|
-
if (models[i]._url) {
|
|
24246
|
+
if (models[i]._url && models[i].show) {
|
|
24151
24247
|
flag = true;
|
|
24152
24248
|
}
|
|
24153
24249
|
}
|
|
@@ -24177,6 +24273,7 @@ class PlaneClipViewModel {
|
|
|
24177
24273
|
//移除监听事件
|
|
24178
24274
|
this._removeEventListener && this._removeEventListener();
|
|
24179
24275
|
this._removeEventListener = null;
|
|
24276
|
+
gis_utils_.mapViewUtils.offViewEvents("resetLayerDatas", this._resetListData, this._viewer._container.id);
|
|
24180
24277
|
}
|
|
24181
24278
|
|
|
24182
24279
|
// 设置裁剪对象
|
|
@@ -24363,20 +24460,23 @@ headerTempTitle.value = language.value.planeClip;
|
|
|
24363
24460
|
boxEnable: formItem.boxEnable,
|
|
24364
24461
|
distance: formItem.clipDistance
|
|
24365
24462
|
};
|
|
24366
|
-
viewModel = new PlaneClipViewModel(scenceView, options);
|
|
24463
|
+
viewModel = new PlaneClipViewModel(scenceView, options, callbackParams);
|
|
24367
24464
|
}
|
|
24368
24465
|
});
|
|
24369
24466
|
setTimeout(() => {
|
|
24370
|
-
|
|
24371
|
-
tiles.value = viewModel.findLayers(); // 获取所有tileset对象
|
|
24372
|
-
if (tiles.value.length > 0) {
|
|
24373
|
-
formItem.tileset = tiles.value[0].guid;
|
|
24374
|
-
paramsChanged("tileset");
|
|
24375
|
-
}
|
|
24376
|
-
}
|
|
24467
|
+
callbackParams();
|
|
24377
24468
|
}, 1000);
|
|
24378
24469
|
});
|
|
24379
|
-
|
|
24470
|
+
function callbackParams (key, val) {
|
|
24471
|
+
if (viewModel) {
|
|
24472
|
+
tiles.value = viewModel.findLayers(); // 获取所有tileset对象
|
|
24473
|
+
formItem.tileset = "";
|
|
24474
|
+
if (tiles.value.length > 0) {
|
|
24475
|
+
formItem.tileset = tiles.value[0].guid;
|
|
24476
|
+
}
|
|
24477
|
+
paramsChanged("tileset");
|
|
24478
|
+
}
|
|
24479
|
+
}
|
|
24380
24480
|
/**
|
|
24381
24481
|
* @description 监听header生成
|
|
24382
24482
|
*/
|
|
@@ -29071,6 +29171,8 @@ function resetWebMapInfo(webMapInfo, cb, defaultShowLayerNames, isShowAllLayers)
|
|
|
29071
29171
|
return { ..._layerSources[i], ...layerData };
|
|
29072
29172
|
}
|
|
29073
29173
|
}
|
|
29174
|
+
} else {
|
|
29175
|
+
layerData.visible = getLayerDefaultState(layerData);
|
|
29074
29176
|
}
|
|
29075
29177
|
}
|
|
29076
29178
|
} else {
|
|
@@ -31071,10 +31173,7 @@ const updatePosition = (boxElem, props) => {
|
|
|
31071
31173
|
if (!boxElem) {
|
|
31072
31174
|
return false;
|
|
31073
31175
|
}
|
|
31074
|
-
|
|
31075
|
-
boxElem.style.left = "auto";
|
|
31076
|
-
boxElem.style.bottom = "auto";
|
|
31077
|
-
boxElem.style.right = "auto";
|
|
31176
|
+
|
|
31078
31177
|
const { position } = props;
|
|
31079
31178
|
let _fixed = "static";
|
|
31080
31179
|
if (position) {
|
|
@@ -31082,6 +31181,11 @@ const updatePosition = (boxElem, props) => {
|
|
|
31082
31181
|
} else {
|
|
31083
31182
|
return false;
|
|
31084
31183
|
}
|
|
31184
|
+
boxElem.style.top = "auto";
|
|
31185
|
+
boxElem.style.left = "auto";
|
|
31186
|
+
boxElem.style.bottom = "auto";
|
|
31187
|
+
boxElem.style.right = "auto";
|
|
31188
|
+
|
|
31085
31189
|
addClass(boxElem, "kq-is-absolute");
|
|
31086
31190
|
const clientVisibleWidth =
|
|
31087
31191
|
_fixed === "fixed" ? document.documentElement.clientWidth || document.body.clientWidth : "auto";
|
|
@@ -31542,15 +31646,6 @@ function specialSymbols(name) {
|
|
|
31542
31646
|
'"/></DecorateStyle>' +
|
|
31543
31647
|
"</PolygonSymbol>" +
|
|
31544
31648
|
"</StyleItem>";
|
|
31545
|
-
} else if (name === "圆点") {
|
|
31546
|
-
xml =
|
|
31547
|
-
'<StyleItem TypeID="109">' +
|
|
31548
|
-
'<CirclePoint Name="' +
|
|
31549
|
-
name +
|
|
31550
|
-
'" AliasName="' +
|
|
31551
|
-
name +
|
|
31552
|
-
'" Color="4278190080" Units="1" Mask="-5" EnableReallyMeter="0" Light="0" EnableXRay="0" XRayColor="4294967295" OffsetX="0" OffsetY="0" Degree="0" Width="3" Height="3" PivotX="0.5" PivotY="0.5" PivotZ="0" m="Y" md="1" mot_h="1" mov_rel_h="0" mov_abs_h="0" mot_v="1" mov_rel_v="0" mov_abs_v="0" vectortype="1" vectorpath="" vectoruuid="" StrokeColor="4294901760" StrokeWidth="0.5" Cap="512" Join="8192" PenStyle="1" FillColor="4294901760" FillStyle="1" GradientType="0" StartGradientColor="4278190080" EndGradientColor="4294967295" GradientDegree="0" GradientRatio="0" scaleWithStyle="N" SourceStyleLocked="N"/>' +
|
|
31553
|
-
"</StyleItem>";
|
|
31554
31649
|
}
|
|
31555
31650
|
let x2js = new X2JS();
|
|
31556
31651
|
let styleItem = x2js.xml2js(xml).StyleItem;
|
|
@@ -31760,8 +31855,7 @@ function getStyleItem(symbolInfo) {
|
|
|
31760
31855
|
symbolInfo.ITEM_NAME === "运载火箭航天发射" ||
|
|
31761
31856
|
symbolInfo.ITEM_NAME === "地空导弹营火力范围" ||
|
|
31762
31857
|
symbolInfo.ITEM_NAME === "近程常规导弹火力发射圈箭头线" ||
|
|
31763
|
-
symbolInfo.ITEM_NAME === "直瞄打击炮队展开地区"
|
|
31764
|
-
symbolInfo[j].ITEM_NAME === "圆点"
|
|
31858
|
+
symbolInfo.ITEM_NAME === "直瞄打击炮队展开地区"
|
|
31765
31859
|
) {
|
|
31766
31860
|
styleItem = specialSymbols(symbolInfo);
|
|
31767
31861
|
} else {
|
|
@@ -53263,6 +53357,31 @@ function openelement(ChildList, thirdName) {
|
|
|
53263
53357
|
thirdName.children.push(element);
|
|
53264
53358
|
}
|
|
53265
53359
|
}
|
|
53360
|
+
|
|
53361
|
+
function getPlotColor(colorValue) {
|
|
53362
|
+
if (colorValue.toString().indexOf("rgba") >= 0) {
|
|
53363
|
+
let value = colorValue.substring(colorValue.indexOf("(") + 1, colorValue.indexOf(")"));
|
|
53364
|
+
let values = value.split(",");
|
|
53365
|
+
let r = Number(values[0]);
|
|
53366
|
+
let g = Number(values[1]);
|
|
53367
|
+
let b = Number(values[2]);
|
|
53368
|
+
let a = Math.round((Number(values[3]) / 255) * 100) / 100;
|
|
53369
|
+
return "rgba(" + r + "," + g + "," + b + "," + a + ")";
|
|
53370
|
+
}
|
|
53371
|
+
if (colorValue === undefined) {
|
|
53372
|
+
return "rgba(0,0,0,1)";
|
|
53373
|
+
}
|
|
53374
|
+
colorValue = Number(colorValue);
|
|
53375
|
+
if (colorValue === 0) {
|
|
53376
|
+
return "rgba(255,0,0,1)";
|
|
53377
|
+
}
|
|
53378
|
+
// colorValue = colorValue >>> 0;
|
|
53379
|
+
let r = (colorValue >> 16) & 0xff;
|
|
53380
|
+
let g = (colorValue >> 8) & 0xff;
|
|
53381
|
+
let b = colorValue & 0xff;
|
|
53382
|
+
let a = Math.round(((colorValue >>> 24) / 255) * 100) / 100;
|
|
53383
|
+
return "rgba(" + r + "," + g + "," + b + "," + a + ")";
|
|
53384
|
+
}
|
|
53266
53385
|
|
|
53267
53386
|
;// CONCATENATED MODULE: ./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/webgl/sceneapp/components/AppPlotting.vue?vue&type=script&setup=true&lang=js
|
|
53268
53387
|
|
|
@@ -58193,7 +58312,7 @@ class DrawManager {
|
|
|
58193
58312
|
}
|
|
58194
58313
|
|
|
58195
58314
|
//开始绘制
|
|
58196
|
-
startDraw(type, style, callback, groupName, isMulti=false) {
|
|
58315
|
+
startDraw(type, style, callback, groupName, isMulti = false) {
|
|
58197
58316
|
// 开始绘制之前停止编辑和关闭样式设置框
|
|
58198
58317
|
if (this._drawHandler.editHandler.shapeObject) {
|
|
58199
58318
|
this._drawHandler.startEdit(null);
|
|
@@ -58215,7 +58334,7 @@ class DrawManager {
|
|
|
58215
58334
|
this._viewer.scene.globe.depthTestAgainstTerrain = true;
|
|
58216
58335
|
}
|
|
58217
58336
|
var unionOptions = { ...this._drawStyle[type] };
|
|
58218
|
-
if(type === "CatmullRomSpline") unionOptions = { ...this._drawStyle["polyline"] };
|
|
58337
|
+
if (type === "CatmullRomSpline") unionOptions = { ...this._drawStyle["polyline"] };
|
|
58219
58338
|
for (const key in unionOptions) {
|
|
58220
58339
|
if (Object.hasOwnProperty.call(options, key)) {
|
|
58221
58340
|
unionOptions[key] = options[key];
|
|
@@ -58261,16 +58380,16 @@ class DrawManager {
|
|
|
58261
58380
|
var feature = that.shapeToGeoFeature(shape);
|
|
58262
58381
|
callback(feature.geometry, { layer: shape.guid });
|
|
58263
58382
|
}
|
|
58264
|
-
if(that.removeEventListener)that.removeEventListener();
|
|
58383
|
+
if (that.removeEventListener) that.removeEventListener();
|
|
58265
58384
|
that.removeEventListener = null;
|
|
58266
|
-
if(isMulti) {
|
|
58385
|
+
if (isMulti) {
|
|
58267
58386
|
that.startDraw(type, style, callback, groupName, isMulti);
|
|
58268
58387
|
}
|
|
58269
58388
|
});
|
|
58270
58389
|
}
|
|
58271
58390
|
|
|
58272
58391
|
stopDraw() {
|
|
58273
|
-
if(this.removeEventListener) {
|
|
58392
|
+
if (this.removeEventListener) {
|
|
58274
58393
|
this.removeEventListener();
|
|
58275
58394
|
this.removeEventListener = null;
|
|
58276
58395
|
}
|
|
@@ -58393,7 +58512,7 @@ class DrawManager {
|
|
|
58393
58512
|
}
|
|
58394
58513
|
|
|
58395
58514
|
//通过geojson进行绘制,支持定位和闪烁
|
|
58396
|
-
drawFromGeojson(geojsonData, idCustom = "result", callFun, geojsonStyle, isLocation, flashing=false) {
|
|
58515
|
+
drawFromGeojson(geojsonData, idCustom = "result", callFun, geojsonStyle, isLocation, flashing = false) {
|
|
58397
58516
|
if (!geojsonStyle) geojsonStyle = {};
|
|
58398
58517
|
let style = JSON.parse(JSON.stringify(this._geojsonStyle));
|
|
58399
58518
|
for (var type in geojsonStyle) {
|
|
@@ -58433,6 +58552,7 @@ class DrawManager {
|
|
|
58433
58552
|
style.point.color = style.point.material;
|
|
58434
58553
|
delete style.billboard;
|
|
58435
58554
|
}
|
|
58555
|
+
|
|
58436
58556
|
this._viewer.scene.globe.depthTestAgainstTerrain = false;
|
|
58437
58557
|
let geojsonDs = this._viewer.dataSources.getByName(idCustom);
|
|
58438
58558
|
if (geojsonDs.length === 0) {
|
|
@@ -58468,11 +58588,11 @@ class DrawManager {
|
|
|
58468
58588
|
let offset = new Cesium.HeadingPitchRange(0, Cesium.Math.toRadians(-90), 0);
|
|
58469
58589
|
that._viewer.flyTo(ds, { duration: 1.5, offset });
|
|
58470
58590
|
}
|
|
58471
|
-
if(flashing) {
|
|
58591
|
+
if (flashing) {
|
|
58472
58592
|
// 闪烁效果
|
|
58473
58593
|
let count = 0;
|
|
58474
58594
|
let interval = setInterval(() => {
|
|
58475
|
-
if(ds._destroyed) {
|
|
58595
|
+
if (ds._destroyed) {
|
|
58476
58596
|
clearInterval(interval);
|
|
58477
58597
|
return;
|
|
58478
58598
|
}
|
|
@@ -58494,12 +58614,10 @@ class DrawManager {
|
|
|
58494
58614
|
|
|
58495
58615
|
//删除指定绘图分组的所有图形
|
|
58496
58616
|
removeGeojsonByIdCustom(idCustom) {
|
|
58617
|
+
if (idCustom === "draw") this.clear();
|
|
58497
58618
|
let dsList = this._viewer.dataSources.getByName(idCustom);
|
|
58498
58619
|
|
|
58499
|
-
if (dsList.length <= 0)
|
|
58500
|
-
this.clear();
|
|
58501
|
-
return;
|
|
58502
|
-
}
|
|
58620
|
+
if (dsList.length <= 0) return;
|
|
58503
58621
|
for (let i = 0; i < dsList.length; i++) {
|
|
58504
58622
|
this._viewer.dataSources.remove(dsList[i], true);
|
|
58505
58623
|
}
|
|
@@ -58507,7 +58625,6 @@ class DrawManager {
|
|
|
58507
58625
|
if (index > -1) {
|
|
58508
58626
|
this._layerGroup.splice(index, 1);
|
|
58509
58627
|
}
|
|
58510
|
-
if(idCustom === 'draw') this.clear();
|
|
58511
58628
|
}
|
|
58512
58629
|
|
|
58513
58630
|
getGeometry(idCustom) {
|
|
@@ -58735,8 +58852,8 @@ class DrawManager {
|
|
|
58735
58852
|
const layer = layerList[i];
|
|
58736
58853
|
const name = layer.name || "";
|
|
58737
58854
|
const info = this.getShapeInfo(layer.guid);
|
|
58738
|
-
|
|
58739
|
-
items.push({ name: name, info: info, shape: layer.shape });
|
|
58855
|
+
// edited by ly
|
|
58856
|
+
items.push({ name: name, info: info, shape: layer.shape, guid: layer.guid });
|
|
58740
58857
|
}
|
|
58741
58858
|
|
|
58742
58859
|
return JSON.stringify(items);
|
|
@@ -58920,7 +59037,7 @@ class DrawManager {
|
|
|
58920
59037
|
let shape = this._drawLayer.getById(id);
|
|
58921
59038
|
if (shape) {
|
|
58922
59039
|
let offset = new Cesium.HeadingPitchRange(0, Cesium.Math.toRadians(-90), 0);
|
|
58923
|
-
if(shape.type ===
|
|
59040
|
+
if (shape.type === "marker" || shape.type === "text") {
|
|
58924
59041
|
let boundingSphere = new Cesium.BoundingSphere(shape.position, 50000);
|
|
58925
59042
|
this._viewer.camera.flyToBoundingSphere(boundingSphere, { duration: 1.5, offset });
|
|
58926
59043
|
} else {
|
|
@@ -59064,29 +59181,55 @@ class DrawManager {
|
|
|
59064
59181
|
}
|
|
59065
59182
|
}
|
|
59066
59183
|
}
|
|
59184
|
+
setLabelList(v, g) {
|
|
59185
|
+
this._labelInfo = {
|
|
59186
|
+
labelList: v,
|
|
59187
|
+
groupName: g
|
|
59188
|
+
};
|
|
59189
|
+
}
|
|
59067
59190
|
|
|
59068
59191
|
/********** 地理编码通用组件使用 start ************/
|
|
59069
59192
|
// 绘制点图标自带点击弹出气泡, 地理编码通用组件使用
|
|
59070
|
-
drawPointWithPoup(data, idCustom = "geocode") {
|
|
59071
|
-
|
|
59072
|
-
|
|
59073
|
-
|
|
59074
|
-
|
|
59075
|
-
|
|
59076
|
-
|
|
59077
|
-
|
|
59078
|
-
|
|
59079
|
-
|
|
59080
|
-
|
|
59081
|
-
|
|
59082
|
-
|
|
59083
|
-
|
|
59084
|
-
|
|
59085
|
-
|
|
59086
|
-
|
|
59087
|
-
|
|
59088
|
-
|
|
59193
|
+
drawPointWithPoup(data, showPoup = false, idCustom = "geocode", isLocation = true) {
|
|
59194
|
+
const that = this;
|
|
59195
|
+
let scene = this._viewer.scene;
|
|
59196
|
+
if (showPoup) {
|
|
59197
|
+
if (!this.geocodeSelected) {
|
|
59198
|
+
this.geocodeSelected = [];
|
|
59199
|
+
}
|
|
59200
|
+
|
|
59201
|
+
if (!this._handler) {
|
|
59202
|
+
// 注册点击事件
|
|
59203
|
+
let scene = this._viewer.scene;
|
|
59204
|
+
this._handler = new Cesium.ScreenSpaceEventHandler(scene.canvas);
|
|
59205
|
+
// let that = this;
|
|
59206
|
+
this._handler.setInputAction(function (movement) {
|
|
59207
|
+
var pickedObject = scene.pick(movement.position);
|
|
59208
|
+
if (pickedObject && pickedObject.id && pickedObject.id instanceof Cesium.Entity) {
|
|
59209
|
+
let entity = pickedObject.id;
|
|
59210
|
+
that.createPointPoup(entity);
|
|
59211
|
+
}
|
|
59212
|
+
}, Cesium.ScreenSpaceEventType.LEFT_CLICK);
|
|
59213
|
+
this._handler.setInputAction(function (movement) {
|
|
59214
|
+
// that.closePointPoup();
|
|
59215
|
+
that.openPointPoup("1002", "AAA");
|
|
59216
|
+
// that.removePointAll();
|
|
59217
|
+
//that.clearPointByIdCustom();
|
|
59218
|
+
}, Cesium.ScreenSpaceEventType.RIGHT_CLICK);
|
|
59219
|
+
this._handler.setInputAction(function (movement) {
|
|
59220
|
+
const pickedObject = scene.pick(movement.endPosition);
|
|
59221
|
+
if (Cesium.defined(pickedObject) && pickedObject.id && pickedObject.id instanceof Cesium.Entity) {
|
|
59222
|
+
that.geocodeSelected = [pickedObject.id];
|
|
59223
|
+
pickedObject.id.billboard.image = pickedObject.id.properties.image1;
|
|
59224
|
+
} else {
|
|
59225
|
+
if (that.geocodeSelected && that.geocodeSelected.length > 0) {
|
|
59226
|
+
that.geocodeSelected[0].billboard.image = that.geocodeSelected[0].properties.image;
|
|
59227
|
+
}
|
|
59228
|
+
}
|
|
59229
|
+
}, Cesium.ScreenSpaceEventType.MOUSE_MOVE);
|
|
59230
|
+
}
|
|
59089
59231
|
}
|
|
59232
|
+
|
|
59090
59233
|
let pointDs = this._viewer.dataSources.getByName(idCustom);
|
|
59091
59234
|
if (pointDs.length === 0) {
|
|
59092
59235
|
pointDs = new Cesium.CustomDataSource(idCustom);
|
|
@@ -59095,28 +59238,52 @@ class DrawManager {
|
|
|
59095
59238
|
} else {
|
|
59096
59239
|
pointDs = pointDs[0];
|
|
59097
59240
|
}
|
|
59098
|
-
let position = Cesium.Cartesian3.fromDegrees(data.
|
|
59241
|
+
let position = Cesium.Cartesian3.fromDegrees(data.lon, data.lat);
|
|
59099
59242
|
pointDs.entities.add({
|
|
59100
59243
|
position: position,
|
|
59101
59244
|
billboard: {
|
|
59102
59245
|
image: data.image,
|
|
59246
|
+
image1: data.image1,
|
|
59103
59247
|
width: data.width,
|
|
59104
59248
|
height: data.height,
|
|
59105
59249
|
verticalOrigin: Cesium.VerticalOrigin.BOTTOM
|
|
59106
|
-
}
|
|
59107
|
-
|
|
59250
|
+
},
|
|
59251
|
+
properties: data
|
|
59108
59252
|
});
|
|
59253
|
+
// 是否定位
|
|
59254
|
+
if (isLocation) {
|
|
59255
|
+
let offset = new Cesium.HeadingPitchRange(0, Cesium.Math.toRadians(-90), 0);
|
|
59256
|
+
that._viewer.flyTo(pointDs, { duration: 1.5, offset });
|
|
59257
|
+
}
|
|
59109
59258
|
}
|
|
59110
59259
|
|
|
59111
59260
|
// 通过entity创建关联气泡
|
|
59112
59261
|
createPointPoup(entity) {
|
|
59113
59262
|
if (this._htmlTag) this._htmlTag.destroy();
|
|
59263
|
+
const id = entity.properties.id._value;
|
|
59264
|
+
const comp = id.component;
|
|
59265
|
+
|
|
59266
|
+
let popHtml = `<div class='kq-label-popup' style='background-color:var(--kq-bg-color); border-radius: 8px; padding: 10px;'>
|
|
59267
|
+
<div id='tag_vue_${id.id}'></div>
|
|
59268
|
+
<span class='triangle' ></span>
|
|
59269
|
+
<a class='close' style='color: #757575' href="javascript:void(0)" onclick="document.getElementsByClassName('kq-label-popup')[0].style.display='none';"><span>×</span></a>
|
|
59270
|
+
</div>`;
|
|
59114
59271
|
this._htmlTag = new Cesium.Kq3dHtmlTag(this._viewer, {
|
|
59115
|
-
html: "<div>" + entity.properties.id._value + "</div>",
|
|
59272
|
+
// html: "<div>" + entity.properties.id._value + "</div>",
|
|
59273
|
+
html: popHtml,
|
|
59116
59274
|
position: entity.position,
|
|
59117
|
-
anchor: [0, -entity.properties.height._value],
|
|
59118
|
-
alignmentMode: 7
|
|
59275
|
+
anchor: [0, -entity.properties.height._value - 4],
|
|
59276
|
+
alignmentMode: 7,
|
|
59277
|
+
noEvent: false
|
|
59119
59278
|
});
|
|
59279
|
+
if (comp) {
|
|
59280
|
+
const pop = id.createVNode(id.component, id.componentProps);
|
|
59281
|
+
// 传入外部vue的appContext到createVNode创建的vue组件对象中
|
|
59282
|
+
if (id.appContext) pop.appContext = id.appContext;
|
|
59283
|
+
setTimeout(() => {
|
|
59284
|
+
id.render(pop, document.getElementById("tag_vue_" + id.id));
|
|
59285
|
+
}, 0);
|
|
59286
|
+
}
|
|
59120
59287
|
}
|
|
59121
59288
|
|
|
59122
59289
|
// 通过id打开地理编码图标气泡
|
|
@@ -60852,7 +61019,8 @@ class LayerManager {
|
|
|
60852
61019
|
let that = this;
|
|
60853
61020
|
this._layerListData.forEach(layer => {
|
|
60854
61021
|
if (layer.visible) {
|
|
60855
|
-
layers_checked.push(layer);
|
|
61022
|
+
// layers_checked.push(layer);
|
|
61023
|
+
layers_checked.unshift(layer);
|
|
60856
61024
|
}
|
|
60857
61025
|
}, this);
|
|
60858
61026
|
const layers_old = this._layerListData_old;
|
|
@@ -73807,7 +73975,8 @@ class WindySlicingViewModel {
|
|
|
73807
73975
|
attrRange: [ranges[0], ranges[ranges.length - 1]],
|
|
73808
73976
|
varName: this._windySlicingLayerconfig?.params?.varNames,
|
|
73809
73977
|
};
|
|
73810
|
-
|
|
73978
|
+
Object.assign(this._currentVolumeOption, params || {})
|
|
73979
|
+
return new Cesium.Kq3dGridVolumeProvider(this._currentVolumeOption);
|
|
73811
73980
|
}
|
|
73812
73981
|
/**
|
|
73813
73982
|
* 创建线剖切
|
|
@@ -74368,6 +74537,7 @@ function formatTooltip(val) {
|
|
|
74368
74537
|
}
|
|
74369
74538
|
// 销毁
|
|
74370
74539
|
(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.onBeforeUnmount)(() => {
|
|
74540
|
+
global_event_default().off("windyTypeChange", handleWindyTypeChange);
|
|
74371
74541
|
viewModel && viewModel.destroy();
|
|
74372
74542
|
});
|
|
74373
74543
|
|
|
@@ -75649,22 +75819,6 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__7997__;
|
|
|
75649
75819
|
"use strict";
|
|
75650
75820
|
module.exports = __WEBPACK_EXTERNAL_MODULE__1895__;
|
|
75651
75821
|
|
|
75652
|
-
/***/ }),
|
|
75653
|
-
|
|
75654
|
-
/***/ 6838:
|
|
75655
|
-
/***/ (function(module) {
|
|
75656
|
-
|
|
75657
|
-
"use strict";
|
|
75658
|
-
module.exports = __WEBPACK_EXTERNAL_MODULE__6838__;
|
|
75659
|
-
|
|
75660
|
-
/***/ }),
|
|
75661
|
-
|
|
75662
|
-
/***/ 7747:
|
|
75663
|
-
/***/ (function(module) {
|
|
75664
|
-
|
|
75665
|
-
"use strict";
|
|
75666
|
-
module.exports = __WEBPACK_EXTERNAL_MODULE__7747__;
|
|
75667
|
-
|
|
75668
75822
|
/***/ })
|
|
75669
75823
|
|
|
75670
75824
|
/******/ });
|
|
@@ -75774,7 +75928,7 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__7747__;
|
|
|
75774
75928
|
/******/ // startup
|
|
75775
75929
|
/******/ // Load entry module and return exports
|
|
75776
75930
|
/******/ // This entry module is referenced by other modules so it can't be inlined
|
|
75777
|
-
/******/ var __webpack_exports__ = __webpack_require__(
|
|
75931
|
+
/******/ var __webpack_exports__ = __webpack_require__(5603);
|
|
75778
75932
|
/******/
|
|
75779
75933
|
/******/ return __webpack_exports__;
|
|
75780
75934
|
/******/ })()
|