@kq_npm/client3d_webgl_vue 4.5.31 → 4.5.32
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 +226 -495
- package/aspectanalysis/index.js +71 -182
- package/baseterraingallery/index.js +40 -102
- package/boxclip/index.js +197 -423
- package/clientPrint/index.js +6953 -17145
- package/comparemap/index.js +165 -216
- package/compass/index.js +20 -47
- package/excavatefillanalysis/index.js +101 -206
- package/fixedzoomin/index.js +20 -43
- package/fixedzoomout/index.js +18 -42
- package/flight/index.js +206 -353
- package/floodanalysis/index.js +145 -328
- package/geologicalbodyanalysis/index.js +114 -241
- package/gpuspatialquery/index.js +146 -340
- package/hawkeye/index.js +78 -80
- package/headertemp/index.js +8 -19
- package/heatmap3d/index.js +304 -645
- package/index.js +6525 -16962
- package/isolineanalysis/index.js +451 -1183
- package/light/index.js +308 -486
- package/limitheightanalysis/index.js +107 -204
- package/measure/index.js +145 -331
- package/modelFlat/index.js +114 -183
- package/modelexcavate/index.js +78 -172
- package/modelfilter/index.js +127 -252
- package/modelprofileanalysis/index.js +154 -297
- package/modelselect/index.js +90 -128
- package/package.json +1 -1
- package/particleeffect/index.js +170 -381
- package/planeclip/index.js +146 -281
- package/resetview/index.js +12 -31
- package/roller/index.js +252 -353
- package/scaneffect/index.js +178 -518
- package/sceneadvancedtoimage/index.js +152 -337
- package/sceneapp/index.js +6953 -17145
- package/sceneset/index.js +299 -838
- package/scenetohdimage/index.js +105 -276
- package/sceneview/index.js +6953 -17145
- package/screenshot/index.js +204 -281
- package/shadowanalysis/index.js +175 -386
- package/sightlineanalysis/index.js +135 -245
- package/skylineanalysis/index.js +108 -289
- package/slopeanalysis/index.js +174 -378
- package/slopeaspectanalysis/index.js +206 -466
- package/statusbar/index.js +37 -39
- package/terrainoperation/index.js +124 -218
- package/terrainprofileanalysis/index.js +66 -118
- package/typhoontrac/index.js +165 -321
- package/underground/index.js +16 -40
- package/videofusion/index.js +214 -470
- package/videoproject/index.js +220 -472
- package/viewshedanalysis/index.js +93 -230
- package/weathereffect/index.js +111 -295
- package/windyslicing/index.js +262 -695
- package/wireframesketch/index.js +49 -106
package/adddata/index.js
CHANGED
|
@@ -19,18 +19,16 @@ return /******/ (function() { // webpackBootstrap
|
|
|
19
19
|
/* harmony import */ var element_plus_dist_index_full_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(element_plus_dist_index_full_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
20
20
|
/* harmony import */ var _init__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7997);
|
|
21
21
|
/* harmony import */ var _init__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_init__WEBPACK_IMPORTED_MODULE_1__);
|
|
22
|
-
/*
|
|
23
|
-
* Copyright (C) 2019 KQ GEO Technologies Co., Ltd.
|
|
24
|
-
* All rights reserved.
|
|
22
|
+
/*
|
|
23
|
+
* Copyright (C) 2019 KQ GEO Technologies Co., Ltd.
|
|
24
|
+
* All rights reserved.
|
|
25
25
|
*/
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
|
|
29
28
|
element_plus_dist_index_full_js__WEBPACK_IMPORTED_MODULE_0__.ElMessage.install = (Vue, opts) => {
|
|
30
29
|
_init__WEBPACK_IMPORTED_MODULE_1___default()(Vue, opts);
|
|
31
30
|
Vue.component("KqMessage", element_plus_dist_index_full_js__WEBPACK_IMPORTED_MODULE_0__.ElMessage);
|
|
32
31
|
};
|
|
33
|
-
|
|
34
32
|
/* harmony default export */ __webpack_exports__["Z"] = (element_plus_dist_index_full_js__WEBPACK_IMPORTED_MODULE_0__.ElMessage);
|
|
35
33
|
|
|
36
34
|
/***/ }),
|
|
@@ -56,6 +54,62 @@ module.exports = require("core-js/modules/es.array.includes.js");
|
|
|
56
54
|
|
|
57
55
|
/***/ }),
|
|
58
56
|
|
|
57
|
+
/***/ 2118:
|
|
58
|
+
/***/ (function(module) {
|
|
59
|
+
|
|
60
|
+
module.exports = require("core-js/modules/es.array.push.js");
|
|
61
|
+
|
|
62
|
+
/***/ }),
|
|
63
|
+
|
|
64
|
+
/***/ 1627:
|
|
65
|
+
/***/ (function(module) {
|
|
66
|
+
|
|
67
|
+
module.exports = require("core-js/modules/es.array.unshift.js");
|
|
68
|
+
|
|
69
|
+
/***/ }),
|
|
70
|
+
|
|
71
|
+
/***/ 8470:
|
|
72
|
+
/***/ (function(module) {
|
|
73
|
+
|
|
74
|
+
module.exports = require("core-js/modules/esnext.iterator.constructor.js");
|
|
75
|
+
|
|
76
|
+
/***/ }),
|
|
77
|
+
|
|
78
|
+
/***/ 2753:
|
|
79
|
+
/***/ (function(module) {
|
|
80
|
+
|
|
81
|
+
module.exports = require("core-js/modules/esnext.iterator.filter.js");
|
|
82
|
+
|
|
83
|
+
/***/ }),
|
|
84
|
+
|
|
85
|
+
/***/ 1058:
|
|
86
|
+
/***/ (function(module) {
|
|
87
|
+
|
|
88
|
+
module.exports = require("core-js/modules/esnext.iterator.for-each.js");
|
|
89
|
+
|
|
90
|
+
/***/ }),
|
|
91
|
+
|
|
92
|
+
/***/ 4360:
|
|
93
|
+
/***/ (function(module) {
|
|
94
|
+
|
|
95
|
+
module.exports = require("core-js/modules/web.url-search-params.delete.js");
|
|
96
|
+
|
|
97
|
+
/***/ }),
|
|
98
|
+
|
|
99
|
+
/***/ 8824:
|
|
100
|
+
/***/ (function(module) {
|
|
101
|
+
|
|
102
|
+
module.exports = require("core-js/modules/web.url-search-params.has.js");
|
|
103
|
+
|
|
104
|
+
/***/ }),
|
|
105
|
+
|
|
106
|
+
/***/ 2936:
|
|
107
|
+
/***/ (function(module) {
|
|
108
|
+
|
|
109
|
+
module.exports = require("core-js/modules/web.url-search-params.size.js");
|
|
110
|
+
|
|
111
|
+
/***/ }),
|
|
112
|
+
|
|
59
113
|
/***/ 9389:
|
|
60
114
|
/***/ (function(module) {
|
|
61
115
|
|
|
@@ -129,7 +183,6 @@ function _defineProperty(obj, key, value) {
|
|
|
129
183
|
} else {
|
|
130
184
|
obj[key] = value;
|
|
131
185
|
}
|
|
132
|
-
|
|
133
186
|
return obj;
|
|
134
187
|
}
|
|
135
188
|
|
|
@@ -217,6 +270,12 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
217
270
|
|
|
218
271
|
// EXTERNAL MODULE: external "core-js/modules/es.array.includes.js"
|
|
219
272
|
var es_array_includes_js_ = __webpack_require__(3600);
|
|
273
|
+
// EXTERNAL MODULE: external "core-js/modules/es.array.push.js"
|
|
274
|
+
var es_array_push_js_ = __webpack_require__(2118);
|
|
275
|
+
// EXTERNAL MODULE: external "core-js/modules/esnext.iterator.constructor.js"
|
|
276
|
+
var esnext_iterator_constructor_js_ = __webpack_require__(8470);
|
|
277
|
+
// EXTERNAL MODULE: external "core-js/modules/esnext.iterator.for-each.js"
|
|
278
|
+
var esnext_iterator_for_each_js_ = __webpack_require__(1058);
|
|
220
279
|
// EXTERNAL MODULE: external {"root":"Vue","commonjs":"vue","commonjs2":"vue","amd":"vue"}
|
|
221
280
|
var external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_ = __webpack_require__(1895);
|
|
222
281
|
// EXTERNAL MODULE: external "@element-plus/icons-vue"
|
|
@@ -227,6 +286,16 @@ var client_icons_vue_ = __webpack_require__(348);
|
|
|
227
286
|
var gis_utils_ = __webpack_require__(7135);
|
|
228
287
|
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/defineProperty.js
|
|
229
288
|
var defineProperty = __webpack_require__(8270);
|
|
289
|
+
// EXTERNAL MODULE: external "core-js/modules/es.array.unshift.js"
|
|
290
|
+
var es_array_unshift_js_ = __webpack_require__(1627);
|
|
291
|
+
// EXTERNAL MODULE: external "core-js/modules/esnext.iterator.filter.js"
|
|
292
|
+
var esnext_iterator_filter_js_ = __webpack_require__(2753);
|
|
293
|
+
// EXTERNAL MODULE: external "core-js/modules/web.url-search-params.delete.js"
|
|
294
|
+
var web_url_search_params_delete_js_ = __webpack_require__(4360);
|
|
295
|
+
// EXTERNAL MODULE: external "core-js/modules/web.url-search-params.has.js"
|
|
296
|
+
var web_url_search_params_has_js_ = __webpack_require__(8824);
|
|
297
|
+
// EXTERNAL MODULE: external "core-js/modules/web.url-search-params.size.js"
|
|
298
|
+
var web_url_search_params_size_js_ = __webpack_require__(2936);
|
|
230
299
|
// EXTERNAL MODULE: external "@kq_npm/client_common_vue/_utils/webmapservice"
|
|
231
300
|
var webmapservice_ = __webpack_require__(3217);
|
|
232
301
|
var webmapservice_default = /*#__PURE__*/__webpack_require__.n(webmapservice_);
|
|
@@ -242,6 +311,13 @@ var external_papaparse_default = /*#__PURE__*/__webpack_require__.n(external_pap
|
|
|
242
311
|
;// CONCATENATED MODULE: ./src/webgl/adddata/AddDataViewModel.js
|
|
243
312
|
|
|
244
313
|
|
|
314
|
+
|
|
315
|
+
|
|
316
|
+
|
|
317
|
+
|
|
318
|
+
|
|
319
|
+
|
|
320
|
+
|
|
245
321
|
/*
|
|
246
322
|
* Copyright (C) 2019 KQ GEO Technologies Co., Ltd.
|
|
247
323
|
* All rights reserved.
|
|
@@ -250,16 +326,14 @@ var external_papaparse_default = /*#__PURE__*/__webpack_require__.n(external_pap
|
|
|
250
326
|
|
|
251
327
|
|
|
252
328
|
|
|
253
|
-
//添加数据逻辑类
|
|
254
329
|
|
|
330
|
+
|
|
331
|
+
//添加数据逻辑类
|
|
255
332
|
class AddDataViewModel {
|
|
256
333
|
constructor(scenceView, options) {
|
|
257
334
|
(0,defineProperty/* default */.Z)(this, "_viewer", null);
|
|
258
|
-
|
|
259
335
|
(0,defineProperty/* default */.Z)(this, "_layerManager", null);
|
|
260
|
-
|
|
261
336
|
(0,defineProperty/* default */.Z)(this, "_language", null);
|
|
262
|
-
|
|
263
337
|
(0,defineProperty/* default */.Z)(this, "_geojsonStyle", {
|
|
264
338
|
label: {
|
|
265
339
|
express: "name",
|
|
@@ -273,15 +347,15 @@ class AddDataViewModel {
|
|
|
273
347
|
style: Cesium.LabelStyle.FILL_AND_OUTLINE,
|
|
274
348
|
eyeOffset: Cesium.Cartesian3.ZERO,
|
|
275
349
|
pixelOffset: new Cesium.Cartesian2(0, -8),
|
|
276
|
-
disableDepthTestDistance: 10000000
|
|
277
|
-
|
|
350
|
+
disableDepthTestDistance: 10000000
|
|
351
|
+
// disableDepthTestDistance: Number.POSITIVE_INFINITY
|
|
278
352
|
},
|
|
279
353
|
billboard: {
|
|
280
354
|
image: const_image_.BILLBOARD_IMAGE_URL,
|
|
281
355
|
width: 12,
|
|
282
356
|
height: 12,
|
|
283
|
-
disableDepthTestDistance: 10000000
|
|
284
|
-
|
|
357
|
+
disableDepthTestDistance: 10000000
|
|
358
|
+
// disableDepthTestDistance: Number.POSITIVE_INFINITY
|
|
285
359
|
},
|
|
286
360
|
polyline: {
|
|
287
361
|
width: 2.0,
|
|
@@ -296,23 +370,20 @@ class AddDataViewModel {
|
|
|
296
370
|
perPositionHeight: false
|
|
297
371
|
}
|
|
298
372
|
});
|
|
299
|
-
|
|
300
373
|
this._viewer = scenceView._viewer;
|
|
301
374
|
this._layerManager = scenceView._layerManager;
|
|
302
375
|
this._language = scenceView._language;
|
|
303
376
|
this._geometryServerUrl = options.geometryServerUrl;
|
|
304
377
|
this._geometryServerToken = options.geometryServerToken;
|
|
305
378
|
if (options.geojsonStyle) this._geojsonStyle = Object.assign({}, this._geojsonStyle, options.geojsonStyle);
|
|
306
|
-
}
|
|
307
|
-
|
|
379
|
+
}
|
|
308
380
|
|
|
381
|
+
//解析文件
|
|
309
382
|
parseFile(file, cb) {
|
|
310
383
|
var that = this;
|
|
311
384
|
return new Promise((resolve, reject) => {
|
|
312
385
|
var ext = file.name.replace(/.+\./, "").toLowerCase(); //文件扩展名
|
|
313
|
-
|
|
314
386
|
var name = file.name.replace(/(.*\/)*([^.]+).*/gi, "$2"); //文件名
|
|
315
|
-
|
|
316
387
|
if (ext === "zip") {
|
|
317
388
|
(0,util_.uploadSHP)(file, function (res) {
|
|
318
389
|
if (res) {
|
|
@@ -328,10 +399,8 @@ class AddDataViewModel {
|
|
|
328
399
|
};
|
|
329
400
|
}
|
|
330
401
|
});
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
402
|
+
that._viewer.dataSources.add(ds);
|
|
403
|
+
// ds.autoAvoid(that._viewer);
|
|
335
404
|
that.flyToLayer(ds);
|
|
336
405
|
resolve("success");
|
|
337
406
|
var layer = {
|
|
@@ -344,9 +413,7 @@ class AddDataViewModel {
|
|
|
344
413
|
addType: "geojson",
|
|
345
414
|
shapeType: that._layerManager.getShapeType(ds)
|
|
346
415
|
};
|
|
347
|
-
|
|
348
416
|
that._layerManager.addTempLayerNode(layer);
|
|
349
|
-
|
|
350
417
|
cb && cb(layer);
|
|
351
418
|
});
|
|
352
419
|
} else {
|
|
@@ -370,10 +437,8 @@ class AddDataViewModel {
|
|
|
370
437
|
};
|
|
371
438
|
}
|
|
372
439
|
});
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
440
|
+
that._viewer.dataSources.add(ds);
|
|
441
|
+
// ds.autoAvoid(that._viewer);
|
|
377
442
|
that.flyToLayer(ds);
|
|
378
443
|
resolve("success");
|
|
379
444
|
var layer = {
|
|
@@ -386,9 +451,7 @@ class AddDataViewModel {
|
|
|
386
451
|
addType: "geojson",
|
|
387
452
|
shapeType: that._layerManager.getShapeType(ds)
|
|
388
453
|
};
|
|
389
|
-
|
|
390
454
|
that._layerManager.addTempLayerNode(layer);
|
|
391
|
-
|
|
392
455
|
cb && cb(layer);
|
|
393
456
|
});
|
|
394
457
|
} else {
|
|
@@ -406,13 +469,11 @@ class AddDataViewModel {
|
|
|
406
469
|
type: "FeatureCollection",
|
|
407
470
|
features: []
|
|
408
471
|
};
|
|
409
|
-
|
|
410
472
|
for (var i = 0; i < features.length; i++) {
|
|
411
473
|
let item = features[i];
|
|
412
474
|
let lat = null;
|
|
413
475
|
let lng = null;
|
|
414
476
|
let properties = {};
|
|
415
|
-
|
|
416
477
|
for (var j in item) {
|
|
417
478
|
if (j.toUpperCase().indexOf("LAT") != -1) {
|
|
418
479
|
lat = item[j];
|
|
@@ -425,9 +486,8 @@ class AddDataViewModel {
|
|
|
425
486
|
} else {
|
|
426
487
|
properties[j] = item[j];
|
|
427
488
|
}
|
|
428
|
-
}
|
|
429
|
-
|
|
430
|
-
|
|
489
|
+
}
|
|
490
|
+
// 点数据
|
|
431
491
|
if (lat && lng) {
|
|
432
492
|
let _point = {
|
|
433
493
|
type: "Feature",
|
|
@@ -437,11 +497,9 @@ class AddDataViewModel {
|
|
|
437
497
|
},
|
|
438
498
|
properties: properties
|
|
439
499
|
};
|
|
440
|
-
|
|
441
500
|
_featureCollection.features.push(_point);
|
|
442
501
|
} else {}
|
|
443
502
|
}
|
|
444
|
-
|
|
445
503
|
if (_featureCollection.features.length > 0) {
|
|
446
504
|
var ds = new Cesium.Kq3dGeoJsonDataSource(name);
|
|
447
505
|
ds.load(_featureCollection, that._geojsonStyle).then(ds => {
|
|
@@ -455,9 +513,7 @@ class AddDataViewModel {
|
|
|
455
513
|
};
|
|
456
514
|
}
|
|
457
515
|
});
|
|
458
|
-
|
|
459
516
|
that._viewer.dataSources.add(ds);
|
|
460
|
-
|
|
461
517
|
that.flyToLayer(ds);
|
|
462
518
|
resolve("success");
|
|
463
519
|
var layer = {
|
|
@@ -470,9 +526,7 @@ class AddDataViewModel {
|
|
|
470
526
|
addType: "geojson",
|
|
471
527
|
shapeType: that._layerManager.getShapeType(ds)
|
|
472
528
|
};
|
|
473
|
-
|
|
474
529
|
that._layerManager.addTempLayerNode(layer);
|
|
475
|
-
|
|
476
530
|
cb && cb(layer);
|
|
477
531
|
});
|
|
478
532
|
} else {
|
|
@@ -495,9 +549,7 @@ class AddDataViewModel {
|
|
|
495
549
|
};
|
|
496
550
|
}
|
|
497
551
|
});
|
|
498
|
-
|
|
499
552
|
that._viewer.dataSources.add(ds);
|
|
500
|
-
|
|
501
553
|
that.flyToLayer(ds);
|
|
502
554
|
resolve("success");
|
|
503
555
|
var layer = {
|
|
@@ -510,9 +562,7 @@ class AddDataViewModel {
|
|
|
510
562
|
addType: "geojson",
|
|
511
563
|
shapeType: that._layerManager.getShapeType(ds)
|
|
512
564
|
};
|
|
513
|
-
|
|
514
565
|
that._layerManager.addTempLayerNode(layer);
|
|
515
|
-
|
|
516
566
|
cb && cb(layer);
|
|
517
567
|
});
|
|
518
568
|
} else {
|
|
@@ -527,11 +577,9 @@ class AddDataViewModel {
|
|
|
527
577
|
if (res.features && res.features.type === "processFailed") {
|
|
528
578
|
reject(file.uid);
|
|
529
579
|
}
|
|
530
|
-
|
|
531
580
|
if (res.srs) {
|
|
532
581
|
delete res.srs;
|
|
533
582
|
}
|
|
534
|
-
|
|
535
583
|
var ds = new Cesium.Kq3dGeoJsonDataSource(name);
|
|
536
584
|
ds.load(res, that._geojsonStyle).then(ds => {
|
|
537
585
|
ds.entities.values.forEach(entity => {
|
|
@@ -544,9 +592,7 @@ class AddDataViewModel {
|
|
|
544
592
|
};
|
|
545
593
|
}
|
|
546
594
|
});
|
|
547
|
-
|
|
548
595
|
that._viewer.dataSources.add(ds);
|
|
549
|
-
|
|
550
596
|
that.flyToLayer(ds);
|
|
551
597
|
resolve("success");
|
|
552
598
|
var layer = {
|
|
@@ -559,9 +605,7 @@ class AddDataViewModel {
|
|
|
559
605
|
addType: "geojson",
|
|
560
606
|
shapeType: that._layerManager.getShapeType(ds)
|
|
561
607
|
};
|
|
562
|
-
|
|
563
608
|
that._layerManager.addTempLayerNode(layer);
|
|
564
|
-
|
|
565
609
|
cb && cb(layer);
|
|
566
610
|
});
|
|
567
611
|
} else {
|
|
@@ -575,36 +619,31 @@ class AddDataViewModel {
|
|
|
575
619
|
//readAsArrayBuffer(file); //原始二进制数据
|
|
576
620
|
//readAsBinaryString(file);//二进制字符串
|
|
577
621
|
//reader.readAsBinaryString(file);
|
|
578
|
-
|
|
579
622
|
reader.onload = function (event) {
|
|
580
623
|
var ret = event.target.result;
|
|
581
|
-
|
|
582
624
|
switch (ext) {
|
|
583
625
|
case "json":
|
|
584
626
|
case "geojson":
|
|
585
627
|
case "topojson":
|
|
586
628
|
ret = ret.replace(/(^\s*)|(\s*$)/, "");
|
|
587
629
|
ret = ret.substring(ret.indexOf("{"));
|
|
588
|
-
|
|
589
630
|
try {
|
|
590
631
|
var data = JSON.parse(ret);
|
|
591
|
-
|
|
592
632
|
if (typeof data == "object" && data) {
|
|
593
633
|
ret = data;
|
|
594
634
|
}
|
|
595
635
|
} catch (e) {}
|
|
596
|
-
|
|
597
|
-
|
|
636
|
+
var style = {
|
|
637
|
+
...that._geojsonStyle
|
|
598
638
|
};
|
|
599
639
|
var ds = new Cesium.Kq3dGeoJsonDataSource(name);
|
|
600
|
-
var addType = "geojson";
|
|
601
|
-
|
|
640
|
+
var addType = "geojson";
|
|
641
|
+
// 判断是否是arcgis格式的json数据
|
|
602
642
|
if (ret.geometryType) {
|
|
603
643
|
ds = new Cesium.Kq3dEsriGeoJsonDataSource(name);
|
|
604
644
|
style.label.express = "NAME";
|
|
605
645
|
addType = "arcjson";
|
|
606
646
|
}
|
|
607
|
-
|
|
608
647
|
ds.load(ret, style).then(ds => {
|
|
609
648
|
ds.entities.values.forEach(entity => {
|
|
610
649
|
if (entity.polygon) {
|
|
@@ -616,10 +655,8 @@ class AddDataViewModel {
|
|
|
616
655
|
};
|
|
617
656
|
}
|
|
618
657
|
});
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
658
|
+
that._viewer.dataSources.add(ds);
|
|
659
|
+
// ds.autoAvoid(that._viewer);
|
|
623
660
|
that.flyToLayer(ds);
|
|
624
661
|
resolve("success");
|
|
625
662
|
var layer = {
|
|
@@ -632,13 +669,10 @@ class AddDataViewModel {
|
|
|
632
669
|
addType: addType,
|
|
633
670
|
shapeType: that._layerManager.getShapeType(ds)
|
|
634
671
|
};
|
|
635
|
-
|
|
636
672
|
that._layerManager.addTempLayerNode(layer);
|
|
637
|
-
|
|
638
673
|
cb && cb(layer);
|
|
639
674
|
});
|
|
640
675
|
break;
|
|
641
|
-
|
|
642
676
|
case "kml":
|
|
643
677
|
ret = ret.replace(/(^\s*)|(\s*$)/, "");
|
|
644
678
|
var options = {
|
|
@@ -652,7 +686,6 @@ class AddDataViewModel {
|
|
|
652
686
|
});
|
|
653
687
|
ds.load(data).then(ds => {
|
|
654
688
|
that._viewer.dataSources.add(ds);
|
|
655
|
-
|
|
656
689
|
that.flyToLayer(ds);
|
|
657
690
|
resolve("success");
|
|
658
691
|
var layer = {
|
|
@@ -664,13 +697,10 @@ class AddDataViewModel {
|
|
|
664
697
|
url: data,
|
|
665
698
|
addType: "kml"
|
|
666
699
|
};
|
|
667
|
-
|
|
668
700
|
that._layerManager.addTempLayerNode(layer);
|
|
669
|
-
|
|
670
701
|
cb && cb(layer);
|
|
671
702
|
});
|
|
672
703
|
break;
|
|
673
|
-
|
|
674
704
|
case "kmz":
|
|
675
705
|
var options = {
|
|
676
706
|
name: name,
|
|
@@ -680,7 +710,6 @@ class AddDataViewModel {
|
|
|
680
710
|
var ds = new Cesium.KmlDataSource(options);
|
|
681
711
|
ds.load(file).then(ds => {
|
|
682
712
|
that._viewer.dataSources.add(ds);
|
|
683
|
-
|
|
684
713
|
that.flyToLayer(ds);
|
|
685
714
|
resolve("success");
|
|
686
715
|
var layer = {
|
|
@@ -692,34 +721,25 @@ class AddDataViewModel {
|
|
|
692
721
|
url: file,
|
|
693
722
|
addType: "kml"
|
|
694
723
|
};
|
|
695
|
-
|
|
696
724
|
that._layerManager.addTempLayerNode(layer);
|
|
697
|
-
|
|
698
725
|
cb && cb(layer);
|
|
699
726
|
});
|
|
700
727
|
break;
|
|
701
|
-
|
|
702
728
|
case "czml":
|
|
703
729
|
ret = ret.replace(/(^\s*)|(\s*$)/, "");
|
|
704
|
-
|
|
705
730
|
try {
|
|
706
731
|
var data = JSON.parse(ret);
|
|
707
|
-
|
|
708
732
|
if (typeof data == "object" && data) {
|
|
709
733
|
ret = data;
|
|
710
734
|
}
|
|
711
735
|
} catch (e) {}
|
|
712
|
-
|
|
713
736
|
if (that._viewer.timeline.container.style.display != 'block') {
|
|
714
737
|
that._viewer.bottomContainer.style.bottom = '15px';
|
|
715
738
|
that._viewer.timeline.container.style.display = 'block';
|
|
716
739
|
that._viewer.animation.container.style.display = 'block';
|
|
717
|
-
|
|
718
740
|
that._viewer.animation.resize();
|
|
719
|
-
|
|
720
741
|
that._viewer.clock.shouldAnimate = true;
|
|
721
742
|
}
|
|
722
|
-
|
|
723
743
|
that._viewer.dataSources.add(Cesium.CzmlDataSource.load(ret, {
|
|
724
744
|
name: name
|
|
725
745
|
})).then(ds => {
|
|
@@ -734,53 +754,39 @@ class AddDataViewModel {
|
|
|
734
754
|
url: ret,
|
|
735
755
|
addType: "czml"
|
|
736
756
|
};
|
|
737
|
-
|
|
738
757
|
that._layerManager.addTempLayerNode(layer);
|
|
739
|
-
|
|
740
758
|
cb && cb(layer);
|
|
741
759
|
});
|
|
742
|
-
|
|
743
760
|
break;
|
|
744
|
-
|
|
745
761
|
case "kqgeobody":
|
|
746
762
|
ret = ret.replace(/(^\s*)|(\s*$)/, "");
|
|
747
|
-
|
|
748
763
|
try {
|
|
749
764
|
let data = JSON.parse(ret);
|
|
750
|
-
|
|
751
765
|
if (Array.isArray(data)) {
|
|
752
766
|
ret = data;
|
|
753
767
|
}
|
|
754
768
|
} catch (e) {}
|
|
755
|
-
|
|
756
769
|
let geology = new Cesium.Kq3dGeologyBody({
|
|
757
770
|
viewer: that._viewer
|
|
758
771
|
});
|
|
759
772
|
geology.name = name;
|
|
760
|
-
|
|
761
773
|
that._viewer.geologyBodyCollection.push(geology);
|
|
762
|
-
|
|
763
774
|
geology.createGeology(ret).then(function (geobody) {
|
|
764
775
|
if (!geobody.viewer.scene.primitives.contains(geobody.geologyPrimitives)) {
|
|
765
776
|
geobody.geologyPrimitives = geobody.viewer.scene.primitives.add(geobody.geologyPrimitiveCollection);
|
|
766
777
|
}
|
|
767
|
-
|
|
768
778
|
let boundingSpheres = [];
|
|
769
|
-
|
|
770
779
|
geobody.geologyPrimitives._primitives.forEach(primitive => {
|
|
771
780
|
if (primitive.geometryInstances.geometry.boundingSphere) {
|
|
772
781
|
boundingSpheres = boundingSpheres.concat(primitive.geometryInstances.geometry.boundingSphere);
|
|
773
782
|
}
|
|
774
783
|
});
|
|
775
|
-
|
|
776
784
|
if (boundingSpheres.length > 0) {
|
|
777
785
|
let boundingSphere = Cesium.BoundingSphere.fromBoundingSpheres(boundingSpheres);
|
|
778
|
-
|
|
779
786
|
that._viewer.camera.flyToBoundingSphere(boundingSphere, {
|
|
780
787
|
offset: new Cesium.HeadingPitchRange(0.0, Cesium.Math.toRadians(-90.0), boundingSphere.radius * 3)
|
|
781
788
|
});
|
|
782
789
|
}
|
|
783
|
-
|
|
784
790
|
resolve("success");
|
|
785
791
|
var layer = {
|
|
786
792
|
guid: geology.geologyPrimitiveCollection._guid,
|
|
@@ -791,33 +797,27 @@ class AddDataViewModel {
|
|
|
791
797
|
url: ret,
|
|
792
798
|
addType: "kqgeobody"
|
|
793
799
|
};
|
|
794
|
-
|
|
795
800
|
that._layerManager.addTempLayerNode(layer);
|
|
796
|
-
|
|
797
801
|
cb && cb(layer);
|
|
798
802
|
});
|
|
799
803
|
break;
|
|
800
|
-
|
|
801
804
|
default:
|
|
802
805
|
break;
|
|
803
806
|
}
|
|
804
807
|
};
|
|
805
|
-
|
|
806
808
|
reader.onerror = function () {
|
|
807
809
|
console.log(file.name + " read error.");
|
|
808
810
|
reject(file.name + " read error.");
|
|
809
811
|
};
|
|
810
812
|
}
|
|
811
813
|
});
|
|
812
|
-
}
|
|
813
|
-
|
|
814
|
+
}
|
|
814
815
|
|
|
816
|
+
//解析数据源
|
|
815
817
|
parseDataSource(options, cb, loadCustom) {
|
|
816
818
|
options = options || {};
|
|
817
|
-
|
|
818
819
|
if (options.url && options.url !== "") {
|
|
819
820
|
let url = options.url;
|
|
820
|
-
|
|
821
821
|
if (options.type === "stkterrain") {
|
|
822
822
|
if (url.indexOf("?") > 0) {
|
|
823
823
|
url = url.replace("?", "layer.json?");
|
|
@@ -825,7 +825,6 @@ class AddDataViewModel {
|
|
|
825
825
|
url += "layer.json";
|
|
826
826
|
}
|
|
827
827
|
}
|
|
828
|
-
|
|
829
828
|
try {
|
|
830
829
|
new URL(url);
|
|
831
830
|
} catch (error) {
|
|
@@ -835,12 +834,10 @@ class AddDataViewModel {
|
|
|
835
834
|
});
|
|
836
835
|
return;
|
|
837
836
|
}
|
|
838
|
-
|
|
839
837
|
if (options.type === "kml") {
|
|
840
838
|
this.parseService(options, cb, loadCustom);
|
|
841
839
|
return;
|
|
842
840
|
}
|
|
843
|
-
|
|
844
841
|
fetch(url).then(data => {
|
|
845
842
|
return data;
|
|
846
843
|
}).then(data => {
|
|
@@ -866,24 +863,21 @@ class AddDataViewModel {
|
|
|
866
863
|
type: "warning"
|
|
867
864
|
});
|
|
868
865
|
}
|
|
869
|
-
}
|
|
870
|
-
|
|
866
|
+
}
|
|
871
867
|
|
|
868
|
+
//解析服务
|
|
872
869
|
parseService(options, cb, loadCustom) {
|
|
873
870
|
let that = this;
|
|
874
871
|
let url = options.url;
|
|
875
872
|
let type = options.type || "";
|
|
876
873
|
type = type.toLowerCase();
|
|
877
874
|
let name = options.name;
|
|
878
|
-
|
|
879
875
|
if (!name || name === "") {
|
|
880
876
|
let ext;
|
|
881
|
-
|
|
882
877
|
if (url.lastIndexOf(".") > url.lastIndexOf("/")) {
|
|
883
878
|
ext = url.substring(url.lastIndexOf(".") + 1);
|
|
884
879
|
ext = ext.toLowerCase();
|
|
885
880
|
}
|
|
886
|
-
|
|
887
881
|
if (["kml", "kmz", "czml", "geojson", "json", "topojson"].indexOf(ext) > -1) {
|
|
888
882
|
name = url.substring(url.lastIndexOf("/") + 1);
|
|
889
883
|
} else {
|
|
@@ -893,9 +887,7 @@ class AddDataViewModel {
|
|
|
893
887
|
}
|
|
894
888
|
}
|
|
895
889
|
}
|
|
896
|
-
|
|
897
890
|
let node, layer;
|
|
898
|
-
|
|
899
891
|
switch (type) {
|
|
900
892
|
case "kq3dimageryfile":
|
|
901
893
|
//影像瓦片文件
|
|
@@ -913,21 +905,16 @@ class AddDataViewModel {
|
|
|
913
905
|
url: url,
|
|
914
906
|
addType: type
|
|
915
907
|
};
|
|
916
|
-
|
|
917
908
|
this._layerManager.addTempLayerNode(node);
|
|
918
|
-
|
|
919
909
|
cb && cb(node);
|
|
920
910
|
break;
|
|
921
|
-
|
|
922
911
|
case "obterrain":
|
|
923
912
|
//ob地形瓦片文件
|
|
924
913
|
layer = new Cesium.Kq3dFileTerrainProvider({
|
|
925
914
|
name: name,
|
|
926
915
|
url: url
|
|
927
916
|
});
|
|
928
|
-
|
|
929
917
|
this._layerManager.setTerrain(layer);
|
|
930
|
-
|
|
931
918
|
this.flyToLayer(layer);
|
|
932
919
|
if (!layer.guid) layer.guid = Cesium.createGuid();
|
|
933
920
|
node = {
|
|
@@ -939,14 +926,10 @@ class AddDataViewModel {
|
|
|
939
926
|
url: url,
|
|
940
927
|
addType: type
|
|
941
928
|
};
|
|
942
|
-
|
|
943
929
|
this._layerManager.addTempLayerNode(node);
|
|
944
|
-
|
|
945
930
|
this._layerManager._terrainProviders.push(layer);
|
|
946
|
-
|
|
947
931
|
cb && cb(node);
|
|
948
932
|
break;
|
|
949
|
-
|
|
950
933
|
case "stkterrain":
|
|
951
934
|
//stk地形瓦片文件
|
|
952
935
|
layer = new Cesium.CesiumTerrainProvider({
|
|
@@ -956,9 +939,7 @@ class AddDataViewModel {
|
|
|
956
939
|
requestWaterMask: false
|
|
957
940
|
});
|
|
958
941
|
if (!layer.guid) layer.guid = Cesium.createGuid();
|
|
959
|
-
|
|
960
942
|
this._layerManager.setTerrain(layer);
|
|
961
|
-
|
|
962
943
|
this.flyToLayer(layer);
|
|
963
944
|
node = {
|
|
964
945
|
guid: layer.guid,
|
|
@@ -969,20 +950,15 @@ class AddDataViewModel {
|
|
|
969
950
|
url: url,
|
|
970
951
|
addType: type
|
|
971
952
|
};
|
|
972
|
-
|
|
973
953
|
this._layerManager.addTempLayerNode(node);
|
|
974
|
-
|
|
975
954
|
this._layerManager._terrainProviders.push(layer);
|
|
976
|
-
|
|
977
955
|
cb && cb(node);
|
|
978
956
|
break;
|
|
979
|
-
|
|
980
957
|
case "3dtiles":
|
|
981
958
|
var tileset = this._viewer.scene.primitives.add(new Cesium.Cesium3DTileset({
|
|
982
959
|
name: name,
|
|
983
960
|
url: url
|
|
984
961
|
}));
|
|
985
|
-
|
|
986
962
|
this.flyToLayer(tileset);
|
|
987
963
|
node = {
|
|
988
964
|
guid: tileset.guid,
|
|
@@ -993,22 +969,18 @@ class AddDataViewModel {
|
|
|
993
969
|
url: url,
|
|
994
970
|
addType: type
|
|
995
971
|
};
|
|
996
|
-
|
|
997
972
|
this._layerManager.addTempLayerNode(node);
|
|
998
|
-
|
|
999
973
|
cb && cb(node);
|
|
1000
974
|
break;
|
|
1001
|
-
|
|
1002
975
|
case "kqgis3dserver":
|
|
1003
976
|
// KQGIS 三维服务
|
|
1004
|
-
var geojsonStyle0 = {
|
|
977
|
+
var geojsonStyle0 = {
|
|
978
|
+
...this._geojsonStyle
|
|
1005
979
|
};
|
|
1006
|
-
|
|
1007
980
|
this._viewer.addKq3dServerLayerGroupExt(url, {
|
|
1008
981
|
geojsonStyle: geojsonStyle0
|
|
1009
982
|
}).then(group => {
|
|
1010
983
|
var layers = group._addedLayers || group._layers;
|
|
1011
|
-
|
|
1012
984
|
if (layers && layers.length > 0) {
|
|
1013
985
|
node = {
|
|
1014
986
|
guid: group.guid,
|
|
@@ -1019,7 +991,6 @@ class AddDataViewModel {
|
|
|
1019
991
|
var serverType = "";
|
|
1020
992
|
var addType = "";
|
|
1021
993
|
let promiseList = [];
|
|
1022
|
-
|
|
1023
994
|
for (var i = 0; i < layers.length; i++) {
|
|
1024
995
|
if (layers[i] instanceof Cesium.Cesium3DTileset) {
|
|
1025
996
|
serverType = "3dtiles";
|
|
@@ -1033,13 +1004,11 @@ class AddDataViewModel {
|
|
|
1033
1004
|
serverType = "terrainprovider";
|
|
1034
1005
|
addType = "obterrain";
|
|
1035
1006
|
url = layers[i]._originUrl + layers[i]._urlPramas;
|
|
1036
|
-
|
|
1037
1007
|
this._layerManager._terrainProviders.push(layers[i]);
|
|
1038
1008
|
} else if (layers[i] instanceof Cesium.CesiumTerrainProvider) {
|
|
1039
1009
|
serverType = "terrainprovider";
|
|
1040
1010
|
addType = "stkterrain";
|
|
1041
1011
|
url = layers[i]._originUrl;
|
|
1042
|
-
|
|
1043
1012
|
this._layerManager._terrainProviders.push(layers[i]);
|
|
1044
1013
|
} else if (layers[i] instanceof Cesium.Kq3dGeoJsonDataSource) {
|
|
1045
1014
|
serverType = "datasource";
|
|
@@ -1058,11 +1027,10 @@ class AddDataViewModel {
|
|
|
1058
1027
|
};
|
|
1059
1028
|
}
|
|
1060
1029
|
});
|
|
1061
|
-
let shapeType = "";
|
|
1062
|
-
|
|
1030
|
+
let shapeType = "";
|
|
1031
|
+
// 判断geojson点线面类型
|
|
1063
1032
|
if (ds.entities.values.length > 0) {
|
|
1064
1033
|
let entity = ds.entities.values[0];
|
|
1065
|
-
|
|
1066
1034
|
if (entity.polygon) {
|
|
1067
1035
|
shapeType = "polygon";
|
|
1068
1036
|
} else if (entity.polyline) {
|
|
@@ -1071,7 +1039,6 @@ class AddDataViewModel {
|
|
|
1071
1039
|
shapeType = "point";
|
|
1072
1040
|
}
|
|
1073
1041
|
}
|
|
1074
|
-
|
|
1075
1042
|
let dsChild = {
|
|
1076
1043
|
guid: ds.guid,
|
|
1077
1044
|
name: ds._name,
|
|
@@ -1091,7 +1058,6 @@ class AddDataViewModel {
|
|
|
1091
1058
|
addType = "s3m";
|
|
1092
1059
|
url = layers[i]._url;
|
|
1093
1060
|
}
|
|
1094
|
-
|
|
1095
1061
|
if (serverType !== "datasource") {
|
|
1096
1062
|
if (!layers[i].guid) layers[i].guid = Cesium.createGuid();
|
|
1097
1063
|
node.children.push({
|
|
@@ -1104,19 +1070,14 @@ class AddDataViewModel {
|
|
|
1104
1070
|
});
|
|
1105
1071
|
}
|
|
1106
1072
|
}
|
|
1107
|
-
|
|
1108
1073
|
Promise.all(promiseList).then(() => {
|
|
1109
1074
|
this.flyToLayer(layers[0]);
|
|
1110
|
-
|
|
1111
1075
|
this._layerManager.addTempLayerNode(node);
|
|
1112
|
-
|
|
1113
1076
|
cb && cb(node);
|
|
1114
1077
|
});
|
|
1115
1078
|
}
|
|
1116
1079
|
});
|
|
1117
|
-
|
|
1118
1080
|
break;
|
|
1119
|
-
|
|
1120
1081
|
case "kqgisimageserver":
|
|
1121
1082
|
// KQGIS 影像服务
|
|
1122
1083
|
node = {
|
|
@@ -1129,7 +1090,6 @@ class AddDataViewModel {
|
|
|
1129
1090
|
service.init(result => {
|
|
1130
1091
|
if (result.resultcode === "success") {
|
|
1131
1092
|
let list = service.collectionInfoList;
|
|
1132
|
-
|
|
1133
1093
|
if (list && list.length > 0) {
|
|
1134
1094
|
list.forEach(item => {
|
|
1135
1095
|
layer = that._viewer.imageryLayers.addImageryProvider(new Cesium.Kq3dKQGISServerImageryProviderExt({
|
|
@@ -1147,13 +1107,10 @@ class AddDataViewModel {
|
|
|
1147
1107
|
addType: type,
|
|
1148
1108
|
layerName: item.collectionName,
|
|
1149
1109
|
type: "Image" // 图层树显示图标使用
|
|
1150
|
-
|
|
1151
1110
|
});
|
|
1152
1111
|
});
|
|
1153
1112
|
this.flyToLayer(layer);
|
|
1154
|
-
|
|
1155
1113
|
this._layerManager.addTempLayerNode(node);
|
|
1156
|
-
|
|
1157
1114
|
cb && cb(node);
|
|
1158
1115
|
}
|
|
1159
1116
|
} else {
|
|
@@ -1161,7 +1118,6 @@ class AddDataViewModel {
|
|
|
1161
1118
|
}
|
|
1162
1119
|
});
|
|
1163
1120
|
break;
|
|
1164
|
-
|
|
1165
1121
|
case "kqgisdataserver":
|
|
1166
1122
|
// KQGIS 数据服务
|
|
1167
1123
|
this.addDataServer(url).then(children => {
|
|
@@ -1172,13 +1128,10 @@ class AddDataViewModel {
|
|
|
1172
1128
|
children: children,
|
|
1173
1129
|
lsType: "ls"
|
|
1174
1130
|
};
|
|
1175
|
-
|
|
1176
1131
|
this._layerManager.addTempLayerNode(node, 1);
|
|
1177
|
-
|
|
1178
1132
|
cb && cb(node);
|
|
1179
1133
|
});
|
|
1180
1134
|
break;
|
|
1181
|
-
|
|
1182
1135
|
case "kqgismapserver":
|
|
1183
1136
|
// KQGIS 地图服务
|
|
1184
1137
|
if (loadCustom) {
|
|
@@ -1188,22 +1141,19 @@ class AddDataViewModel {
|
|
|
1188
1141
|
});
|
|
1189
1142
|
return;
|
|
1190
1143
|
}
|
|
1191
|
-
|
|
1192
1144
|
node = {
|
|
1193
1145
|
guid: Cesium.createGuid(),
|
|
1194
1146
|
name: name,
|
|
1195
1147
|
children: [],
|
|
1196
1148
|
lsType: "ls"
|
|
1197
|
-
};
|
|
1198
|
-
|
|
1149
|
+
};
|
|
1150
|
+
//使用二维方式解析服务
|
|
1199
1151
|
let serverName = url.split("services/")[1].split("/")[0];
|
|
1200
1152
|
let serverUrl = url.split("services/")[0] + "services/";
|
|
1201
1153
|
let token;
|
|
1202
|
-
|
|
1203
1154
|
if (url.indexOf("ua_token") != -1) {
|
|
1204
1155
|
token = url.split("ua_token=")[1].split("&")[0];
|
|
1205
1156
|
}
|
|
1206
|
-
|
|
1207
1157
|
let webMapService = new (webmapservice_default())(serverName, {
|
|
1208
1158
|
token: token,
|
|
1209
1159
|
serviceUrl: serverUrl
|
|
@@ -1216,13 +1166,12 @@ class AddDataViewModel {
|
|
|
1216
1166
|
});
|
|
1217
1167
|
return;
|
|
1218
1168
|
}
|
|
1219
|
-
|
|
1220
1169
|
mapInfo = mapInfo.result;
|
|
1221
1170
|
let mapServerInfo = (0,util_.formatKQMapInfo)(mapInfo, serverUrl, serverName, token, null, true);
|
|
1222
1171
|
let showLayers = [];
|
|
1223
1172
|
showLayers = showLayers.concat(mapServerInfo.layers_show);
|
|
1224
|
-
showLayers.reverse();
|
|
1225
|
-
|
|
1173
|
+
showLayers.reverse();
|
|
1174
|
+
//获取图层筛选类型时用
|
|
1226
1175
|
showLayers.forEach(layer => {
|
|
1227
1176
|
layer.sourceType = "kqserver";
|
|
1228
1177
|
});
|
|
@@ -1236,10 +1185,8 @@ class AddDataViewModel {
|
|
|
1236
1185
|
show: layer.visible
|
|
1237
1186
|
});
|
|
1238
1187
|
imageryLayer._guid = layer.guid;
|
|
1239
|
-
|
|
1240
1188
|
this._viewer.imageryLayers.add(imageryLayer);
|
|
1241
1189
|
}, this);
|
|
1242
|
-
|
|
1243
1190
|
if (mapInfo.rect84) {
|
|
1244
1191
|
if (mapInfo.rect84 instanceof Array) {
|
|
1245
1192
|
this._viewer.camera.flyTo({
|
|
@@ -1251,26 +1198,21 @@ class AddDataViewModel {
|
|
|
1251
1198
|
});
|
|
1252
1199
|
}
|
|
1253
1200
|
}
|
|
1254
|
-
|
|
1255
1201
|
setChildrenAddType(mapServerInfo.layerTreeData, type);
|
|
1256
1202
|
mapServerInfo.layerTreeData.forEach(layerData => {
|
|
1257
1203
|
layerData.url = url;
|
|
1258
1204
|
node.children.push(layerData);
|
|
1259
1205
|
});
|
|
1260
|
-
|
|
1261
1206
|
this._layerManager.addTempLayerNode(node, 1);
|
|
1262
|
-
|
|
1263
1207
|
cb && cb(node);
|
|
1264
1208
|
});
|
|
1265
1209
|
break;
|
|
1266
|
-
|
|
1267
1210
|
case "arcgismapserver":
|
|
1268
1211
|
// ARCGIS 地图服务
|
|
1269
1212
|
layer = this._viewer.imageryLayers.addImageryProvider(new Cesium.Kq3dArcGISMapServerImageryProvider({
|
|
1270
1213
|
name: name,
|
|
1271
1214
|
url: url,
|
|
1272
1215
|
usePreCachedTilesIfAvailable: false //使用export请求可支持自定义比例尺
|
|
1273
|
-
|
|
1274
1216
|
}));
|
|
1275
1217
|
this.flyToLayer(layer);
|
|
1276
1218
|
node = {
|
|
@@ -1282,12 +1224,9 @@ class AddDataViewModel {
|
|
|
1282
1224
|
url: url,
|
|
1283
1225
|
addType: type
|
|
1284
1226
|
};
|
|
1285
|
-
|
|
1286
1227
|
this._layerManager.addTempLayerNode(node);
|
|
1287
|
-
|
|
1288
1228
|
cb && cb(node);
|
|
1289
1229
|
break;
|
|
1290
|
-
|
|
1291
1230
|
case "mvt":
|
|
1292
1231
|
// 矢量瓦片
|
|
1293
1232
|
layer = this._viewer.imageryLayers.addImageryProvider(new Cesium.Kq3dMvtImageryProviderExt({
|
|
@@ -1304,14 +1243,10 @@ class AddDataViewModel {
|
|
|
1304
1243
|
url: url,
|
|
1305
1244
|
addType: type,
|
|
1306
1245
|
renderType: "vectortile" // 图层树显示图标使用
|
|
1307
|
-
|
|
1308
1246
|
};
|
|
1309
|
-
|
|
1310
1247
|
this._layerManager.addTempLayerNode(node);
|
|
1311
|
-
|
|
1312
1248
|
cb && cb(node);
|
|
1313
1249
|
break;
|
|
1314
|
-
|
|
1315
1250
|
case "kqgisdataflowserver":
|
|
1316
1251
|
// KQGIS 数据流服务
|
|
1317
1252
|
let guid = Cesium.createGuid();
|
|
@@ -1335,14 +1270,10 @@ class AddDataViewModel {
|
|
|
1335
1270
|
url: url,
|
|
1336
1271
|
addType: type
|
|
1337
1272
|
};
|
|
1338
|
-
|
|
1339
1273
|
this._layerManager.addTempLayerNode(node);
|
|
1340
|
-
|
|
1341
1274
|
this._layerManager._dataFlowLayerList.push(layer);
|
|
1342
|
-
|
|
1343
1275
|
cb && cb(node);
|
|
1344
1276
|
break;
|
|
1345
|
-
|
|
1346
1277
|
case "wms":
|
|
1347
1278
|
this._viewer.addWMSLayerGroup(url).then(group => {
|
|
1348
1279
|
node = {
|
|
@@ -1351,16 +1282,13 @@ class AddDataViewModel {
|
|
|
1351
1282
|
children: [],
|
|
1352
1283
|
lsType: "ls",
|
|
1353
1284
|
serverType: "ogcwms" //图层树显示图标使用
|
|
1354
|
-
|
|
1355
1285
|
};
|
|
1356
1286
|
var layers = group._addedLayers || group._layers;
|
|
1357
|
-
|
|
1358
1287
|
if (layers) {
|
|
1359
1288
|
for (var i = layers.length - 1; i >= 0; i--) {
|
|
1360
1289
|
if (i === 0) {
|
|
1361
1290
|
this.flyToLayer(layers[i]);
|
|
1362
1291
|
}
|
|
1363
|
-
|
|
1364
1292
|
node.children.push({
|
|
1365
1293
|
guid: layers[i].guid,
|
|
1366
1294
|
name: layers[i].name,
|
|
@@ -1372,17 +1300,12 @@ class AddDataViewModel {
|
|
|
1372
1300
|
});
|
|
1373
1301
|
}
|
|
1374
1302
|
}
|
|
1375
|
-
|
|
1376
1303
|
this._layerManager.addTempLayerNode(node);
|
|
1377
|
-
|
|
1378
1304
|
cb && cb(node);
|
|
1379
1305
|
});
|
|
1380
|
-
|
|
1381
1306
|
break;
|
|
1382
|
-
|
|
1383
1307
|
case "wmts":
|
|
1384
1308
|
case "kqgistileserver": // KQGIS 瓦片服务
|
|
1385
|
-
|
|
1386
1309
|
case "kqgisaggregationserver":
|
|
1387
1310
|
// KQGIS 聚合服务
|
|
1388
1311
|
if (type === "kqgistileserver") {
|
|
@@ -1392,9 +1315,7 @@ class AddDataViewModel {
|
|
|
1392
1315
|
url += "/wmts";
|
|
1393
1316
|
}
|
|
1394
1317
|
}
|
|
1395
|
-
|
|
1396
1318
|
let defaultName = "wmts";
|
|
1397
|
-
|
|
1398
1319
|
this._viewer.addWMTSLayerGroup(url).then(group => {
|
|
1399
1320
|
// if(type === "kqgistileserver") defaultName = name;
|
|
1400
1321
|
if (type === "kqgisaggregationserver") defaultName = "aggregation";
|
|
@@ -1404,20 +1325,16 @@ class AddDataViewModel {
|
|
|
1404
1325
|
children: [],
|
|
1405
1326
|
lsType: "ls"
|
|
1406
1327
|
};
|
|
1407
|
-
|
|
1408
1328
|
if (type === "wmts") {
|
|
1409
1329
|
//图层树显示图标使用
|
|
1410
1330
|
node.serverType = "ogcwmts";
|
|
1411
1331
|
}
|
|
1412
|
-
|
|
1413
1332
|
var layers = group._addedLayers || group._layers;
|
|
1414
|
-
|
|
1415
1333
|
if (layers) {
|
|
1416
1334
|
for (var i = layers.length - 1; i >= 0; i--) {
|
|
1417
1335
|
if (i === 0) {
|
|
1418
1336
|
this.flyToLayer(layers[i]);
|
|
1419
1337
|
}
|
|
1420
|
-
|
|
1421
1338
|
node.children.push({
|
|
1422
1339
|
guid: layers[i].guid,
|
|
1423
1340
|
name: layers[i].name,
|
|
@@ -1429,14 +1346,10 @@ class AddDataViewModel {
|
|
|
1429
1346
|
});
|
|
1430
1347
|
}
|
|
1431
1348
|
}
|
|
1432
|
-
|
|
1433
1349
|
this._layerManager.addTempLayerNode(node);
|
|
1434
|
-
|
|
1435
1350
|
cb && cb(node);
|
|
1436
1351
|
});
|
|
1437
|
-
|
|
1438
1352
|
break;
|
|
1439
|
-
|
|
1440
1353
|
case "wfs":
|
|
1441
1354
|
var wfsProvider = new Cesium.Kq3dWebFeatureServiceProvider({
|
|
1442
1355
|
url: url,
|
|
@@ -1445,9 +1358,8 @@ class AddDataViewModel {
|
|
|
1445
1358
|
wfsProvider.load().then(function (data) {
|
|
1446
1359
|
var ds = new Cesium.Kq3dGeoJsonDataSource(name);
|
|
1447
1360
|
ds.load(data, that._geojsonStyle).then(ds => {
|
|
1448
|
-
that._viewer.dataSources.add(ds);
|
|
1449
|
-
|
|
1450
|
-
|
|
1361
|
+
that._viewer.dataSources.add(ds);
|
|
1362
|
+
// ds.autoAvoid(that._viewer);
|
|
1451
1363
|
that.flyToLayer(ds);
|
|
1452
1364
|
node = {
|
|
1453
1365
|
guid: ds.guid,
|
|
@@ -1458,14 +1370,11 @@ class AddDataViewModel {
|
|
|
1458
1370
|
url: url,
|
|
1459
1371
|
addType: type
|
|
1460
1372
|
};
|
|
1461
|
-
|
|
1462
1373
|
that._layerManager.addTempLayerNode(node);
|
|
1463
|
-
|
|
1464
1374
|
cb && cb(node);
|
|
1465
1375
|
});
|
|
1466
1376
|
});
|
|
1467
1377
|
break;
|
|
1468
|
-
|
|
1469
1378
|
case "geojson":
|
|
1470
1379
|
var ds = new Cesium.Kq3dGeoJsonDataSource(name);
|
|
1471
1380
|
ds.load(url, this._geojsonStyle).then(ds => {
|
|
@@ -1479,10 +1388,8 @@ class AddDataViewModel {
|
|
|
1479
1388
|
};
|
|
1480
1389
|
}
|
|
1481
1390
|
}, this);
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1391
|
+
this._viewer.dataSources.add(ds);
|
|
1392
|
+
// ds.autoAvoid(this._viewer);
|
|
1486
1393
|
that.flyToLayer(ds);
|
|
1487
1394
|
node = {
|
|
1488
1395
|
guid: ds.guid,
|
|
@@ -1494,16 +1401,14 @@ class AddDataViewModel {
|
|
|
1494
1401
|
addType: type,
|
|
1495
1402
|
shapeType: this._layerManager.getShapeType(ds)
|
|
1496
1403
|
};
|
|
1497
|
-
|
|
1498
1404
|
this._layerManager.addTempLayerNode(node);
|
|
1499
|
-
|
|
1500
1405
|
cb && cb(node);
|
|
1501
1406
|
});
|
|
1502
1407
|
break;
|
|
1503
|
-
|
|
1504
1408
|
case "arcjson":
|
|
1505
1409
|
var ds = new Cesium.Kq3dEsriGeoJsonDataSource(name);
|
|
1506
|
-
var geojsonStyle = {
|
|
1410
|
+
var geojsonStyle = {
|
|
1411
|
+
...this._geojsonStyle
|
|
1507
1412
|
};
|
|
1508
1413
|
geojsonStyle.label.express = "NAME";
|
|
1509
1414
|
ds.load(url, geojsonStyle).then(ds => {
|
|
@@ -1517,9 +1422,7 @@ class AddDataViewModel {
|
|
|
1517
1422
|
};
|
|
1518
1423
|
}
|
|
1519
1424
|
}, this);
|
|
1520
|
-
|
|
1521
1425
|
this._viewer.dataSources.add(ds);
|
|
1522
|
-
|
|
1523
1426
|
that.flyToLayer(ds);
|
|
1524
1427
|
node = {
|
|
1525
1428
|
guid: ds.guid,
|
|
@@ -1531,13 +1434,10 @@ class AddDataViewModel {
|
|
|
1531
1434
|
addType: type,
|
|
1532
1435
|
shapeType: this._layerManager.getShapeType(ds)
|
|
1533
1436
|
};
|
|
1534
|
-
|
|
1535
1437
|
this._layerManager.addTempLayerNode(node);
|
|
1536
|
-
|
|
1537
1438
|
cb && cb(node);
|
|
1538
1439
|
});
|
|
1539
1440
|
break;
|
|
1540
|
-
|
|
1541
1441
|
case "kml":
|
|
1542
1442
|
var ds = new Cesium.KmlDataSource({
|
|
1543
1443
|
name: name,
|
|
@@ -1546,7 +1446,6 @@ class AddDataViewModel {
|
|
|
1546
1446
|
});
|
|
1547
1447
|
ds.load(url).then(ds => {
|
|
1548
1448
|
this._viewer.dataSources.add(ds);
|
|
1549
|
-
|
|
1550
1449
|
that.flyToLayer(ds);
|
|
1551
1450
|
node = {
|
|
1552
1451
|
guid: ds.guid,
|
|
@@ -1557,18 +1456,14 @@ class AddDataViewModel {
|
|
|
1557
1456
|
url: url,
|
|
1558
1457
|
addType: type
|
|
1559
1458
|
};
|
|
1560
|
-
|
|
1561
1459
|
this._layerManager.addTempLayerNode(node);
|
|
1562
|
-
|
|
1563
1460
|
cb && cb(node);
|
|
1564
1461
|
});
|
|
1565
1462
|
break;
|
|
1566
|
-
|
|
1567
1463
|
case "czml":
|
|
1568
1464
|
var ds = new Cesium.CzmlDataSource(name);
|
|
1569
1465
|
ds.load(url).then(ds => {
|
|
1570
1466
|
this._viewer.dataSources.add(ds);
|
|
1571
|
-
|
|
1572
1467
|
that.flyToLayer(ds);
|
|
1573
1468
|
node = {
|
|
1574
1469
|
guid: ds.guid,
|
|
@@ -1579,13 +1474,10 @@ class AddDataViewModel {
|
|
|
1579
1474
|
url: url,
|
|
1580
1475
|
addType: type
|
|
1581
1476
|
};
|
|
1582
|
-
|
|
1583
1477
|
this._layerManager.addTempLayerNode(node);
|
|
1584
|
-
|
|
1585
1478
|
cb && cb(node);
|
|
1586
1479
|
});
|
|
1587
1480
|
break;
|
|
1588
|
-
|
|
1589
1481
|
case "s3m":
|
|
1590
1482
|
layer = this._viewer.scene.primitives.add(new Cesium.Kq3dS3MTilesLayer({
|
|
1591
1483
|
context: this._viewer.scene._context,
|
|
@@ -1604,33 +1496,27 @@ class AddDataViewModel {
|
|
|
1604
1496
|
url: url,
|
|
1605
1497
|
addType: type
|
|
1606
1498
|
};
|
|
1607
|
-
|
|
1608
1499
|
this._layerManager.addTempLayerNode(node);
|
|
1609
|
-
|
|
1610
1500
|
cb && cb(node);
|
|
1611
1501
|
break;
|
|
1612
|
-
|
|
1613
1502
|
default:
|
|
1614
1503
|
break;
|
|
1615
1504
|
}
|
|
1616
|
-
}
|
|
1617
|
-
|
|
1505
|
+
}
|
|
1618
1506
|
|
|
1507
|
+
// 添加数据服务
|
|
1619
1508
|
addDataServer(url) {
|
|
1620
1509
|
return new Promise((resolve, reject) => {
|
|
1621
1510
|
Cesium.Kq3dService.datasourceService(url).getDatasources(async e => {
|
|
1622
1511
|
if (e.result.resultcode === "success") {
|
|
1623
1512
|
let datasourceList = e.result.result.datasources;
|
|
1624
|
-
|
|
1625
1513
|
if (datasourceList) {
|
|
1626
1514
|
let nodes = [];
|
|
1627
|
-
|
|
1628
1515
|
for (let i = 0; i < datasourceList.length; i++) {
|
|
1629
1516
|
let datasetList = await this._getDatasetList(url, datasourceList[i].datasourceName);
|
|
1630
1517
|
if (!datasetList || datasetList.length === 0) continue;
|
|
1631
1518
|
await this._addDataSets(url, datasourceList[i].datasourceName, datasetList, nodes);
|
|
1632
1519
|
}
|
|
1633
|
-
|
|
1634
1520
|
resolve(nodes);
|
|
1635
1521
|
} else {
|
|
1636
1522
|
reject([]);
|
|
@@ -1645,7 +1531,6 @@ class AddDataViewModel {
|
|
|
1645
1531
|
});
|
|
1646
1532
|
});
|
|
1647
1533
|
}
|
|
1648
|
-
|
|
1649
1534
|
_getDatasetList(url, datasourceName) {
|
|
1650
1535
|
let params = new window.KqGIS.Data.GetDatasetsInfoParams({
|
|
1651
1536
|
datasourceName: datasourceName
|
|
@@ -1663,19 +1548,18 @@ class AddDataViewModel {
|
|
|
1663
1548
|
reject([]);
|
|
1664
1549
|
});
|
|
1665
1550
|
});
|
|
1666
|
-
}
|
|
1667
|
-
|
|
1551
|
+
}
|
|
1668
1552
|
|
|
1553
|
+
// 加载数据集
|
|
1669
1554
|
async _addDataSets(url, datasourceName, datasetList, nodes) {
|
|
1670
1555
|
let dataSourceNode = {
|
|
1671
1556
|
guid: window.Cesium.createGuid(),
|
|
1672
1557
|
name: datasourceName,
|
|
1673
1558
|
visible: true,
|
|
1674
1559
|
children: []
|
|
1675
|
-
};
|
|
1676
|
-
|
|
1560
|
+
};
|
|
1561
|
+
// 获取数据集类型数据
|
|
1677
1562
|
const datasetArr = datasetList.filter(o => o['isParentDataset'] === true);
|
|
1678
|
-
|
|
1679
1563
|
if (datasetArr.length === 0) {
|
|
1680
1564
|
await this._addFeatures(url, datasourceName, datasetList, dataSourceNode);
|
|
1681
1565
|
} else {
|
|
@@ -1687,23 +1571,20 @@ class AddDataViewModel {
|
|
|
1687
1571
|
children: []
|
|
1688
1572
|
});
|
|
1689
1573
|
});
|
|
1690
|
-
|
|
1691
1574
|
for (let i = 0; i < dataSourceNode.children.length; i++) {
|
|
1692
1575
|
const datasetChild = datasetList.filter(o => o['parentDatasetName'] === dataSourceNode.children[i].name);
|
|
1693
1576
|
await this._addFeatures(url, datasourceName, datasetChild, dataSourceNode.children[i]);
|
|
1694
1577
|
}
|
|
1695
1578
|
}
|
|
1696
|
-
|
|
1697
1579
|
nodes.push(dataSourceNode);
|
|
1698
|
-
}
|
|
1699
|
-
|
|
1580
|
+
}
|
|
1700
1581
|
|
|
1582
|
+
// 加载要素
|
|
1701
1583
|
async _addFeatures(url, datasourceName, datasetList, parentNode) {
|
|
1702
1584
|
let promises = [];
|
|
1703
|
-
|
|
1704
1585
|
for (let i = 0; i < datasetList.length; i++) {
|
|
1705
|
-
const dataset = datasetList[i];
|
|
1706
|
-
|
|
1586
|
+
const dataset = datasetList[i];
|
|
1587
|
+
// 获取数据集数据
|
|
1707
1588
|
const featureData = await this._getFeatureList(url, datasourceName, dataset.datasetName);
|
|
1708
1589
|
var ds = new Cesium.Kq3dGeoJsonDataSource(featureData.datasetName);
|
|
1709
1590
|
let promise = ds.load(featureData.features, this._geojsonStyle).then(ds => {
|
|
@@ -1717,9 +1598,7 @@ class AddDataViewModel {
|
|
|
1717
1598
|
};
|
|
1718
1599
|
}
|
|
1719
1600
|
}, this);
|
|
1720
|
-
|
|
1721
1601
|
this._viewer.dataSources.add(ds);
|
|
1722
|
-
|
|
1723
1602
|
parentNode.children.push({
|
|
1724
1603
|
guid: ds.guid,
|
|
1725
1604
|
name: featureData.datasetName,
|
|
@@ -1730,21 +1609,17 @@ class AddDataViewModel {
|
|
|
1730
1609
|
addType: 'geojson',
|
|
1731
1610
|
shapeType: featureData.geometryType
|
|
1732
1611
|
});
|
|
1733
|
-
|
|
1734
1612
|
this._layerManager._layerListData.push(parentNode.children[i]);
|
|
1735
|
-
|
|
1736
1613
|
if (i == 0) this.flyToLayer(ds);
|
|
1737
1614
|
});
|
|
1738
1615
|
promises.push(promise);
|
|
1739
1616
|
}
|
|
1740
|
-
|
|
1741
1617
|
return new Promise(resolve => {
|
|
1742
1618
|
Promise.all(promises).then(() => {
|
|
1743
1619
|
resolve();
|
|
1744
1620
|
});
|
|
1745
1621
|
});
|
|
1746
1622
|
}
|
|
1747
|
-
|
|
1748
1623
|
_getFeatureList(url, datasourceName, datasetName) {
|
|
1749
1624
|
let params = new window.KqGIS.Data.GetFeaturesParamsBase({
|
|
1750
1625
|
datasourceName: datasourceName,
|
|
@@ -1768,10 +1643,8 @@ class AddDataViewModel {
|
|
|
1768
1643
|
});
|
|
1769
1644
|
});
|
|
1770
1645
|
}
|
|
1771
|
-
|
|
1772
1646
|
flyToLayer(layer) {
|
|
1773
1647
|
let viewer = this._viewer;
|
|
1774
|
-
|
|
1775
1648
|
if (layer instanceof Cesium.ImageryLayer) {
|
|
1776
1649
|
layer.getViewableRectangle().then(function (rectangle) {
|
|
1777
1650
|
viewer.camera.flyTo({
|
|
@@ -1812,13 +1685,12 @@ class AddDataViewModel {
|
|
|
1812
1685
|
});
|
|
1813
1686
|
}
|
|
1814
1687
|
}
|
|
1688
|
+
}
|
|
1815
1689
|
|
|
1816
|
-
|
|
1817
|
-
|
|
1690
|
+
// 设置子节点addType属性
|
|
1818
1691
|
function setChildrenAddType(nodeList, addType) {
|
|
1819
1692
|
for (let i = 0; i < nodeList.length; i++) {
|
|
1820
1693
|
const node = nodeList[i];
|
|
1821
|
-
|
|
1822
1694
|
if (node.children) {
|
|
1823
1695
|
setChildrenAddType(node.children, addType);
|
|
1824
1696
|
} else {
|
|
@@ -1831,6 +1703,9 @@ var vue_i18n_cjs_js_ = __webpack_require__(7080);
|
|
|
1831
1703
|
;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/webgl/adddata/AddData.vue?vue&type=script&setup=true&lang=js
|
|
1832
1704
|
|
|
1833
1705
|
|
|
1706
|
+
|
|
1707
|
+
|
|
1708
|
+
|
|
1834
1709
|
const _hoisted_1 = {
|
|
1835
1710
|
class: "kq3d-add-data-box"
|
|
1836
1711
|
};
|
|
@@ -1882,7 +1757,6 @@ const __default__ = {
|
|
|
1882
1757
|
type: Boolean,
|
|
1883
1758
|
default: true
|
|
1884
1759
|
},
|
|
1885
|
-
|
|
1886
1760
|
/**
|
|
1887
1761
|
* 例:"center","topLeft","topRight","bottomLeft","bottomRight", "topCenter", "bottomCenter" {top:'16px',left:'16px'}, {top:16,left:16}
|
|
1888
1762
|
*/
|
|
@@ -1945,7 +1819,6 @@ const __default__ = {
|
|
|
1945
1819
|
type: String
|
|
1946
1820
|
}
|
|
1947
1821
|
},
|
|
1948
|
-
|
|
1949
1822
|
setup(__props, {
|
|
1950
1823
|
expose: __expose
|
|
1951
1824
|
}) {
|
|
@@ -1955,8 +1828,9 @@ const __default__ = {
|
|
|
1955
1828
|
proxy
|
|
1956
1829
|
} = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.getCurrentInstance)();
|
|
1957
1830
|
let language = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(proxy.$i18n.global.messages[proxy.$i18n.global.locale]["webgl"]);
|
|
1958
|
-
let selectTypeIndex = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(0);
|
|
1831
|
+
let selectTypeIndex = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(0);
|
|
1959
1832
|
|
|
1833
|
+
//选择的数据源类型
|
|
1960
1834
|
let dataSourceType = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)({});
|
|
1961
1835
|
let dataSource = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.reactive)({
|
|
1962
1836
|
url: "",
|
|
@@ -1965,37 +1839,38 @@ const __default__ = {
|
|
|
1965
1839
|
let upload_ref = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(null);
|
|
1966
1840
|
let upload_btn_ref = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(null);
|
|
1967
1841
|
let fileList = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)([]);
|
|
1968
|
-
let loadingFile = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(false);
|
|
1969
|
-
|
|
1842
|
+
let loadingFile = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(false);
|
|
1843
|
+
|
|
1844
|
+
// 获取组件传参
|
|
1970
1845
|
|
|
1846
|
+
//URL服务支持的数据源类型
|
|
1971
1847
|
let dataSourceTypeList = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(setDataSourceType());
|
|
1972
1848
|
let operatorArray = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.computed)(() => {
|
|
1973
1849
|
let array = [];
|
|
1974
1850
|
let list = [...fileList.value];
|
|
1975
1851
|
let len = list.length;
|
|
1976
|
-
|
|
1977
1852
|
for (let i = 0, j = 0; i < len; i += 3, j++) {
|
|
1978
1853
|
array[j] = list.splice(0, 3);
|
|
1979
1854
|
}
|
|
1980
|
-
|
|
1981
1855
|
return array;
|
|
1982
1856
|
});
|
|
1983
1857
|
let disabled = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.computed)(() => {
|
|
1984
1858
|
let flag = true;
|
|
1985
|
-
|
|
1986
1859
|
if (fileList.value.length > 0) {
|
|
1987
1860
|
flag = false;
|
|
1988
1861
|
}
|
|
1989
|
-
|
|
1990
1862
|
return flag;
|
|
1991
|
-
});
|
|
1863
|
+
});
|
|
1992
1864
|
|
|
1993
|
-
|
|
1865
|
+
// 组件容器Ref
|
|
1866
|
+
let boxRef = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)(null);
|
|
1994
1867
|
|
|
1868
|
+
// 生成组件默认header
|
|
1995
1869
|
let headerTemp = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)();
|
|
1996
1870
|
let headerTempRef = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.ref)();
|
|
1997
|
-
let viewModel = null;
|
|
1871
|
+
let viewModel = null;
|
|
1998
1872
|
|
|
1873
|
+
// 国际化
|
|
1999
1874
|
let {
|
|
2000
1875
|
locale,
|
|
2001
1876
|
messages
|
|
@@ -2007,9 +1882,9 @@ const __default__ = {
|
|
|
2007
1882
|
dataSourceTypeList.value = setDataSourceType();
|
|
2008
1883
|
dataSourceType.value = dataSourceTypeList.value[selectTypeIndex.value];
|
|
2009
1884
|
});
|
|
2010
|
-
|
|
2011
1885
|
function setDataSourceType() {
|
|
2012
|
-
let types = [
|
|
1886
|
+
let types = [
|
|
1887
|
+
// {
|
|
2013
1888
|
// type: 'kq3dimageryfile',
|
|
2014
1889
|
// name: language.value.ImagertyTileFile,
|
|
2015
1890
|
// namePlaceholder: language.value.optional,
|
|
@@ -2137,22 +2012,17 @@ const __default__ = {
|
|
|
2137
2012
|
namePlaceholder: language.value.optional,
|
|
2138
2013
|
urlPlaceholder: language.value.format +': http://<host>:<port>/xxx/<servername>/xxx.czml',
|
|
2139
2014
|
description: language.value.imagertyCZMLdescription
|
|
2140
|
-
}*/
|
|
2141
|
-
];
|
|
2142
|
-
|
|
2015
|
+
}*/];
|
|
2143
2016
|
if (props.hideServiceTypes) {
|
|
2144
2017
|
let indexList = props.hideServiceTypes.split(",");
|
|
2145
|
-
|
|
2146
2018
|
for (let i = types.length - 1; i >= 0; i--) {
|
|
2147
2019
|
if (indexList.includes(i.toString())) {
|
|
2148
2020
|
types.splice(i, 1);
|
|
2149
2021
|
}
|
|
2150
2022
|
}
|
|
2151
2023
|
}
|
|
2152
|
-
|
|
2153
2024
|
return types;
|
|
2154
2025
|
}
|
|
2155
|
-
|
|
2156
2026
|
(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.onMounted)(() => {
|
|
2157
2027
|
(0,util_.updatePosition)(boxRef.value, props);
|
|
2158
2028
|
(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.watch)(() => props.position, (newVal, oldVal) => {
|
|
@@ -2175,49 +2045,49 @@ const __default__ = {
|
|
|
2175
2045
|
}
|
|
2176
2046
|
});
|
|
2177
2047
|
});
|
|
2048
|
+
|
|
2178
2049
|
/**
|
|
2179
2050
|
* @description 监听header生成
|
|
2180
2051
|
*/
|
|
2181
|
-
|
|
2182
2052
|
const watchCreateHeaderTemp = () => {
|
|
2183
2053
|
if (props.showHeaderTemp) {
|
|
2184
2054
|
// 生成headerTemp
|
|
2185
2055
|
headerTemp.value = (0,util_.createHeaderTemp)(boxRef.value, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toRefs)(props), headerTempRef, addDataTitle);
|
|
2186
2056
|
}
|
|
2187
|
-
};
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
function handleChange(pane) {} // 切换类型
|
|
2057
|
+
};
|
|
2191
2058
|
|
|
2059
|
+
// 切换tab页
|
|
2060
|
+
function handleChange(pane) {}
|
|
2192
2061
|
|
|
2062
|
+
// 切换类型
|
|
2193
2063
|
function changeType(index) {
|
|
2194
2064
|
dataSourceType.value = dataSourceTypeList.value[index];
|
|
2195
2065
|
dataSource.url = "";
|
|
2196
2066
|
dataSource.name = "";
|
|
2197
|
-
}
|
|
2198
|
-
|
|
2067
|
+
}
|
|
2199
2068
|
|
|
2069
|
+
//选择文件
|
|
2200
2070
|
function changeFile(file) {
|
|
2201
2071
|
fileList.value.push(file);
|
|
2202
|
-
}
|
|
2203
|
-
|
|
2072
|
+
}
|
|
2204
2073
|
|
|
2074
|
+
// 删除文件
|
|
2205
2075
|
function removeFile(file) {
|
|
2206
2076
|
fileList.value.forEach((item, index) => {
|
|
2207
2077
|
if (item.uid === file.uid) {
|
|
2208
2078
|
fileList.value.splice(index, 1);
|
|
2209
2079
|
}
|
|
2210
2080
|
});
|
|
2211
|
-
}
|
|
2212
|
-
|
|
2081
|
+
}
|
|
2213
2082
|
|
|
2083
|
+
//清空所有文件
|
|
2214
2084
|
function removeFiles() {
|
|
2215
2085
|
upload_ref.value.$refs.child.clearFiles();
|
|
2216
2086
|
upload_btn_ref.value.$refs.child.clearFiles();
|
|
2217
2087
|
fileList.value = [];
|
|
2218
|
-
}
|
|
2219
|
-
|
|
2088
|
+
}
|
|
2220
2089
|
|
|
2090
|
+
//加载文件
|
|
2221
2091
|
function loadFiles() {
|
|
2222
2092
|
loadingFile.value = true;
|
|
2223
2093
|
let promiseList = [];
|
|
@@ -2228,53 +2098,39 @@ const __default__ = {
|
|
|
2228
2098
|
removeFiles();
|
|
2229
2099
|
loadingFile.value = false;
|
|
2230
2100
|
});
|
|
2231
|
-
}
|
|
2232
|
-
|
|
2101
|
+
}
|
|
2233
2102
|
|
|
2103
|
+
//加载URL
|
|
2234
2104
|
function loadURL() {
|
|
2235
2105
|
viewModel.parseDataSource({
|
|
2236
2106
|
type: dataSourceType.value.type,
|
|
2237
2107
|
url: dataSource.url,
|
|
2238
2108
|
name: dataSource.name
|
|
2239
2109
|
}, props.loadCallback, props.loadCustom);
|
|
2240
|
-
}
|
|
2241
|
-
|
|
2110
|
+
}
|
|
2242
2111
|
|
|
2112
|
+
// 重置
|
|
2243
2113
|
function reset() {
|
|
2244
2114
|
dataSource.url = "";
|
|
2245
2115
|
dataSource.name = "";
|
|
2246
|
-
}
|
|
2247
|
-
|
|
2116
|
+
}
|
|
2248
2117
|
|
|
2118
|
+
// 销毁
|
|
2249
2119
|
(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.onBeforeUnmount)(() => {});
|
|
2250
|
-
|
|
2251
2120
|
__expose({});
|
|
2252
|
-
|
|
2253
2121
|
return (_ctx, _cache) => {
|
|
2254
2122
|
const _component_kq_row = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-row");
|
|
2255
|
-
|
|
2256
2123
|
const _component_kq_upload = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-upload");
|
|
2257
|
-
|
|
2258
2124
|
const _component_kq_icon = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-icon");
|
|
2259
|
-
|
|
2260
2125
|
const _component_kq_col = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-col");
|
|
2261
|
-
|
|
2262
2126
|
const _component_kq_button = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-button");
|
|
2263
|
-
|
|
2264
2127
|
const _component_kq_tab_pane = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-tab-pane");
|
|
2265
|
-
|
|
2266
2128
|
const _component_kq_option = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-option");
|
|
2267
|
-
|
|
2268
2129
|
const _component_kq_select = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-select");
|
|
2269
|
-
|
|
2270
2130
|
const _component_kq_form_item = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-form-item");
|
|
2271
|
-
|
|
2272
2131
|
const _component_kq_input = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-input");
|
|
2273
|
-
|
|
2274
2132
|
const _component_kq_form = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-form");
|
|
2275
|
-
|
|
2276
2133
|
const _component_kq_tabs = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.resolveComponent)("kq-tabs");
|
|
2277
|
-
|
|
2278
2134
|
return (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementBlock)("section", {
|
|
2279
2135
|
class: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.normalizeClass)(["kq3d-add-data", {
|
|
2280
2136
|
'kq-box-shadow': __props.showShadow
|
|
@@ -2285,9 +2141,7 @@ const __default__ = {
|
|
|
2285
2141
|
key: 0,
|
|
2286
2142
|
ref_key: "headerTempRef",
|
|
2287
2143
|
ref: headerTempRef
|
|
2288
|
-
}, null, 512
|
|
2289
|
-
/* NEED_PATCH */
|
|
2290
|
-
)) : (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createCommentVNode)("v-if", true), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_tabs, {
|
|
2144
|
+
}, null, 512 /* NEED_PATCH */)) : (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createCommentVNode)("v-if", true), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_tabs, {
|
|
2291
2145
|
modelValue: props.activeName,
|
|
2292
2146
|
"onUpdate:modelValue": _cache[8] || (_cache[8] = $event => props.activeName = $event),
|
|
2293
2147
|
onTabChange: handleChange
|
|
@@ -2299,21 +2153,13 @@ const __default__ = {
|
|
|
2299
2153
|
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_2, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_row, {
|
|
2300
2154
|
class: "kq3d-add-data-title"
|
|
2301
2155
|
}, {
|
|
2302
|
-
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).fileFormatDescription), 1
|
|
2303
|
-
/*
|
|
2304
|
-
)]),
|
|
2305
|
-
_: 1
|
|
2306
|
-
/* STABLE */
|
|
2307
|
-
|
|
2156
|
+
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).fileFormatDescription), 1 /* TEXT */)]),
|
|
2157
|
+
_: 1 /* STABLE */
|
|
2308
2158
|
}), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_row, {
|
|
2309
2159
|
class: "kq3d-add-data-tip"
|
|
2310
2160
|
}, {
|
|
2311
|
-
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).fileFormatDescriptionTips), 1
|
|
2312
|
-
/*
|
|
2313
|
-
)]),
|
|
2314
|
-
_: 1
|
|
2315
|
-
/* STABLE */
|
|
2316
|
-
|
|
2161
|
+
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).fileFormatDescriptionTips), 1 /* TEXT */)]),
|
|
2162
|
+
_: 1 /* STABLE */
|
|
2317
2163
|
})]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createCommentVNode)(" <div>\r\n <kq-row>{{ language.coordinateSystemDescription }}</kq-row>\r\n <kq-row class=\"kq3d-add-data-tip\">{{ language.coordinateSystemDescriptionTips }}</kq-row>\r\n </div> "), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withDirectives)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_upload, {
|
|
2318
2164
|
drag: "",
|
|
2319
2165
|
action: "",
|
|
@@ -2326,15 +2172,9 @@ const __default__ = {
|
|
|
2326
2172
|
ref_key: "upload_ref",
|
|
2327
2173
|
ref: upload_ref
|
|
2328
2174
|
}, {
|
|
2329
|
-
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_3, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).dragFileToArea), 1
|
|
2330
|
-
/*
|
|
2331
|
-
|
|
2332
|
-
_: 1
|
|
2333
|
-
/* STABLE */
|
|
2334
|
-
|
|
2335
|
-
}, 8
|
|
2336
|
-
/* PROPS */
|
|
2337
|
-
, ["file-list", "accept"]), [[external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.vShow, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(fileList).length === 0]]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withDirectives)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_4, [((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)(operatorArray), (rowItem, i) => {
|
|
2175
|
+
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_3, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).dragFileToArea), 1 /* TEXT */)]),
|
|
2176
|
+
_: 1 /* STABLE */
|
|
2177
|
+
}, 8 /* PROPS */, ["file-list", "accept"]), [[external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.vShow, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(fileList).length === 0]]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withDirectives)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_4, [((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)(operatorArray), (rowItem, i) => {
|
|
2338
2178
|
return (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.openBlock)(), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createBlock)(_component_kq_row, {
|
|
2339
2179
|
key: i,
|
|
2340
2180
|
gutter: 20
|
|
@@ -2348,44 +2188,22 @@ const __default__ = {
|
|
|
2348
2188
|
class: "kq3d-add-data-doc"
|
|
2349
2189
|
}, {
|
|
2350
2190
|
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(icons_vue_.Document))]),
|
|
2351
|
-
_: 1
|
|
2352
|
-
/* STABLE */
|
|
2353
|
-
|
|
2191
|
+
_: 1 /* STABLE */
|
|
2354
2192
|
}), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("p", {
|
|
2355
2193
|
title: file.name
|
|
2356
|
-
}, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)(file.name), 9
|
|
2357
|
-
/* TEXT, PROPS */
|
|
2358
|
-
, _hoisted_6), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_icon, {
|
|
2194
|
+
}, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)(file.name), 9 /* TEXT, PROPS */, _hoisted_6), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_icon, {
|
|
2359
2195
|
class: "kq3d-add-data-close",
|
|
2360
2196
|
onClick: $event => removeFile(file)
|
|
2361
2197
|
}, {
|
|
2362
2198
|
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(icons_vue_.CircleClose))]),
|
|
2363
|
-
_: 2
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
}, 1024
|
|
2373
|
-
/* DYNAMIC_SLOTS */
|
|
2374
|
-
);
|
|
2375
|
-
}), 128
|
|
2376
|
-
/* KEYED_FRAGMENT */
|
|
2377
|
-
))]),
|
|
2378
|
-
_: 2
|
|
2379
|
-
/* DYNAMIC */
|
|
2380
|
-
|
|
2381
|
-
}, 1024
|
|
2382
|
-
/* DYNAMIC_SLOTS */
|
|
2383
|
-
);
|
|
2384
|
-
}), 128
|
|
2385
|
-
/* KEYED_FRAGMENT */
|
|
2386
|
-
))], 512
|
|
2387
|
-
/* NEED_PATCH */
|
|
2388
|
-
), [[external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.vShow, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(fileList).length > 0]]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_7, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.renderSlot)(_ctx.$slots, "loadingFilesSwitch"), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_8, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_upload, {
|
|
2199
|
+
_: 2 /* DYNAMIC */
|
|
2200
|
+
}, 1032 /* PROPS, DYNAMIC_SLOTS */, ["onClick"])])]),
|
|
2201
|
+
_: 2 /* DYNAMIC */
|
|
2202
|
+
}, 1024 /* DYNAMIC_SLOTS */);
|
|
2203
|
+
}), 128 /* KEYED_FRAGMENT */))]),
|
|
2204
|
+
_: 2 /* DYNAMIC */
|
|
2205
|
+
}, 1024 /* DYNAMIC_SLOTS */);
|
|
2206
|
+
}), 128 /* KEYED_FRAGMENT */))], 512 /* NEED_PATCH */), [[external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.vShow, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(fileList).length > 0]]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_7, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.renderSlot)(_ctx.$slots, "loadingFilesSwitch"), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_8, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_upload, {
|
|
2389
2207
|
action: "",
|
|
2390
2208
|
"show-file-list": false,
|
|
2391
2209
|
"auto-upload": false,
|
|
@@ -2399,55 +2217,29 @@ const __default__ = {
|
|
|
2399
2217
|
title: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).selectFiles,
|
|
2400
2218
|
type: "primary"
|
|
2401
2219
|
}, {
|
|
2402
|
-
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).selectFiles), 1
|
|
2403
|
-
/*
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
}, 8
|
|
2409
|
-
/* PROPS */
|
|
2410
|
-
, ["title"])]),
|
|
2411
|
-
_: 1
|
|
2412
|
-
/* STABLE */
|
|
2413
|
-
|
|
2414
|
-
}, 8
|
|
2415
|
-
/* PROPS */
|
|
2416
|
-
, ["accept"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_button, {
|
|
2220
|
+
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).selectFiles), 1 /* TEXT */)]),
|
|
2221
|
+
_: 1 /* STABLE */
|
|
2222
|
+
}, 8 /* PROPS */, ["title"])]),
|
|
2223
|
+
_: 1 /* STABLE */
|
|
2224
|
+
}, 8 /* PROPS */, ["accept"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_button, {
|
|
2417
2225
|
onClick: _cache[1] || (_cache[1] = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withModifiers)($event => removeFiles(), ["stop"])),
|
|
2418
2226
|
title: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).clearFiles,
|
|
2419
2227
|
type: "primary"
|
|
2420
2228
|
}, {
|
|
2421
|
-
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).clearFiles), 1
|
|
2422
|
-
/*
|
|
2423
|
-
|
|
2424
|
-
_: 1
|
|
2425
|
-
/* STABLE */
|
|
2426
|
-
|
|
2427
|
-
}, 8
|
|
2428
|
-
/* PROPS */
|
|
2429
|
-
, ["title"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_button, {
|
|
2229
|
+
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).clearFiles), 1 /* TEXT */)]),
|
|
2230
|
+
_: 1 /* STABLE */
|
|
2231
|
+
}, 8 /* PROPS */, ["title"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_button, {
|
|
2430
2232
|
onClick: _cache[2] || (_cache[2] = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withModifiers)($event => loadFiles(), ["stop"])),
|
|
2431
2233
|
title: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).loadFiles,
|
|
2432
2234
|
type: "primary",
|
|
2433
2235
|
disabled: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(disabled),
|
|
2434
2236
|
loading: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(loadingFile)
|
|
2435
2237
|
}, {
|
|
2436
|
-
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).loadFiles), 1
|
|
2437
|
-
/*
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
}, 8
|
|
2443
|
-
/* PROPS */
|
|
2444
|
-
, ["title", "disabled", "loading"])])])]),
|
|
2445
|
-
_: 3
|
|
2446
|
-
/* FORWARDED */
|
|
2447
|
-
|
|
2448
|
-
}, 8
|
|
2449
|
-
/* PROPS */
|
|
2450
|
-
, ["label"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_tab_pane, {
|
|
2238
|
+
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).loadFiles), 1 /* TEXT */)]),
|
|
2239
|
+
_: 1 /* STABLE */
|
|
2240
|
+
}, 8 /* PROPS */, ["title", "disabled", "loading"])])])]),
|
|
2241
|
+
_: 3 /* FORWARDED */
|
|
2242
|
+
}, 8 /* PROPS */, ["label"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_tab_pane, {
|
|
2451
2243
|
label: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).urlData,
|
|
2452
2244
|
name: "url"
|
|
2453
2245
|
}, {
|
|
@@ -2469,29 +2261,13 @@ const __default__ = {
|
|
|
2469
2261
|
key: item.name,
|
|
2470
2262
|
label: item.name,
|
|
2471
2263
|
value: index
|
|
2472
|
-
}, null, 8
|
|
2473
|
-
|
|
2474
|
-
|
|
2475
|
-
|
|
2476
|
-
|
|
2477
|
-
|
|
2478
|
-
|
|
2479
|
-
/* STABLE */
|
|
2480
|
-
|
|
2481
|
-
}, 8
|
|
2482
|
-
/* PROPS */
|
|
2483
|
-
, ["modelValue"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("span", _hoisted_9, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSourceType).description), 1
|
|
2484
|
-
/* TEXT */
|
|
2485
|
-
)]),
|
|
2486
|
-
_: 1
|
|
2487
|
-
/* STABLE */
|
|
2488
|
-
|
|
2489
|
-
}, 8
|
|
2490
|
-
/* PROPS */
|
|
2491
|
-
, ["label"])]),
|
|
2492
|
-
_: 1
|
|
2493
|
-
/* STABLE */
|
|
2494
|
-
|
|
2264
|
+
}, null, 8 /* PROPS */, ["label", "value"]);
|
|
2265
|
+
}), 128 /* KEYED_FRAGMENT */))]),
|
|
2266
|
+
_: 1 /* STABLE */
|
|
2267
|
+
}, 8 /* PROPS */, ["modelValue"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("span", _hoisted_9, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSourceType).description), 1 /* TEXT */)]),
|
|
2268
|
+
_: 1 /* STABLE */
|
|
2269
|
+
}, 8 /* PROPS */, ["label"])]),
|
|
2270
|
+
_: 1 /* STABLE */
|
|
2495
2271
|
}), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_row, null, {
|
|
2496
2272
|
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_form_item, {
|
|
2497
2273
|
label: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).url
|
|
@@ -2500,20 +2276,10 @@ const __default__ = {
|
|
|
2500
2276
|
modelValue: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSource).url,
|
|
2501
2277
|
"onUpdate:modelValue": _cache[4] || (_cache[4] = $event => (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSource).url = $event),
|
|
2502
2278
|
placeholder: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSourceType).urlPlaceholder
|
|
2503
|
-
}, null, 8
|
|
2504
|
-
/*
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
)]),
|
|
2508
|
-
_: 1
|
|
2509
|
-
/* STABLE */
|
|
2510
|
-
|
|
2511
|
-
}, 8
|
|
2512
|
-
/* PROPS */
|
|
2513
|
-
, ["label"])]),
|
|
2514
|
-
_: 1
|
|
2515
|
-
/* STABLE */
|
|
2516
|
-
|
|
2279
|
+
}, null, 8 /* PROPS */, ["modelValue", "placeholder"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("span", _hoisted_10, (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSourceType).urlPlaceholder), 1 /* TEXT */)]),
|
|
2280
|
+
_: 1 /* STABLE */
|
|
2281
|
+
}, 8 /* PROPS */, ["label"])]),
|
|
2282
|
+
_: 1 /* STABLE */
|
|
2517
2283
|
}), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_row, null, {
|
|
2518
2284
|
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_form_item, {
|
|
2519
2285
|
label: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).nodeName
|
|
@@ -2522,65 +2288,32 @@ const __default__ = {
|
|
|
2522
2288
|
modelValue: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSource).name,
|
|
2523
2289
|
"onUpdate:modelValue": _cache[5] || (_cache[5] = $event => (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSource).name = $event),
|
|
2524
2290
|
placeholder: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(dataSourceType).namePlaceholder
|
|
2525
|
-
}, null, 8
|
|
2526
|
-
/*
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
/* STABLE */
|
|
2530
|
-
|
|
2531
|
-
}, 8
|
|
2532
|
-
/* PROPS */
|
|
2533
|
-
, ["label"])]),
|
|
2534
|
-
_: 1
|
|
2535
|
-
/* STABLE */
|
|
2536
|
-
|
|
2291
|
+
}, null, 8 /* PROPS */, ["modelValue", "placeholder"])]),
|
|
2292
|
+
_: 1 /* STABLE */
|
|
2293
|
+
}, 8 /* PROPS */, ["label"])]),
|
|
2294
|
+
_: 1 /* STABLE */
|
|
2537
2295
|
})]),
|
|
2538
|
-
_: 1
|
|
2539
|
-
/* STABLE */
|
|
2540
|
-
|
|
2296
|
+
_: 1 /* STABLE */
|
|
2541
2297
|
}), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_11, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.renderSlot)(_ctx.$slots, "loadingURLSwitch"), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createElementVNode)("div", _hoisted_12, [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_button, {
|
|
2542
2298
|
onClick: _cache[6] || (_cache[6] = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withModifiers)($event => loadURL(), ["stop"])),
|
|
2543
2299
|
title: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).loadFiles,
|
|
2544
2300
|
type: "primary"
|
|
2545
2301
|
}, {
|
|
2546
|
-
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).loadFiles), 1
|
|
2547
|
-
/*
|
|
2548
|
-
|
|
2549
|
-
_: 1
|
|
2550
|
-
/* STABLE */
|
|
2551
|
-
|
|
2552
|
-
}, 8
|
|
2553
|
-
/* PROPS */
|
|
2554
|
-
, ["title"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_button, {
|
|
2302
|
+
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).loadFiles), 1 /* TEXT */)]),
|
|
2303
|
+
_: 1 /* STABLE */
|
|
2304
|
+
}, 8 /* PROPS */, ["title"]), (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createVNode)(_component_kq_button, {
|
|
2555
2305
|
onClick: _cache[7] || (_cache[7] = (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withModifiers)($event => reset(), ["stop"])),
|
|
2556
2306
|
title: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).reset
|
|
2557
2307
|
}, {
|
|
2558
|
-
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).reset), 1
|
|
2559
|
-
/*
|
|
2560
|
-
|
|
2561
|
-
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
|
|
2565
|
-
/* PROPS */
|
|
2566
|
-
, ["title"])])])]),
|
|
2567
|
-
_: 3
|
|
2568
|
-
/* FORWARDED */
|
|
2569
|
-
|
|
2570
|
-
}, 8
|
|
2571
|
-
/* PROPS */
|
|
2572
|
-
, ["label"])])]),
|
|
2573
|
-
_: 3
|
|
2574
|
-
/* FORWARDED */
|
|
2575
|
-
|
|
2576
|
-
}, 8
|
|
2577
|
-
/* PROPS */
|
|
2578
|
-
, ["modelValue"])], 2
|
|
2579
|
-
/* CLASS */
|
|
2580
|
-
);
|
|
2308
|
+
default: (0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.withCtx)(() => [(0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.createTextVNode)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.toDisplayString)((0,external_root_Vue_commonjs_vue_commonjs2_vue_amd_vue_.unref)(language).reset), 1 /* TEXT */)]),
|
|
2309
|
+
_: 1 /* STABLE */
|
|
2310
|
+
}, 8 /* PROPS */, ["title"])])])]),
|
|
2311
|
+
_: 3 /* FORWARDED */
|
|
2312
|
+
}, 8 /* PROPS */, ["label"])])]),
|
|
2313
|
+
_: 3 /* FORWARDED */
|
|
2314
|
+
}, 8 /* PROPS */, ["modelValue"])], 2 /* CLASS */);
|
|
2581
2315
|
};
|
|
2582
2316
|
}
|
|
2583
|
-
|
|
2584
2317
|
}));
|
|
2585
2318
|
;// CONCATENATED MODULE: ./src/webgl/adddata/AddData.vue?vue&type=script&setup=true&lang=js
|
|
2586
2319
|
|
|
@@ -2602,13 +2335,11 @@ var init_js_default = /*#__PURE__*/__webpack_require__.n(init_js_);
|
|
|
2602
2335
|
|
|
2603
2336
|
|
|
2604
2337
|
|
|
2605
|
-
|
|
2606
2338
|
AddData.install = (Vue, opts) => {
|
|
2607
2339
|
init_js_default()(Vue, opts);
|
|
2608
2340
|
Vue.component(AddData.name, AddData);
|
|
2609
2341
|
};
|
|
2610
2342
|
|
|
2611
|
-
|
|
2612
2343
|
}();
|
|
2613
2344
|
/******/ return __webpack_exports__;
|
|
2614
2345
|
/******/ })()
|