|
@@ -87,25 +87,33 @@
|
|
|
class="stat-card rounded-lg border-l-4 border-[var(--czr-main-color)] bg-gray-50 p-3"
|
|
|
>
|
|
|
<div class="text-xs text-gray-500">当前难度等级</div>
|
|
|
- <div class="mt-1 text-xl font-bold text-gray-800">S</div>
|
|
|
+ <div class="mt-1 text-xl font-bold text-gray-800">
|
|
|
+ {{ state.statistic.card.data.level }}
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<div
|
|
|
class="stat-card rounded-lg border-l-4 border-[var(--czr-main-color)] bg-gray-50 p-3"
|
|
|
>
|
|
|
<div class="text-xs text-gray-500">正确率</div>
|
|
|
- <div class="mt-1 text-xl font-bold text-gray-800">85%</div>
|
|
|
+ <div class="mt-1 text-xl font-bold text-gray-800">
|
|
|
+ {{ state.statistic.card.data.totalAccuracyRate }}
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<div
|
|
|
class="stat-card rounded-lg border-l-4 border-[var(--czr-main-color)] bg-gray-50 p-3"
|
|
|
>
|
|
|
<div class="text-xs text-gray-500">待提升板块</div>
|
|
|
- <div class="mt-1 text-xl font-bold text-gray-800">文言文</div>
|
|
|
+ <div class="mt-1 text-sm font-bold text-gray-800">
|
|
|
+ {{ state.statistic.card.data.maxIncorrectSections }}
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<div
|
|
|
class="stat-card rounded-lg border-l-4 border-[var(--czr-main-color)] bg-gray-50 p-3"
|
|
|
>
|
|
|
<div class="text-xs text-gray-500">优秀板块</div>
|
|
|
- <div class="mt-1 text-xl font-bold text-gray-800">作文</div>
|
|
|
+ <div class="mt-1 text-sm font-bold text-gray-800">
|
|
|
+ {{ state.statistic.card.data.maxCorrectSections }}
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
@@ -349,10 +357,7 @@
|
|
|
class="subject-questions-btn bg-subject-color ml-auto flex items-center rounded-full px-3 py-1 text-sm"
|
|
|
@click="
|
|
|
$router.push({
|
|
|
- name: $route.meta.subjectId + 'plan',
|
|
|
- query: {
|
|
|
- onlyError: true,
|
|
|
- },
|
|
|
+ name: $route.meta.subjectId + 'error',
|
|
|
})
|
|
|
"
|
|
|
>
|
|
@@ -430,7 +435,9 @@ import chart3 from './chart-3.vue'
|
|
|
import chart4 from './chart-4.vue'
|
|
|
import {
|
|
|
trainingCampLearningPlanList,
|
|
|
+ trainingCampQuestionTypeIpadGetExerciseCompletionStats,
|
|
|
trainingCampQuestionTypeIpadGetKnowledgeMasteryStats,
|
|
|
+ trainingCampQuestionTypeIpadGetSectionImprovementStats,
|
|
|
trainingCampQuestionTypeIpadGetWrongStatInfo,
|
|
|
} from '@/api/modules/study'
|
|
|
import { oneDayTime, YM, YMD } from '@/utils/czr-util'
|
|
@@ -468,6 +475,7 @@ const state: any = reactive({
|
|
|
},
|
|
|
card: {
|
|
|
loading: false,
|
|
|
+ data: {},
|
|
|
},
|
|
|
},
|
|
|
error: {
|
|
@@ -552,6 +560,17 @@ const initTraining = () => {
|
|
|
})
|
|
|
}
|
|
|
const initStatistic = () => {
|
|
|
+ state.statistic.radar.loading = true
|
|
|
+ trainingCampQuestionTypeIpadGetKnowledgeMasteryStats(
|
|
|
+ AppStore.studentInfo?.grade,
|
|
|
+ route.meta.subjectId,
|
|
|
+ )
|
|
|
+ .then(({ data }: any) => {
|
|
|
+ state.statistic.radar.data = data
|
|
|
+ })
|
|
|
+ .finally(() => {
|
|
|
+ state.statistic.radar.loading = false
|
|
|
+ })
|
|
|
state.statistic.line.loading = true
|
|
|
trainingCampLearningPlanList({
|
|
|
pageNum: 1,
|
|
@@ -570,17 +589,27 @@ const initStatistic = () => {
|
|
|
.finally(() => {
|
|
|
state.statistic.line.loading = false
|
|
|
})
|
|
|
-
|
|
|
- state.statistic.radar.loading = true
|
|
|
- trainingCampQuestionTypeIpadGetKnowledgeMasteryStats(
|
|
|
+ state.statistic.bar.loading = true
|
|
|
+ trainingCampQuestionTypeIpadGetExerciseCompletionStats(
|
|
|
AppStore.studentInfo?.grade,
|
|
|
route.meta.subjectId,
|
|
|
)
|
|
|
.then(({ data }: any) => {
|
|
|
- state.statistic.radar.data = data
|
|
|
+ state.statistic.bar.data = data
|
|
|
})
|
|
|
.finally(() => {
|
|
|
- state.statistic.radar.loading = false
|
|
|
+ state.statistic.bar.loading = false
|
|
|
+ })
|
|
|
+ state.statistic.card.loading = true
|
|
|
+ trainingCampQuestionTypeIpadGetSectionImprovementStats(
|
|
|
+ AppStore.studentInfo?.grade,
|
|
|
+ route.meta.subjectId,
|
|
|
+ )
|
|
|
+ .then(({ data }: any) => {
|
|
|
+ state.statistic.card.data = data
|
|
|
+ })
|
|
|
+ .finally(() => {
|
|
|
+ state.statistic.card.loading = false
|
|
|
})
|
|
|
}
|
|
|
const initError = () => {
|