瀏覽代碼

修改数据

lex 2 年之前
父節點
當前提交
c5c23234f3

+ 2 - 2
src/school/train-report/modal/student-attendance.tsx

@@ -77,14 +77,14 @@ export default defineComponent({
       let textColor = '#1B4FD7'
       for (const i in data) {
         if (i === 'TOTAL') {
-          forms.total = data[i] * 100
+          forms.total = Math.ceil(data[i] * 100)
           if (forms.total <= 59) {
             lineColor = '#FF8057'
             textColor = '#F67146'
           }
         } else {
           titleList.push(reportCourseType[i])
-          valueList.push(data[i] * 100)
+          valueList.push(Math.ceil(data[i] * 100))
         }
       }
 

+ 2 - 2
src/school/train-report/modal/teacher-attendance.tsx

@@ -76,14 +76,14 @@ export default defineComponent({
       let textColor = '#1B4FD7'
       for (const i in data) {
         if (i === 'TOTAL') {
-          forms.total = data[i] * 100
+          forms.total = Math.ceil(data[i] * 100)
           if (forms.total <= 59) {
             lineColor = '#FF8057'
             textColor = '#F67146'
           }
         } else {
           titleList.push(reportCourseType[i])
-          valueList.push(data[i] * 100)
+          valueList.push(Math.ceil(data[i] * 100))
         }
       }