|
@@ -1,5 +1,5 @@
|
|
|
<template>
|
|
|
- <div :class="{'content-container': fromFlag === 0}">
|
|
|
+ <div :class="{ 'content-container': fromFlag === 0 }">
|
|
|
<div class="content-outline result-card-outline">
|
|
|
<div class="content-inner">
|
|
|
<el-image
|
|
@@ -8,39 +8,68 @@
|
|
|
fit="fill"
|
|
|
/>
|
|
|
<div class="btn-area flex-row">
|
|
|
- <el-button v-if="flag !== 'PSY_CAPITAL'" type="primary" plain round @click="downloadFile">
|
|
|
+ <el-button
|
|
|
+ v-if="flag && flag !== 'PSY_CAPITAL'"
|
|
|
+ type="primary"
|
|
|
+ plain
|
|
|
+ round
|
|
|
+ @click="downloadFile"
|
|
|
+ >
|
|
|
点击下载
|
|
|
</el-button>
|
|
|
<!-- <el-button v-if="type == 0 && isGroup" type="primary" round @click="downloadReport">下载报告</el-button> -->
|
|
|
- <el-button type="primary" plain round @click="goToHistory">测试历史记录</el-button>
|
|
|
+ <el-button type="primary" plain round @click="goToHistory"
|
|
|
+ >测试历史记录</el-button
|
|
|
+ >
|
|
|
</div>
|
|
|
|
|
|
<div class="result-area">
|
|
|
- <result-title v-if="data.userRecordEntity && data.userRecordEntity.phone" class="result-div" text="测试得分" />
|
|
|
- <div v-if="data.userRecordEntity && data.userRecordEntity.phone" class="test-top-left">
|
|
|
+ <result-title
|
|
|
+ v-if="data.userRecordEntity && data.userRecordEntity.phone"
|
|
|
+ class="result-div"
|
|
|
+ text="测试得分"
|
|
|
+ />
|
|
|
+ <div
|
|
|
+ v-if="data.userRecordEntity && data.userRecordEntity.phone"
|
|
|
+ class="test-top-left"
|
|
|
+ >
|
|
|
<div>
|
|
|
测试者:
|
|
|
<span>{{ petName }}</span>
|
|
|
<span class="time">{{ data.userRecordEntity.testDate }}</span>
|
|
|
</div>
|
|
|
<div class="lang-to">
|
|
|
- {{ parseInt(type) === 0 ? "量表名称:" : parseInt(type) === 1 ? "任务名称:" : "" }}
|
|
|
+ <span v-if="type">{{
|
|
|
+ parseInt(type) === 0
|
|
|
+ ? "量表名称:"
|
|
|
+ : parseInt(type) === 1
|
|
|
+ ? "任务名称:"
|
|
|
+ : ""
|
|
|
+ }}</span>
|
|
|
+
|
|
|
<span>{{ data.userRecordEntity.name }}</span>
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="report-tip">
|
|
|
- 报告阅读说明<br>
|
|
|
- 谢谢您的参与,阅读本报告时,请注意以下内容:<br>
|
|
|
- 本结果仅供参考,不可作为临床诊断的依据;<br>
|
|
|
- 如对报告有不理解的地方,建议向专业资质人员进行咨询。<br>
|
|
|
- 如结果与你自己或他人感知的有出入,可回忆在测试时是否有事情影响了你,或自己答题时是否有所顾虑;<br>
|
|
|
+ 报告阅读说明<br />
|
|
|
+ 谢谢您的参与,阅读本报告时,请注意以下内容:<br />
|
|
|
+ 本结果仅供参考,不可作为临床诊断的依据;<br />
|
|
|
+ 如对报告有不理解的地方,建议向专业资质人员进行咨询。<br />
|
|
|
+ 如结果与你自己或他人感知的有出入,可回忆在测试时是否有事情影响了你,或自己答题时是否有所顾虑;<br />
|
|
|
</div>
|
|
|
|
|
|
- <result-title class="result-div" text="分值"/>
|
|
|
- <div class="test-top-left" v-if="allData.ifShow && allData.ifShow.totalScore">
|
|
|
+ <result-title class="result-div" text="分值" />
|
|
|
+ <div
|
|
|
+ class="test-top-left"
|
|
|
+ v-if="allData.ifShow && allData.ifShow.totalScore"
|
|
|
+ >
|
|
|
<div class="total-score">
|
|
|
<span>总分:</span>
|
|
|
- <span class="lang-to fen">{{ allData.totalScore[0].totalScore }}</span>
|
|
|
+ <span class="lang-to fen">{{
|
|
|
+ allData.totalScore[0].totalScore && allData.totalScore[0].totalScore.indexOf("%") !== -1
|
|
|
+ ? allData.totalScore[0].totalScore.replace("%", "")
|
|
|
+ : allData.totalScore[0].totalScore
|
|
|
+ }}</span>
|
|
|
<span>分</span>
|
|
|
</div>
|
|
|
<div class="score-des">
|
|
@@ -48,20 +77,38 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <div class="score-warp" v-if="allData.ifShow.radar || allData.ifShow.table">
|
|
|
+ <div
|
|
|
+ class="score-warp"
|
|
|
+ v-if="allData.ifShow.radar || allData.ifShow.table"
|
|
|
+ >
|
|
|
<!--雷达图-->
|
|
|
- <div class="radar-warp" v-if="allData.ifShow.radar && allData.chartModule.chartType == 'radar'">
|
|
|
+ <div
|
|
|
+ class="radar-warp"
|
|
|
+ v-if="
|
|
|
+ allData.ifShow.radar && allData.chartModule.chartType == 'radar'
|
|
|
+ "
|
|
|
+ >
|
|
|
<radarChart :data="allData.chartModule.chartBody"></radarChart>
|
|
|
</div>
|
|
|
<!--折线图-->
|
|
|
- <div class="line-warp" v-if="allData.ifShow.radar && allData.chartModule.chartType == 'line'">
|
|
|
+ <div
|
|
|
+ class="line-warp"
|
|
|
+ v-if="
|
|
|
+ allData.ifShow.radar && allData.chartModule.chartType == 'line'
|
|
|
+ "
|
|
|
+ >
|
|
|
<lineChart :data="allData.chartModule.chartBody"></lineChart>
|
|
|
</div>
|
|
|
|
|
|
- <div class="table-list" v-if="allData.ifShow && allData.ifShow.table">
|
|
|
+ <div
|
|
|
+ class="table-list"
|
|
|
+ v-if="allData.ifShow && allData.ifShow.table"
|
|
|
+ >
|
|
|
<table v-for="(item, index) in tableData" :key="index">
|
|
|
<tr class="table-th">
|
|
|
- <th v-for="(items, i) in item.columnName" :key="i">{{ items }}</th>
|
|
|
+ <th v-for="(items, i) in item.columnName" :key="i">
|
|
|
+ {{ items }}
|
|
|
+ </th>
|
|
|
</tr>
|
|
|
<tr v-for="(list, j) in item.columnValue[0]" :key="j">
|
|
|
<td
|
|
@@ -76,9 +123,18 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <result-title v-if="allData.ifShow && allData.ifShow.dimensions" class="result-div" text="得分解读"/>
|
|
|
+ <result-title
|
|
|
+ v-if="allData.ifShow && allData.ifShow.dimensions"
|
|
|
+ class="result-div"
|
|
|
+ text="得分解读"
|
|
|
+ />
|
|
|
<template v-if="allData.ifShow && allData.ifShow.dimensions">
|
|
|
- <div v-for="(item,index) in allData.dimensions" :key="index" class="char-outline" :class="{ 'last-item': index === allData.dimensions.length - 1 }">
|
|
|
+ <div
|
|
|
+ v-for="(item, index) in allData.dimensions"
|
|
|
+ :key="index"
|
|
|
+ class="char-outline"
|
|
|
+ :class="{ 'last-item': index === allData.dimensions.length - 1 }"
|
|
|
+ >
|
|
|
<scoreInterpretation-item :data="item" :order="index" />
|
|
|
</div>
|
|
|
</template>
|
|
@@ -98,8 +154,8 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import ResultTitle from "@/components/ResultTitle/index.vue"
|
|
|
-import GoBack from "@/components/goBack/index.vue"
|
|
|
+import ResultTitle from "@/components/ResultTitle/index.vue";
|
|
|
+import GoBack from "@/components/goBack/index.vue";
|
|
|
|
|
|
export default {
|
|
|
name: "cognitiveTaskReport",
|
|
@@ -107,8 +163,8 @@ export default {
|
|
|
props: {
|
|
|
fromFlag: {
|
|
|
type: Number,
|
|
|
- default: 0
|
|
|
- }
|
|
|
+ default: 0,
|
|
|
+ },
|
|
|
// allData: {
|
|
|
// type: Object,
|
|
|
// default: function () {
|
|
@@ -130,7 +186,7 @@ export default {
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
- id: '', //测试记录id
|
|
|
+ id: "", //测试记录id
|
|
|
data: {}, //测试结果返回总数据
|
|
|
allData: {}, //测试显示内容
|
|
|
// groupOne: [],
|
|
@@ -139,28 +195,27 @@ export default {
|
|
|
// groupAll: [],
|
|
|
// groupLength: 0,
|
|
|
tableData: [], //表格数据
|
|
|
- petName: ''
|
|
|
- }
|
|
|
+ petName: "",
|
|
|
+ };
|
|
|
},
|
|
|
created() {
|
|
|
- this.id = this.$route.query.id
|
|
|
+ this.id = this.$route.query.id;
|
|
|
//获取测试结果存储值
|
|
|
- this.data = JSON.parse(sessionStorage.getItem('testResult'))
|
|
|
- this.allData = JSON.parse(this.data?.userRecordEntity?.testResult)
|
|
|
+ this.data = JSON.parse(sessionStorage.getItem("testResult"));
|
|
|
+ this.allData = JSON.parse(this.data?.userRecordEntity?.testResult);
|
|
|
// console.log(this.data,"获取新结果值")
|
|
|
- // console.log(this.allData,"获取新结果值列表数据")
|
|
|
+ console.log(this.allData,"获取新结果值列表数据")
|
|
|
},
|
|
|
mounted() {
|
|
|
// if(this.allData?.dimensions) {
|
|
|
// this.dataHandle(this.allData?.dimensions);
|
|
|
// }
|
|
|
- this.petName = sessionStorage.getItem('435e0648d634175c46bd40ac366545a8')
|
|
|
+ this.petName = sessionStorage.getItem("435e0648d634175c46bd40ac366545a8");
|
|
|
if (this.allData.ifShow.table && this.allData?.tableModule) {
|
|
|
//表格数据赋值处理
|
|
|
- this.tableData = this.allData.tableModule
|
|
|
- this.tableDataHandle()
|
|
|
+ this.tableData = this.allData.tableModule;
|
|
|
+ this.tableDataHandle();
|
|
|
}
|
|
|
-
|
|
|
},
|
|
|
computed: {},
|
|
|
watch: {},
|
|
@@ -196,32 +251,34 @@ export default {
|
|
|
// },
|
|
|
tableDataHandle() {
|
|
|
//表格数据处理
|
|
|
- this.tableData.forEach(item => {
|
|
|
+ this.tableData.forEach((item) => {
|
|
|
item.columnValue.forEach((items, index, arr) => {
|
|
|
- item.columnValue[index] = items.split(';')
|
|
|
- })
|
|
|
- })
|
|
|
+ item.columnValue[index] = items.split(";");
|
|
|
+ });
|
|
|
+ });
|
|
|
},
|
|
|
|
|
|
goToHistory() {
|
|
|
- if(this.$route.path === '/ContainerSys/CognitiveTaskUserDetailNew') {
|
|
|
- this.goBack()
|
|
|
+ if (this.$route.path === "/ContainerSys/CognitiveTaskUserDetailNew") {
|
|
|
+ this.goBack();
|
|
|
} else {
|
|
|
this.$router.push({
|
|
|
- path: "/welcome/PersonalCenter"
|
|
|
- })
|
|
|
+ path: "/welcome/PersonalCenter",
|
|
|
+ });
|
|
|
}
|
|
|
},
|
|
|
|
|
|
downloadFile() {
|
|
|
if (this.title === "画钟测试") {
|
|
|
- window.open(`${ baseUrl }result/download/CDTImg?id=${ this.id }`, "_blank")
|
|
|
+ window.open(`${baseUrl}result/download/CDTImg?id=${this.id}`, "_blank");
|
|
|
}
|
|
|
- window.open(`${ baseUrl }result/download/testResult?id=${ this.id }`, "_blank")
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
-}
|
|
|
+ window.open(
|
|
|
+ `${baseUrl}result/download/testResult?id=${this.id}`,
|
|
|
+ "_blank"
|
|
|
+ );
|
|
|
+ },
|
|
|
+ },
|
|
|
+};
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
@@ -278,7 +335,7 @@ export default {
|
|
|
|
|
|
.lang-to {
|
|
|
margin-top: 4px;
|
|
|
- color: #26B600;
|
|
|
+ color: #26b600;
|
|
|
}
|
|
|
|
|
|
.total-score {
|
|
@@ -302,7 +359,7 @@ export default {
|
|
|
padding: 12px 18px;
|
|
|
border-radius: 12px;
|
|
|
color: #666666;
|
|
|
- background-color: #F0F3F8;
|
|
|
+ background-color: #f0f3f8;
|
|
|
font-size: 0.083rem;
|
|
|
line-height: 0.108rem;
|
|
|
margin: 10px 35px 10px 43px;
|
|
@@ -324,7 +381,7 @@ export default {
|
|
|
height: 36px;
|
|
|
|
|
|
th {
|
|
|
- background-color: #26B600;
|
|
|
+ background-color: #26b600;
|
|
|
color: white;
|
|
|
line-height: 39px;
|
|
|
font-size: 0.086rem;
|
|
@@ -339,7 +396,7 @@ export default {
|
|
|
font-size: 0.086rem;
|
|
|
text-align: center;
|
|
|
line-height: 35px;
|
|
|
- background-color: #F0F3F8;
|
|
|
+ background-color: #f0f3f8;
|
|
|
width: 50%;
|
|
|
border-right: 1px solid white;
|
|
|
border-bottom: 1px solid white;
|
|
@@ -358,9 +415,9 @@ export default {
|
|
|
line-height: 27px;
|
|
|
font-size: 0.086rem;
|
|
|
font-family: PingFang SC-Regular, PingFang SC;
|
|
|
- color: #FFFFFF;
|
|
|
+ color: #ffffff;
|
|
|
text-align: left;
|
|
|
- background: #FFCD5A;
|
|
|
+ background: #ffcd5a;
|
|
|
border-radius: 0 10px 0 10px;
|
|
|
padding: 0 10px;
|
|
|
|
|
@@ -390,14 +447,14 @@ export default {
|
|
|
.dimension-item-title {
|
|
|
width: 80px;
|
|
|
height: 25px;
|
|
|
- color: #26B600;
|
|
|
+ color: #26b600;
|
|
|
text-align: justify;
|
|
|
text-justify: distribute-all-lines;
|
|
|
}
|
|
|
|
|
|
.dimension-item-mh {
|
|
|
width: 30px;
|
|
|
- color: #26B600;
|
|
|
+ color: #26b600;
|
|
|
font-weight: bold;
|
|
|
}
|
|
|
|
|
@@ -411,7 +468,7 @@ export default {
|
|
|
.dimension-item-title::after {
|
|
|
width: 100%;
|
|
|
display: inline-block;
|
|
|
- content: '';
|
|
|
+ content: "";
|
|
|
/*这三个都不可以少*/
|
|
|
}
|
|
|
|
|
@@ -442,8 +499,9 @@ export default {
|
|
|
font-size: 30px;
|
|
|
font-family: PingFang SC;
|
|
|
font-weight: 500;
|
|
|
- color: #FFFFFF;
|
|
|
- background: url("../../assets/congnitiveAblitity/taskReport_bg.png") no-repeat center;
|
|
|
+ color: #ffffff;
|
|
|
+ background: url("../../assets/congnitiveAblitity/taskReport_bg.png") no-repeat
|
|
|
+ center;
|
|
|
background-size: cover;
|
|
|
}
|
|
|
|
|
@@ -456,23 +514,23 @@ export default {
|
|
|
.report-user {
|
|
|
width: 100%;
|
|
|
height: 50px;
|
|
|
- border-left: 3px solid #247E8D;
|
|
|
+ border-left: 3px solid #247e8d;
|
|
|
box-sizing: border-box;
|
|
|
padding-left: 5px;
|
|
|
- color: #247E8D;
|
|
|
+ color: #247e8d;
|
|
|
}
|
|
|
|
|
|
.report-name {
|
|
|
font-size: 20px;
|
|
|
font-family: PingFang SC;
|
|
|
font-weight: 500;
|
|
|
- color: #247E8D;
|
|
|
+ color: #247e8d;
|
|
|
}
|
|
|
|
|
|
.report-time {
|
|
|
font-size: 16px;
|
|
|
font-family: PingFang SC;
|
|
|
- color: #247E8D;
|
|
|
+ color: #247e8d;
|
|
|
}
|
|
|
|
|
|
.report-tip {
|
|
@@ -517,7 +575,7 @@ export default {
|
|
|
.report-total-score-warp {
|
|
|
width: 100%;
|
|
|
/*height: 160px;*/
|
|
|
- background: #F1F9FA;
|
|
|
+ background: #f1f9fa;
|
|
|
box-sizing: border-box;
|
|
|
padding: 20px;
|
|
|
margin: 30px 0;
|
|
@@ -532,7 +590,8 @@ export default {
|
|
|
width: 100%;
|
|
|
}
|
|
|
|
|
|
-.score-title, .note-title {
|
|
|
+.score-title,
|
|
|
+.note-title {
|
|
|
width: 200px;
|
|
|
height: 40px;
|
|
|
font-size: 20px;
|
|
@@ -544,16 +603,19 @@ export default {
|
|
|
}
|
|
|
|
|
|
.score-title {
|
|
|
- background: url("../../assets/congnitiveAblitity/pinggu_icon.png") no-repeat center;
|
|
|
+ background: url("../../assets/congnitiveAblitity/pinggu_icon.png") no-repeat
|
|
|
+ center;
|
|
|
background-size: 100% 100%;
|
|
|
}
|
|
|
|
|
|
.note-title {
|
|
|
- background: url("../../assets/congnitiveAblitity/jianyi_icon.png") no-repeat center;
|
|
|
+ background: url("../../assets/congnitiveAblitity/jianyi_icon.png") no-repeat
|
|
|
+ center;
|
|
|
background-size: 100% 100%;
|
|
|
}
|
|
|
|
|
|
-.radar-warp, .line-warp {
|
|
|
+.radar-warp,
|
|
|
+.line-warp {
|
|
|
width: 100%;
|
|
|
box-sizing: border-box;
|
|
|
padding: 20px 85px 0;
|
|
@@ -573,7 +635,7 @@ export default {
|
|
|
|
|
|
.table-warp .score-table {
|
|
|
width: 100%;
|
|
|
- background: #F4F4F4;
|
|
|
+ background: #f4f4f4;
|
|
|
font-size: 16px;
|
|
|
}
|
|
|
|
|
@@ -582,13 +644,14 @@ export default {
|
|
|
line-height: 48px;
|
|
|
}
|
|
|
|
|
|
-.score-table th, .score-table td {
|
|
|
+.score-table th,
|
|
|
+.score-table td {
|
|
|
text-align: center;
|
|
|
width: 50%;
|
|
|
}
|
|
|
|
|
|
.score-table th {
|
|
|
- background: #9DD9E3;
|
|
|
+ background: #9dd9e3;
|
|
|
}
|
|
|
|
|
|
.score-table {
|
|
@@ -609,7 +672,7 @@ export default {
|
|
|
font-family: PingFang SC;
|
|
|
font-weight: 500;
|
|
|
color: #262626;
|
|
|
- border-top: 8px solid #5CB9C9;
|
|
|
+ border-top: 8px solid #5cb9c9;
|
|
|
/*box-sizing: border-box;*/
|
|
|
margin: 30px 0 0;
|
|
|
}
|
|
@@ -633,5 +696,4 @@ export default {
|
|
|
margin: 20px 0 0 78px;
|
|
|
text-indent: 2em;
|
|
|
}
|
|
|
-
|
|
|
</style>
|