|
@@ -1,4 +1,4 @@
|
|
-
|
|
|
|
|
|
+import titleBg from '@/assets/images/map-infowindow-title-bg.png'
|
|
|
|
|
|
/**
|
|
/**
|
|
*
|
|
*
|
|
@@ -87,7 +87,9 @@ export function toInt(num) {
|
|
return formatInt(temp, temp.length - 1)
|
|
return formatInt(temp, temp.length - 1)
|
|
}
|
|
}
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+/**
|
|
|
|
+ * 填充区县数据
|
|
|
|
+ */
|
|
export const formatCityData = (data) => {
|
|
export const formatCityData = (data) => {
|
|
return citys.map(item => {
|
|
return citys.map(item => {
|
|
let temp = data.find(i => i.name === item)
|
|
let temp = data.find(i => i.name === item)
|
|
@@ -97,3 +99,14 @@ export const formatCityData = (data) => {
|
|
}
|
|
}
|
|
})
|
|
})
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+export function createMapChartWindowInfo(ctx, render) {
|
|
|
|
+ return `<div>
|
|
|
|
+ <div style="background: url('${titleBg}') center center no-repeat;
|
|
|
|
+ color: #ffb800;font-size: 16px;
|
|
|
|
+ font-style: normal;
|
|
|
|
+ font-weight: 400;padding: 5px;">${ctx.title}</div>
|
|
|
|
+ <div style="padding: 5px;" >${render()}</divs>
|
|
|
|
+ </div>`;
|
|
|
|
+}
|