|
@@ -39,6 +39,10 @@ export default {
|
|
type: String,
|
|
type: String,
|
|
default: "A",
|
|
default: "A",
|
|
},
|
|
},
|
|
|
|
+ unit: {
|
|
|
|
+ type: String,
|
|
|
|
+ default: "公顷",
|
|
|
|
+ },
|
|
},
|
|
},
|
|
mounted() {
|
|
mounted() {
|
|
this.initEchart(
|
|
this.initEchart(
|
|
@@ -71,6 +75,13 @@ export default {
|
|
// Use axis to trigger tooltip
|
|
// Use axis to trigger tooltip
|
|
type: "shadow", // 'shadow' as default; can also be 'line' or 'shadow'
|
|
type: "shadow", // 'shadow' as default; can also be 'line' or 'shadow'
|
|
},
|
|
},
|
|
|
|
+ formatter: function (params) {
|
|
|
|
+ let relVal = params[0].name;
|
|
|
|
+ for (let i = 0; i < params.length; i++) {
|
|
|
|
+ relVal += `<br/>${params[i].marker}${params[i].value}公顷`;
|
|
|
|
+ }
|
|
|
|
+ return relVal;
|
|
|
|
+ },
|
|
},
|
|
},
|
|
legend: {
|
|
legend: {
|
|
bottom: "0%",
|
|
bottom: "0%",
|