|
@@ -266,7 +266,7 @@ export default {
|
|
|
title: {
|
|
|
showTitle: true,
|
|
|
text: `${
|
|
|
- tabActive === "bm" ? "部门培训课时排行" : "职工培训课时排行top20"
|
|
|
+ tabActive === "bm" ? "部门培训课程排行" : "职工培训时长排行top20"
|
|
|
}`,
|
|
|
subtext: "可滚轮缩放、左右拖动查看",
|
|
|
x: "center",
|
|
@@ -281,6 +281,7 @@ export default {
|
|
|
},
|
|
|
yAxis: {
|
|
|
type: "value",
|
|
|
+ minInterval: 1,
|
|
|
},
|
|
|
tooltip: {
|
|
|
show: true,
|
|
@@ -289,7 +290,7 @@ export default {
|
|
|
let str = "";
|
|
|
data.forEach((ele) => {
|
|
|
let circle = `<span style="display:inline-block;margin-right:5px;border-radius:50%;width:10px;height:10px;left:5px;background-color:${ele.color}"></span>`;
|
|
|
- str += circle + `${ele.name}: ${ele.value}分钟 <br />`;
|
|
|
+ str += circle + `${ele.name} : ${ele.value}${tabActive === 'bm' ? '' : '分钟'} <br />`;
|
|
|
});
|
|
|
return str;
|
|
|
},
|
|
@@ -332,7 +333,7 @@ export default {
|
|
|
|
|
|
res.data.forEach((ele) => {
|
|
|
xAxisData.push(tabActive === "bm" ? ele.deptName : ele.realName);
|
|
|
- pxSeriesData.push(ele.total);
|
|
|
+ pxSeriesData.push(ele.total > 0 ? (ele.passed / ele.total) * 100 : 0);
|
|
|
});
|
|
|
|
|
|
option = {
|
|
@@ -361,7 +362,7 @@ export default {
|
|
|
let str = "";
|
|
|
data.forEach((ele) => {
|
|
|
let circle = `<span style="display:inline-block;margin-right:5px;border-radius:50%;width:10px;height:10px;left:5px;background-color:${ele.color}"></span>`;
|
|
|
- str += circle + `${ele.name}: ${ele.value}% <br />`;
|
|
|
+ str += circle + `${ele.name} : ${ele.value}% <br />`;
|
|
|
});
|
|
|
return str;
|
|
|
},
|