examTeamApp/pages/score/report.vue

178 lines
3.4 KiB
Vue
Raw Normal View History

2024-05-29 16:35:45 +08:00
<template>
<view class="content">
<!-- 估分 -->
<view class="box">
<view class="title bold">本次估分成绩为</view>
<view class="charts">
2024-06-13 18:03:50 +08:00
<qiun-data-charts type="arcbar" :chartData="chartData" />
2024-05-29 16:35:45 +08:00
</view>
2024-06-13 18:03:50 +08:00
<view class="name">{{score}}</view>
<view class="time text_c">{{create_time}}</view>
2024-05-29 16:35:45 +08:00
</view>
<!-- -->
2024-06-13 18:03:50 +08:00
<view v-for="(item,index) in selectllist">
<view class="titleName bold mt-15 ml-15 size18">{{item.name}}</view>
<view class="indexCarList">
<view class="card" v-for="(ite,ind) in item.list">
<view class="title">
<view class="name">{{ite.name}}</view>
2024-05-29 16:35:45 +08:00
</view>
2024-07-22 14:13:19 +08:00
<view class="item3" v-for="(it,id) in ite.list" v-if="ite.list.length>1">
2024-06-13 18:03:50 +08:00
<view class="name">{{it.name}}</view>
<view class="weight">
2024-07-22 14:13:19 +08:00
<view class="input">{{it.value?it.value:'-'}}</view>
<view class="cblue bold">{{it.score?it.score:'-'}}</view>
<view class="cblue bold">{{it.proportion_value?it.proportion_value:'-'}}</view>
2024-05-29 16:35:45 +08:00
</view>
</view>
2024-06-13 18:03:50 +08:00
2024-05-29 16:35:45 +08:00
</view>
</view>
</view>
</view>
</template>
<script>
import qiunDataCharts from '@/uni_modules/qiun-data-charts/components/qiun-data-charts/qiun-data-charts.vue';
export default {
data() {
return {
chartData: {
series: [{
name: "正确率",
color: "#4687F9",
2024-06-13 18:03:50 +08:00
data: 0
2024-05-29 16:35:45 +08:00
}]
},
2024-06-13 18:03:50 +08:00
score: 0,
create_time: "",
selectllist: []
2024-05-29 16:35:45 +08:00
}
},
components: {
qiunDataCharts
},
2024-06-13 18:03:50 +08:00
onLoad(options) {
let that = this
that.getList(options.id)
2024-05-29 16:35:45 +08:00
},
methods: {
2024-06-13 18:03:50 +08:00
getList(id) {
let that = this
that.$model.getSportshistorydetail({
id: Number(id),
}).then((res) => {
console.log("历史记录详情", res)
if (res.code != 0) return
that.selectllist = res.data.list
2024-07-22 14:13:19 +08:00
that.score = Number(res.data.score)
2024-06-13 18:03:50 +08:00
that.create_time = res.data.create_time
2024-07-22 14:13:19 +08:00
that.chartData.series[0].data = Number(res.data.score) / 50
2024-05-29 16:35:45 +08:00
})
},
2024-06-13 18:03:50 +08:00
2024-05-29 16:35:45 +08:00
}
}
</script>
<style scoped lang="scss">
.content {
min-height: 100vh;
2024-06-13 18:03:50 +08:00
padding-top: 15px;
2024-05-29 16:35:45 +08:00
padding-bottom: 15px;
background-color: #f7f7f7;
}
.box {
2024-06-13 18:03:50 +08:00
margin: 15px 10px 0;
2024-05-29 16:35:45 +08:00
padding: 15px 10px 10px;
background-color: #fff;
width: calc(100% - 40px);
display: flex;
flex-wrap: wrap;
justify-content: center;
align-items: center;
border-radius: 10px;
position: relative;
2024-06-13 18:03:50 +08:00
.name {
position: absolute;
top: 42%;
margin: auto;
font-size: 35px;
color: #4687F9;
}
2024-05-29 16:35:45 +08:00
}
2024-06-13 18:03:50 +08:00
.indexCarList {
width: calc(100% - 40px);
margin: 10px;
padding: 5px 10px;
background-color: #fff;
2024-05-29 16:35:45 +08:00
border-radius: 10px;
2024-06-13 18:03:50 +08:00
.title {
color: #000;
background-color: #f5f5f5 !important;
border-bottom: 1px solid #d9d9d9;
padding-left: 10px;
border-radius: 5px;
height: 35px;
display: flex;
align-items: center;
width: calc(100% - 10px);
2024-05-29 16:35:45 +08:00
2024-06-13 18:03:50 +08:00
.name {
font-weight: bold;
margin-top: 3px;
}
.right {
width: 30%;
color: $textcolor;
font-size: 12px;
text-align: right;
margin-top: 5px;
margin-right: 10px;
}
}
.item3 {
display: flex;
background: #fff;
padding: 0 10px;
height: 50px;
border-bottom: 1px solid #f7f7f7;
.name {
width: 35%;
line-height: 50px;
}
.weight {
width: 65%;
display: flex;
align-items: center;
position: relative;
justify-content: space-between;
2024-07-22 14:13:19 +08:00
view {
width: 30%;
text-align: center;
}
.input {
width: 40%;
}
2024-06-13 18:03:50 +08:00
}
2024-05-29 16:35:45 +08:00
}
}
.charts {
width: 100%;
2024-06-13 18:03:50 +08:00
height: 130px;
margin: 10px 0;
2024-05-29 16:35:45 +08:00
}
</style>