|
|
@@ -1,7 +1,7 @@
|
|
|
<template>
|
|
|
<!-- 分析报告详情总页面 -->
|
|
|
<div class="analysis_main">
|
|
|
- <div :class="['main_header',{'full_screen':isLianXiao}]" ref="mainHeader">
|
|
|
+ <div :class="['main_header', { 'full_screen': isLianXiao }]" ref="mainHeader">
|
|
|
<div class="header_left">
|
|
|
<span class="back_button" @click="GoBack">
|
|
|
<i class="iconfont icon_return"></i>返回
|
|
|
@@ -27,24 +27,27 @@
|
|
|
|
|
|
<div class="main_content">
|
|
|
<div class="content_right" ref="rightContent" @scroll="ScrollChange">
|
|
|
- <div :class="['content_right_scroll',{'full_screen':isLianXiao}]" ref="contentRightScroll">
|
|
|
+ <div :class="['content_right_scroll', { 'full_screen': isLianXiao }]" ref="contentRightScroll">
|
|
|
<template v-if="isLianXiao">
|
|
|
<div class="mm_body">
|
|
|
<div class="left">
|
|
|
<button class="mm_btn mb_10" :class="{ active: activeBtn === pathOne }"
|
|
|
@click="toPage(pathOne)">成绩分析</button>
|
|
|
|
|
|
- <button v-if="isShowKnowledgeButtons" class="mm_btn mb_10" :class="{ active: activeBtn === pathTwo }"
|
|
|
- @click="toPage(pathTwo)">个性化错题</button>
|
|
|
- <button v-if="!isTotalScore" class="mm_btn mb_10" :class="{ active: activeBtn === pathThree }"
|
|
|
+ <button v-if="isShowKnowledgeButtons" class="mm_btn mb_10"
|
|
|
+ :class="{ active: activeBtn === pathTwo }" @click="toPage(pathTwo)">举一反三</button>
|
|
|
+ <button v-if="!isTotalScore" class="mm_btn mb_10"
|
|
|
+ :class="{ active: activeBtn === pathThree }"
|
|
|
@click="toPage(pathThree)">个人画像</button>
|
|
|
</div>
|
|
|
|
|
|
<div class="right">
|
|
|
<div class="page_filter" ref="filterContent">
|
|
|
- <FiltersItem :filtersData="filteredFilterData" @selectItem="ChangeFilters"></FiltersItem>
|
|
|
- </div>
|
|
|
- <router-view ref="child" @isPdfDataLoadEnd="isPdfDataLoadEnd" @closePdfLoading="closePdfLoading"></router-view>
|
|
|
+ <FiltersItem :filtersData="filteredFilterData" @selectItem="ChangeFilters">
|
|
|
+ </FiltersItem>
|
|
|
+ </div>
|
|
|
+ <router-view ref="child" @isPdfDataLoadEnd="isPdfDataLoadEnd"
|
|
|
+ @closePdfLoading="closePdfLoading"></router-view>
|
|
|
</div>
|
|
|
</div>
|
|
|
</template>
|
|
|
@@ -53,7 +56,8 @@
|
|
|
<div class="page_filter" ref="filterContent">
|
|
|
<FiltersItem :filtersData="filteredFilterData" @selectItem="ChangeFilters"></FiltersItem>
|
|
|
</div>
|
|
|
- <router-view ref="child" @isPdfDataLoadEnd="isPdfDataLoadEnd" @closePdfLoading="closePdfLoading"></router-view>
|
|
|
+ <router-view ref="child" @isPdfDataLoadEnd="isPdfDataLoadEnd"
|
|
|
+ @closePdfLoading="closePdfLoading"></router-view>
|
|
|
</template>
|
|
|
</div>
|
|
|
</div>
|
|
|
@@ -94,8 +98,8 @@ export default {
|
|
|
return {
|
|
|
isShowFilter: false, //是否显示筛选条件
|
|
|
isShowBtn: false, //是否显示下载按钮
|
|
|
- isShowPadfBtn:false,//是否显示下载pdf按钮
|
|
|
- isPdfLoadEnd:false,//报告册数据是否加载完成
|
|
|
+ isShowPadfBtn: false,//是否显示下载pdf按钮
|
|
|
+ isPdfLoadEnd: false,//报告册数据是否加载完成
|
|
|
filterData: [
|
|
|
{
|
|
|
name: "科目名称",
|
|
|
@@ -110,12 +114,12 @@ export default {
|
|
|
pathTwo: '/studentAnalysisReport/reportDetails/personalWrongQuestions',
|
|
|
pathThree: '/studentAnalysisReport/reportDetails/personalProfile',//个人画像
|
|
|
isLianXiao: false,//是否联校
|
|
|
- stuPdfLoading:false,
|
|
|
+ stuPdfLoading: false,
|
|
|
};
|
|
|
},
|
|
|
|
|
|
created() {
|
|
|
- this.isShowPadfBtn = this.$route.path=='/studentAnalysisReport/reportDetails/scrolReport';
|
|
|
+ this.isShowPadfBtn = this.$route.path == '/studentAnalysisReport/reportDetails/scrolReport';
|
|
|
const schoolType = sessionStorage.getItem('schoolType') || '1'; //1:单校 2:联校
|
|
|
this.isLianXiao = schoolType === '2';
|
|
|
|
|
|
@@ -148,9 +152,9 @@ export default {
|
|
|
SetHeadWidth() {
|
|
|
if (this.$refs.contentRightScroll) {
|
|
|
let scrollDivWidth = 0;
|
|
|
- if(this.isLianXiao){
|
|
|
+ if (this.isLianXiao) {
|
|
|
scrollDivWidth = this.$refs.contentRightScroll.offsetWidth - 20;//联校
|
|
|
- }else{
|
|
|
+ } else {
|
|
|
scrollDivWidth = this.$refs.contentRightScroll.offsetWidth;
|
|
|
}
|
|
|
const headDiv = this.$refs.mainHeader;
|
|
|
@@ -160,7 +164,7 @@ export default {
|
|
|
|
|
|
// 筛选事件
|
|
|
ChangeFilters(e) {
|
|
|
-
|
|
|
+
|
|
|
this.filterData[e.index].value = e.value;
|
|
|
// 选中科目数据
|
|
|
let courseObj = this.filterData[0].list.find(item => item.value == this.filterData[0].value);
|
|
|
@@ -183,7 +187,7 @@ export default {
|
|
|
localStorage.setItem('reportExamCourseId', courseObj.subjectId);//单科的考试科目id
|
|
|
localStorage.setItem('reportIsTotalScore', isTotal)
|
|
|
this.$store.dispatch("report/UpdateFilterObject", filterObject);
|
|
|
-
|
|
|
+
|
|
|
// 如果选择了总分且当前在个人画像页面,跳转到成绩分析页面
|
|
|
if (isTotal && this.$route.path === '/studentAnalysisReport/reportDetails/personalProfile') {
|
|
|
this.toPage(this.pathOne);
|
|
|
@@ -234,27 +238,27 @@ export default {
|
|
|
//返回按钮点击
|
|
|
GoBack() {
|
|
|
const schoolType = sessionStorage.getItem('schoolType');
|
|
|
- if(schoolType == 1){//单校
|
|
|
+ if (schoolType == 1) {//单校
|
|
|
this.$router.push("/studentAnalysisReport/list");
|
|
|
- }else{//联校
|
|
|
+ } else {//联校
|
|
|
this.$router.push("/jointStudentAnalysisReport/list");
|
|
|
- }
|
|
|
-
|
|
|
+ }
|
|
|
+
|
|
|
},
|
|
|
StuDownloadPDF() {
|
|
|
- if(!this.isPdfLoadEnd){
|
|
|
+ if (!this.isPdfLoadEnd) {
|
|
|
return this.$message.warning('请稍等报告数据生成中!');
|
|
|
}
|
|
|
this.stuPdfLoading = true;
|
|
|
this.$refs.child.DownloadPdf();
|
|
|
},
|
|
|
- isPdfDataLoadEnd(){
|
|
|
+ isPdfDataLoadEnd() {
|
|
|
this.isPdfLoadEnd = true;
|
|
|
},
|
|
|
- closePdfLoading(){
|
|
|
+ closePdfLoading() {
|
|
|
this.stuPdfLoading = false;
|
|
|
},
|
|
|
-
|
|
|
+
|
|
|
// 处理筛选数据更新
|
|
|
handleFilterDataUpdate() {
|
|
|
// 不再在个人画像页面隐藏总分选项
|
|
|
@@ -271,7 +275,7 @@ export default {
|
|
|
this.ResetScroll();//重置滚动条
|
|
|
},
|
|
|
},
|
|
|
-
|
|
|
+
|
|
|
// 监听筛选数据变化,动态过滤总分选项
|
|
|
filterData: {
|
|
|
deep: true,
|