合并前

This commit is contained in:
@fawn-nine
2024-09-09 11:18:06 +08:00
parent ac4f5dcd66
commit 195ba83a10
5 changed files with 1010 additions and 471 deletions

View File

@@ -0,0 +1,299 @@
<template>
<view class="">
<view class="" >
<view class="classMateBox" v-show="students.length> 0 ">
<view class="" style=" overflow: hidden;">
<uni-section class="mb-10 nobg xueyuanTitle" title="班内学员" type="line" sub-title="">
{{students.length}} 名学员</uni-section>
</view>
<view class=" tips">
<view v-if="thisClass.state == '2'" class=" zhiliang flex_box flex_between align-items_box" style="margin-top: 20rpx;">
<view class="">
<text>A证</text>
<text>20 </text>
</view>
<view class="">
<text>B证</text>
<text>20 </text>
</view>
<view class="">
<text>不合格</text>
<text>20 </text>
</view>
</view>
</view>
<!-- item.student.vip == '1' ? 'superVip' : '',
item.student.vip == '2' ? 'wumenVip' : '',
item.student.vip == '3' ? 'zmVip' : '', -->
<view class="newBox">
<view :class="['item']" v-for="(item, index) in students" :key="index" @click="clickStudent(item)">
<!-- <view class="imgcontainer" :style="{backgroundImage:surl(item.image)}"> -->
<view class="flex_box align-items_box">
<view class="classmateImg">
<image v-if="item.user.avatar != null && item.user.avatar != ''"
:src="item.user.avatar" mode="aspectFit"></image>
<image v-else src="/static/icon/morenAvavter.png" mode="aspectFit"></image>
</view>
<view :class="['textItems','flex_box']">
<text class="txt555"
v-if="item.user.nickname != null && item.user.nickname != ''">
{{item.user.nickname}}
<template>
<text>{{item.user.tel}}</text>
</template>
</text>
<text class="txt555" v-else>
匿名用户
</text>
<!-- <text @click.stop="outClass(item.student.id)" class="outBtn"
v-if="thisClass.state != '2' && thisClass.state != '3'">踢出班级</text> -->
<!-- <text class="userType" v-if="item.student.vip == '1'">超级VIP用户</text>
<text class="userType" v-if="item.student.vip == '2' ">医学VIP用户</text>
<text class="userType" v-if="item.student.vip == '3' ">国学VIP用户</text> -->
</view>
</view>
<view class="" v-if="thisClass.state == '3' || thisClass.state == '2'">
<view class="scoreBox flex_box flex_between border_radius_10 ">
<view class="">
<view class="ciyao">
平时成绩
</view>
<text class="score">{{item.pingshiScore}}</text>
</view>
<template v-if="classModel.isExam == 1">
<template v-if="item.classExamUsers.length == 0">
<view class="">
<view class="" style="color: #ff9496;">
未考试
</view>
</view>
<!-- <view class="" v-if="thisClass.state == '2'">
<view class="ciyao">
考试成绩
</view>
<text class="score">0</text>
</view> -->
</template>
<template v-else >
<!-- <view class="" v-if="thisClass.state == '3'">
<view class="" style="color: #55aa7f;">
等待公布分数
</view>
</view> -->
<view >
<view class="ciyao">
考试成绩
</view>
<text class="score">{{item.examScore}}</text>
</view>
</template>
</template>
<!-- -->
<!-- <view v-if="classModel.isExam == 1 && thisClass.state == '2'" :class="['PM_font','zhengshu',item.student.score.certificateType == 'A' ? 'Azheng' : 'Bzheng']"
></view> -->
</view>
</view>
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
props:['students','tabId','thisClass','classModel'],
data(){
return{
}
},
methods:{
clickStudent(item) {
// console.log('item', item);
this.$emit('chooseStudent',item)
// this.thisStudent = item
// this.showStudentBlank = true
},
}
}
</script>
<style lang="scss" scoped>
@import "@/style/mixin.scss";
::v-deep .xueyuanTitle {
.uni-section-header {
float: left;
}
.uni-section-content {
float: right;
margin-top: 20rpx;
font-size: 26rpx;
}
}
.scoreBox{
align-items: center; border: 1px solid #f1f1f1;
margin-top: 20rpx;
text-align: center; background-color: #fff; padding: 10rpx 20rpx;
.ciyao{color: #999; font-size: 28rpx;}
.score{color: #258feb; font-weight: bold; font-size: 36rpx;}
.seePaper{width: 50rpx; height: 50rpx;
image{width: 100%; height: 100%;}
}
}
.newBox {
.item {
margin-bottom: 20rpx;
background-color: #fff;
border-radius: 20rpx;
@include ptop_bottm(10px);
@include pleft_right(10px);
// @include mshadow(10px, 1)
.imgcontainer {
display: block;
width: 80rpx;
margin-right: 20rpx;
// background-size: cover;
// background-position: center;
height: 120rpx;
flex-grow: 1;
// @include ptop_bottm(10px);
overflow: hidden;
// @include pleft_right(10px);
image {
width: 100%;
height: 120rpx;
}
}
.btn_box {
text-align: right;
text {
border-radius: 20rpx;
padding: 3px 5px;
@include theme("btn_bg");
font-size: 28rpx;
color: #fff;
}
}
.buyItems {
width: 60%;
}
.jianjie {
line-height: 30rpx;
height: 60rpx;
overflow: hidden;
overflow: hidden !important;
margin-top: 10rpx;
font-size: 24rpx;
@include bov();
color: #9c9c9c;
}
.txt555 {
font-size: 30rpx;
color: #000;
@include bov()
}
}
}
.zhengshu{width: 80rpx; height: 80rpx; background-size: contain;}
.Azheng{background-image: url(@/static/icon/Az.png);}
.Bzheng{background-image: url(@/static/icon/Bz.png);}
.classMateBox {
.zmVip {
background-image: linear-gradient(-30deg, #7fd59c 0%, #e1feef 50%, #e1feef 100%);
.outBtn {
color: #fff !important;
border: 1px solid #fff !important;
}
}
.wumenVip {
background-image: linear-gradient(-30deg, #71aaf0 0%, #f1f4fd 50%, #f1f4fd 100%);
.outBtn {
color: #fff !important;
border: 1px solid #fff !important;
}
}
.superVip {
background-image: linear-gradient(-30deg, #a576c7 0%, #fdf0ed 30%, #fdf0ed 100%);
.outBtn {
color: #fff !important;
border: 1px solid #fff !important;
}
}
.newBox {
flex-wrap: wrap;
.item {
border: 1px solid #fff;
padding: 10rpx;
}
}
.item {
width: 100%;
position: relative;
.textItems {
width: 100%;
align-items: center;
justify-content: space-between;
.outBtn {
padding: 6rpx 10rpx;
display: inline-block;
border-radius: 10rpx;
color: $themeColor;
border: 1px solid $themeColor;
font-size: 26rpx;
margin-left: 10rpx;
}
.txt555 {
font-size: 28rpx;
color: #333;
}
.userType {
position: absolute;
font-size: 26rpx;
right: 30rpx;
top: 8rpx;
color: #fff;
}
}
}
.item.cur {
border: 1px solid #55aa00;
}
}
.classmateImg {
width: 60rpx;
margin-right: 20rpx;
height: 60rpx;
border-radius: 100rpx;
image {
width: 60rpx;
height: 60rpx;
}
}
</style>