egovamap 0.15.4 → 0.15.5
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/egovamap/egovaBI.js +11 -9
- package/egovamap/egovagis.js +7 -0
- package/egovamap/egovagisviewer.js +1 -0
- package/egovamap/egovamap.js +11 -1
- package/package.json +1 -1
package/egovamap/egovaBI.js
CHANGED
|
@@ -377,7 +377,7 @@ var egovaBI = function(globeMap, gisMap, mapType){
|
|
|
377
377
|
this.drawOtherParts = function (options, data) {
|
|
378
378
|
var self = this;
|
|
379
379
|
const geomType = options.geomType;
|
|
380
|
-
let queryParam = options.queryParam;
|
|
380
|
+
let queryParam = options.queryParam || {};
|
|
381
381
|
function showParts(data) {
|
|
382
382
|
|
|
383
383
|
}
|
|
@@ -391,17 +391,17 @@ var egovaBI = function(globeMap, gisMap, mapType){
|
|
|
391
391
|
const keyValue = null;
|
|
392
392
|
const clearMap = queryParam.clearMap || true;
|
|
393
393
|
let inStyle = queryParam.style || {
|
|
394
|
-
color: "
|
|
394
|
+
color: "blue"
|
|
395
395
|
};
|
|
396
396
|
let inHStyle = queryParam.hStyle || {
|
|
397
|
-
color: "
|
|
397
|
+
color: "blue"
|
|
398
398
|
};
|
|
399
399
|
let style = null, hStyle = null;
|
|
400
400
|
if (geomType == 1) {
|
|
401
401
|
} else if (geomType == 2) {
|
|
402
402
|
style = {
|
|
403
403
|
type: "simple-line", // autocasts as new SimpleLineSymbol()
|
|
404
|
-
color: inStyle.color || "
|
|
404
|
+
color: inStyle.color || "blue",
|
|
405
405
|
width: inStyle.width || "2px",
|
|
406
406
|
style: inStyle.style || "solid",
|
|
407
407
|
cap: inStyle.cap || "round",
|
|
@@ -409,7 +409,7 @@ var egovaBI = function(globeMap, gisMap, mapType){
|
|
|
409
409
|
};
|
|
410
410
|
hStyle = {
|
|
411
411
|
type: "simple-line", // autocasts as new SimpleLineSymbol()
|
|
412
|
-
color: inHStyle.color || "
|
|
412
|
+
color: inHStyle.color || "red",
|
|
413
413
|
width: inHStyle.width || inStyle.width || "2px",
|
|
414
414
|
style: inHStyle.style || inStyle.style || "solid",
|
|
415
415
|
cap: inHStyle.cap || inStyle.cap || "round",
|
|
@@ -421,7 +421,7 @@ var egovaBI = function(globeMap, gisMap, mapType){
|
|
|
421
421
|
color: inStyle.color || [51, 51, 204, 0.9],
|
|
422
422
|
style: inStyle.style || "solid",
|
|
423
423
|
outline: { // autocasts as new SimpleLineSymbol()
|
|
424
|
-
color: inStyle.outlineColor || "
|
|
424
|
+
color: inStyle.outlineColor || "blue",
|
|
425
425
|
width: inStyle.outlineWidth || "1px",
|
|
426
426
|
style: inStyle.outlineStyle || "solid",
|
|
427
427
|
cap: inStyle.outlineCap || "round",
|
|
@@ -433,7 +433,7 @@ var egovaBI = function(globeMap, gisMap, mapType){
|
|
|
433
433
|
color: inHStyle.color || [51, 51, 204, 0.9],
|
|
434
434
|
style: inHStyle.style || inStyle.style || "solid",
|
|
435
435
|
outline: { // autocasts as new SimpleLineSymbol()
|
|
436
|
-
color: inHStyle.outlineColor || "
|
|
436
|
+
color: inHStyle.outlineColor || "red",
|
|
437
437
|
width: inHStyle.outlineWidth || inStyle.outlineWidth || "1px",
|
|
438
438
|
style: inHStyle.outlineStyle || inStyle.outlineStyle || "solid",
|
|
439
439
|
cap: inHStyle.outlineCap || inStyle.outlineCap || "round",
|
|
@@ -448,10 +448,12 @@ var egovaBI = function(globeMap, gisMap, mapType){
|
|
|
448
448
|
const geometry = null;
|
|
449
449
|
const where = queryParam.where || "1=1";
|
|
450
450
|
const opts = {
|
|
451
|
-
layerId: layerName
|
|
451
|
+
layerId: layerName,
|
|
452
|
+
mouseOverCallback: queryParam.mouseOverCallback
|
|
452
453
|
};
|
|
453
454
|
|
|
454
|
-
let param = [layerID, keyField, keyValue, clearMap, style, hStyle, bZoom, randomColor, labelField, labelstyle, geometry, where, null, null, opts];
|
|
455
|
+
let param = [layerID, keyField, keyValue, clearMap, style, hStyle, bZoom, randomColor, labelField, labelstyle, geometry, where, null, null, opts, null, null, null, null, null, null, queryParam.callback];
|
|
456
|
+
//let param = [layerID, keyField, keyValue, clearMap, style, hStyle, bZoom, randomColor, labelField, labelstyle, geometry, where, null, null, opts, null, null, null, null, queryParam.callback];
|
|
455
457
|
if (globeMap) {
|
|
456
458
|
gisMap.locateFeatureByIDs(...param);
|
|
457
459
|
} else if (gisMap) {
|
package/egovamap/egovagis.js
CHANGED
|
@@ -581,6 +581,13 @@ var EGovaGISMap = function ($container, pScene, prefix, gisParams, mapConfig,con
|
|
|
581
581
|
}
|
|
582
582
|
scene.fire((msgPrefix + ":getBuffer"), {args: args}, parentScene, true);
|
|
583
583
|
}
|
|
584
|
+
/* 获取多点的缓冲区 */
|
|
585
|
+
that.getMultiPointBuffer = function(points, radius){
|
|
586
|
+
if (scene == null)
|
|
587
|
+
return;
|
|
588
|
+
scene.fire((msgPrefix + ":getMultiPointBuffer"), {args: args}, parentScene, true);
|
|
589
|
+
|
|
590
|
+
}
|
|
584
591
|
/* 显示监督员责任网格 */
|
|
585
592
|
that.showPatrolDutygridCells = function(infoJson, zoom, clickCallback) {
|
|
586
593
|
if (scene == null)
|
|
@@ -751,6 +751,7 @@ var EGovaGISMap = function ($container, pScene, prefix, gisParams, mapConfig, co
|
|
|
751
751
|
var cb = function (type, data) {
|
|
752
752
|
if (callback) {
|
|
753
753
|
if (type == 'locateFeatureByIDsCallback') callback(data);
|
|
754
|
+
else if (type == 'locateFeatureByIDsMouseOver') options && options.mouseOverCallback(data);
|
|
754
755
|
} else {
|
|
755
756
|
that.fireCallback(type, data);
|
|
756
757
|
}
|
package/egovamap/egovamap.js
CHANGED
|
@@ -1793,7 +1793,17 @@ var EGovaMap = function (containerID, callback, mapConfig, mapType, mapParam, co
|
|
|
1793
1793
|
}
|
|
1794
1794
|
|
|
1795
1795
|
}
|
|
1796
|
-
|
|
1796
|
+
/**
|
|
1797
|
+
* @param {*} points 点位坐标list,[[x,y],...]
|
|
1798
|
+
* @param {*} radius 缓冲距离,单位为米
|
|
1799
|
+
* @returns
|
|
1800
|
+
*/
|
|
1801
|
+
that.getMultiPointBuffer = function(points, radius){
|
|
1802
|
+
if (scene == null)
|
|
1803
|
+
return;
|
|
1804
|
+
if (gisMap != null)
|
|
1805
|
+
gismap.getMultiPointBuffer(this, arguments);
|
|
1806
|
+
}
|
|
1797
1807
|
|
|
1798
1808
|
/* 显示监督员责任网格 */
|
|
1799
1809
|
that.showPatrolDutygridCells = function (infoJson, zoom, clickCallback) {
|