lex 1 سال پیش
والد
کامیت
6bbaea6fe6

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

@@ -102,6 +102,26 @@ export default defineComponent({
       const chartDom = document.getElementById('studentEcharts')
       myChart = echarts.init(chartDom as HTMLDivElement)
       const option = {
+        tooltip: {
+          trigger: 'axis',
+          confine: true,
+          axisPointer: {
+            type: 'shadow',
+            label: {
+              formatter: (params: any) => {
+                if (params.value.length > 16) {
+                  return params.value.substring(0, 16) + '...'
+                }
+                return params.value
+              }
+            }
+          },
+          textStyle: {
+            color: '#131415',
+            width: 100,
+            overflow: 'truncate'
+          }
+        },
         dataZoom: [
           {
             type: 'inside',
@@ -155,6 +175,7 @@ export default defineComponent({
         },
         series: [
           {
+            name: '出勤率',
             type: 'bar',
             showBackground: false,
             barWidth: 20,

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

@@ -205,12 +205,13 @@ export default defineComponent({
         },
         tooltip: {
           trigger: 'axis',
+          confine: true,
           axisPointer: {
             type: 'shadow',
             label: {
               formatter: (params: any) => {
-                if (params.value.length > 11) {
-                  return params.value.substring(0, 11) + '...'
+                if (params.value.length > 16) {
+                  return params.value.substring(0, 16) + '...'
                 }
                 return params.value
               }

+ 23 - 1
src/school/train-report/modal/train-class.tsx

@@ -95,6 +95,26 @@ export default defineComponent({
       const chartDom = document.getElementById('classEcharts')
       myChart = echarts.init(chartDom as HTMLDivElement)
       const option = {
+        tooltip: {
+          trigger: 'axis',
+          confine: true,
+          axisPointer: {
+            type: 'shadow',
+            label: {
+              formatter: (params: any) => {
+                if (params.value.length > 16) {
+                  return params.value.substring(0, 16) + '...'
+                }
+                return params.value
+              }
+            }
+          },
+          textStyle: {
+            color: '#131415',
+            width: 100,
+            overflow: 'truncate'
+          }
+        },
         dataZoom: [
           {
             type: 'inside',
@@ -102,7 +122,8 @@ export default defineComponent({
             startValue: 0,
             endValue: 4,
             filterMode: 'none',
-            zoomLock: true
+            zoomLock: true,
+            throttle: 100
           }
         ],
         xAxis: {
@@ -148,6 +169,7 @@ export default defineComponent({
         },
         series: [
           {
+            name: '本周训练',
             type: 'bar',
             showBackground: false,
             barWidth: 20,

+ 21 - 0
src/school/train-report/modal/train-over-work.tsx

@@ -102,6 +102,26 @@ export default defineComponent({
       const chartDom = document.getElementById('overWorkEcharts')
       myChart = echarts.init(chartDom as HTMLDivElement)
       const option = {
+        tooltip: {
+          trigger: 'axis',
+          confine: true,
+          axisPointer: {
+            type: 'shadow',
+            label: {
+              formatter: (params: any) => {
+                if (params.value.length > 16) {
+                  return params.value.substring(0, 16) + '...'
+                }
+                return params.value
+              }
+            }
+          },
+          textStyle: {
+            color: '#131415',
+            width: 100,
+            overflow: 'truncate'
+          }
+        },
         dataZoom: [
           {
             type: 'inside',
@@ -154,6 +174,7 @@ export default defineComponent({
         },
         series: [
           {
+            name: forms.type === 'target' ? '作业完成率' : '作业提交率',
             type: 'bar',
             showBackground: false,
             barWidth: 20,

+ 2 - 2
src/school/train-report/month-report.tsx

@@ -101,9 +101,9 @@ export default defineComponent({
         reportData.startTime = data.startTime || ''
         reportData.endTime = data.endTime || ''
 
-        const courseware = reportData.COURSEWARE
+        const courseware = data.notTargetClassList
         for (const i in courseware) {
-          i != 'TOTAL' && reportData.coursewareList.push(reportCourseType[i])
+          reportData.coursewareList.push(courseware[i].classGroupName)
         }
       } catch {
         //

+ 2 - 2
src/school/train-report/week-report.tsx

@@ -94,9 +94,9 @@ export default defineComponent({
         reportData.startTime = data.startTime || ''
         reportData.endTime = data.endTime || ''
 
-        const courseware = reportData.COURSEWARE
+        const courseware = data.notTargetClassList
         for (const i in courseware) {
-          i != 'TOTAL' && reportData.coursewareList.push(reportCourseType[i])
+          reportData.coursewareList.push(courseware[i].classGroupName)
         }
       } catch {
         //