Skip to content

Commit

Permalink
Fix path name for k8s obj
Browse files Browse the repository at this point in the history
  • Loading branch information
cb-github-robot authored Oct 25, 2024
2 parents d69dfae + 48dc045 commit c179140
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ var iconStyleK8s = new Style({
crossOrigin: "anonymous",
src: "img/iconK8s.png",
opacity: 1.0,
scale: 1.0,
scale: 0.7,
}),
});

Expand Down Expand Up @@ -1024,16 +1024,18 @@ function getMci() {
timeout: 10000,
}).then((res) => {
var obj = res.data;
if (obj.cluster != null) {
if (obj.K8sClusterInfo != null) {
var resourceLocation = [];
for (let item of obj.cluster) {
for (let item of obj.K8sClusterInfo) {
resourceLocation.push([
item.connectionConfig.regionDetail.location.longitude * 1 +
(returnAdjustmentPoint(j).ax / zoomLevel) * radius,
item.connectionConfig.regionDetail.location.latitude * 1 - 0.5 +
item.connectionConfig.regionDetail.location.latitude * 1 +
(returnAdjustmentPoint(j).ay / zoomLevel) * radius,
]);
geoResourceLocation.k8s[0] = new MultiPoint([resourceLocation]);
geoResourceLocation.k8s[0] = new MultiPoint([resourceLocation]);
console.log("geoResourceLocation.k8s[0]");
console.log(geoResourceLocation.k8s[0]);
}
} else {
geoResourceLocation.k8s = [];
Expand Down

0 comments on commit c179140

Please sign in to comment.