Jelajahi Sumber

Merge branch 'master' of http://gogs.gisvg.com/YDM/museums-ui

wwj 1 bulan lalu
induk
melakukan
8b93cbe742

+ 3 - 3
src/views/Home/echarts-data.ts

@@ -112,7 +112,7 @@ const yearsData = years.filter(item => {
 // console.log(filteredData,'filteredData');
 const year1 = sourcsData.map(sourcsData => sourcsData.year);
 const purchase = sourcsData.map(sourcsData => sourcsData.purchase);
-const gather = sourcsData.map(filteredData => sourcsData.gather);
+const gather = sourcsData.map(sourcsData => sourcsData.gather);
 const donate = sourcsData.map(sourcsData => sourcsData.donate);
 
 // 进一步处理数据,例如渲染到页面
@@ -203,7 +203,7 @@ export const pieOptions: EChartsOption = {
       color: "#556677",
     },
   },
-  
+
   tooltip: {
     trigger: "item",
     axisPointer: {
@@ -651,7 +651,7 @@ export const mouthOptions: EChartsOption =  {
                 offset: 0.86,
                 /*
 0.86 = (文字 + 文字距下边线的距离)/(文字 + 文字距下边线的距离 + 下边线的宽度)
-                        
+
                         */
                 color: "#fff", // 0% 处的颜色
               },

+ 2 - 6
src/views/museums/specimeninfo/index.vue

@@ -891,7 +891,7 @@ const onSubmit = async () => {
         ctx.lineWidth = 0.5
         ctx.strokeRect(0, 0, canvas.width, canvas.height)
 
-
+        //标题
         // 设置文本对齐方式为居中
         ctx.textAlign = 'center'
         // 设置字体样式
@@ -919,9 +919,6 @@ const onSubmit = async () => {
           }
         }
 
-
-
-
         // 添加副标题
         if (label.subtitle && label.subtitle !== '') {
         ctx.textAlign = 'center'
@@ -936,7 +933,7 @@ const onSubmit = async () => {
           }
         }
 
-
+        //内容
         // 设置文本对齐方式为左对齐
         ctx.textAlign = 'left'
         // 设置字体样式
@@ -950,7 +947,6 @@ const onSubmit = async () => {
         }else {
           y = size.height * 0.55
         }
-
         for (const line of lines) {
           ctx.fillText(line, size.width * 0.15, y)
           y += Math.min(size.width, size.height) * 0.15 // 每行间隔