修改禅道bug
This commit is contained in:
@@ -84,7 +84,7 @@ export default {
|
||||
|
||||
return dataMap.map(itemInfo => {
|
||||
const rawItem = rawData[itemInfo.key] || {};
|
||||
const progress = Math.max(0, Math.round((rawItem.rate || 0)));
|
||||
const progress = rawItem.rate || 0;
|
||||
|
||||
return {
|
||||
unit: itemInfo.unit,
|
||||
|
||||
@@ -89,7 +89,7 @@ export default {
|
||||
unit: mappingItem.unit,
|
||||
targetValue: indicatorData.target, // 目标值
|
||||
currentValue: indicatorData.real, // 实际值
|
||||
progress: indicatorData.rate ? Math.round(indicatorData.rate) : 0, // 完成率(百分比,四舍五入)
|
||||
progress: indicatorData.rate || 0, // 完成率
|
||||
path: mappingItem.path // 路由路径
|
||||
};
|
||||
});
|
||||
|
||||
@@ -101,7 +101,7 @@ export default {
|
||||
return dataMap.map(itemInfo => {
|
||||
const rawItem = rawData[itemInfo.key] || {};
|
||||
// 计算进度百分比,确保不小于0
|
||||
const progress = Math.max(0, Math.round((rawItem.rate || 0)));
|
||||
const progress = rawItem.rate || 0;
|
||||
|
||||
return {
|
||||
unit: itemInfo.unit,
|
||||
|
||||
Reference in New Issue
Block a user