暂存
This commit is contained in:
@@ -44,19 +44,26 @@
|
||||
|
||||
</view>
|
||||
<view class="otherItems flex_box userScore">
|
||||
<view>
|
||||
<view v-if="classModel.isTask == 1">
|
||||
<text class="ciyao">作业得分</text>
|
||||
<text class="ciyao"><i class="mainTxt PM_font">{{performanceScore.task0Score}}</i>分</text>
|
||||
</view>
|
||||
<view><text class="ciyao">医案得分</text>
|
||||
<view v-if="classModel.isMedicalcase == 1">
|
||||
<text class="ciyao">医案得分</text>
|
||||
<text class="ciyao"><i class="mainTxt PM_font">{{performanceScore.task1Score}}</i>分</text>
|
||||
</view>
|
||||
<view><text class="ciyao">心得得分</text>
|
||||
<view v-if="classModel.isExperience == 1">
|
||||
<text class="ciyao">心得得分</text>
|
||||
<text class="ciyao"><i class="mainTxt PM_font">{{performanceScore.experienceScore}}</i>分</text>
|
||||
</view>
|
||||
<view><text class="ciyao">思考题分</text>
|
||||
<view v-if="classModel.isQuestion == 1">
|
||||
<text class="ciyao">思考题分</text>
|
||||
<text class="ciyao"><i class="mainTxt PM_font">{{performanceScore.questionScore}}</i>分</text>
|
||||
</view>
|
||||
</view>
|
||||
<!-- <view v-if="classModel.isExam == 1 && thisClass.state == '2'">
|
||||
<text class="ciyao">考试分</text>
|
||||
<text class="ciyao"><i class="mainTxt PM_font">{{performanceScore.questionScore}}</i>分</text>
|
||||
</view> -->
|
||||
</view>
|
||||
<!-- <view class="optionsBox" >
|
||||
<view class="flex_box flex_between">
|
||||
@@ -149,15 +156,16 @@
|
||||
<view class="" v-show="students.length == 0 && tabId == '2'">
|
||||
<u-divider text="暂无学员加入"></u-divider>
|
||||
</view>
|
||||
{{getTijiaoTitleList}}
|
||||
<!-- 班内提交 -->
|
||||
<view class="" v-if=" tabId == '3' && thisClass.state != '0'">
|
||||
<view class="" v-if="tabId == '3' && thisClass.state != '0'">
|
||||
<view class="flex_box tijiaoTitle">
|
||||
<text :class="tijiaoTitleId == item.id ? 'active' :''" @click="titleClick(item,index)"
|
||||
v-for="(item, index) in tijiaoTitleList" :key="index">{{item.name}}</text>
|
||||
</view>
|
||||
<!-- 班内任务 --><!-- 医案 --> <!-- 心得 -->
|
||||
<view class="">
|
||||
<view class="" v-if="tijiaoTitleId == 2 && thisClass.state == '1'">
|
||||
<view class="" v-if="tijiaoTitleId == 2 && thisClass.state == '1' && roleCode.includes('0')">
|
||||
<view class="noanser">
|
||||
<view class="">
|
||||
<text>快来添加一条记录吧~</text>
|
||||
@@ -207,12 +215,14 @@
|
||||
v-show="tijiaoTitleId == 2 && myExperience == 1 && item.scoreSuccess == 0"
|
||||
@click.stop="editMyXinde(item)">修改</text>
|
||||
</view>
|
||||
<template v-if="roleCode.includes('0')">
|
||||
<view class="leve3" v-show="item.reply && tijiaoTitleId != 2">
|
||||
<text>已提交答案</text>
|
||||
</view>
|
||||
<view class="leve3 no" v-show="!item.reply && tijiaoTitleId != 2">
|
||||
<text>未提交答案 点击开始答题</text>
|
||||
</view>
|
||||
</template>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -239,7 +249,7 @@
|
||||
<text class="adminName">班长:</text>
|
||||
<view class="personbox" v-if="admins.monitor.user != null">
|
||||
<text>{{admins.monitor.user.nickname != null && admins.monitor.user.nickname != '' ? admins.monitor.user.nickname : '匿名用户'}}</text>
|
||||
<text v-if="admins.monitor.id">({{admins.monitor.user.tel}})</text>
|
||||
<!-- <text v-if="admins.monitor.id">({{admins.monitor.user.tel}})</text> -->
|
||||
</view>
|
||||
<text v-else>暂未设置</text>
|
||||
</view>
|
||||
@@ -247,8 +257,8 @@
|
||||
<text class="adminName">副班长:</text>
|
||||
<view class="personbox" v-if="admins.dmonitor.user != null">
|
||||
<text>{{admins.dmonitor.user.nickname != null && admins.dmonitor.user.nickname != '' ? admins.dmonitor.user.nickname : '匿名用户'}}</text>
|
||||
-->
|
||||
<text>({{admins.dmonitor.user.tel}})</text>
|
||||
|
||||
<!-- <text>({{admins.dmonitor.user.tel}})</text> -->
|
||||
</view>
|
||||
<text v-else>暂未设置</text>
|
||||
</view>
|
||||
@@ -256,7 +266,7 @@
|
||||
|
||||
<view class="personbox" v-if="admins.learner.user != null">
|
||||
<text>{{admins.learner.user.nickname != null && admins.learner.user.nickname != '' ? admins.learner.user.nickname : '匿名用户'}}</text>
|
||||
<text>({{admins.learner.user.tel}})</text>
|
||||
<!-- <text>({{admins.learner.user.tel}})</text> -->
|
||||
</view>
|
||||
<text v-else>暂未设置</text>
|
||||
</view>
|
||||
@@ -275,8 +285,8 @@
|
||||
<template v-if="admins.scorer.length > 0">
|
||||
<view class="arryItemSub" v-for="(item,index) in admins.scorer" :key="index">
|
||||
<template v-if="item.user != null">
|
||||
<text>{{item.user.nickname != null && item.user.nickname != '' ? item.user.nickname : '匿名用户'}}</text>
|
||||
<text>({{item.user.tel}}),</text>
|
||||
<text>{{item.user.nickname != null && item.user.nickname != '' ? item.user.nickname+' ' : '匿名用户 '}}</text>
|
||||
<!-- <text>({{item.user.tel}}),</text> -->
|
||||
</template>
|
||||
</view>
|
||||
</template>
|
||||
@@ -326,7 +336,7 @@
|
||||
|
||||
thisClass: {},
|
||||
students: [],
|
||||
tabId: '3',
|
||||
tabId:'3',
|
||||
curTagIndex: 0,
|
||||
scrollable: false,
|
||||
pPage: 0,
|
||||
@@ -387,7 +397,8 @@
|
||||
isDirector: false, // 是主任
|
||||
isHave: false,
|
||||
showMan: false,
|
||||
tijiaoTitleList: [{
|
||||
tijiaoTitleList:[],
|
||||
defaultTijiaoTitleList: [{
|
||||
name: '班内作业',
|
||||
id: '0'
|
||||
},
|
||||
@@ -409,12 +420,14 @@
|
||||
experienceScore: 0,
|
||||
task0Score: 0,
|
||||
questionScore: 0
|
||||
}
|
||||
},
|
||||
roleCode:[]
|
||||
}
|
||||
},
|
||||
onLoad(e) {
|
||||
uni.hideTabBar();
|
||||
this.classId = e.id
|
||||
|
||||
this.getUserInfo()
|
||||
uni.$on('refreshData', () => {
|
||||
console.log('开始刷新列表数据');
|
||||
@@ -445,6 +458,15 @@
|
||||
onShow() {
|
||||
this.getClassInfo()
|
||||
this.getScore()
|
||||
// this.getTijiaoTitleList()
|
||||
if (this.thisClass.state != 0) {
|
||||
this.pPage = 0
|
||||
this.taskList = []
|
||||
this.getList()
|
||||
}
|
||||
// this.pPage = 0
|
||||
// this.taskList = []
|
||||
// this.getList()
|
||||
},
|
||||
computed: {
|
||||
...mapState(["userInfo"]),
|
||||
@@ -472,6 +494,23 @@
|
||||
}
|
||||
return list
|
||||
},
|
||||
// 获得提交项目的tab
|
||||
getTijiaoTitleList(){
|
||||
var _list = []
|
||||
if(this.classModel.isTask == 1){
|
||||
_list.push(this.defaultTijiaoTitleList[0])
|
||||
}
|
||||
if(this.classModel.isMedicalcase == 1){
|
||||
_list.push(this.defaultTijiaoTitleList[1])
|
||||
}
|
||||
if(this.classModel.isExperience == 1){
|
||||
_list.push(this.defaultTijiaoTitleList[2])
|
||||
}
|
||||
// return _list
|
||||
this.tijiaoTitleList = _list
|
||||
this.tijiaoTitleId = this.tijiaoTitleList[0].id
|
||||
// this.tabId =
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
|
||||
@@ -482,6 +521,32 @@
|
||||
|
||||
this.taskList[index].zhedie = !this.taskList[index].zhedie
|
||||
},
|
||||
// 获取用户身份
|
||||
getUserRole(){
|
||||
$http.request({
|
||||
url: "common/class/getUserRole",
|
||||
method: "POST",
|
||||
data: {
|
||||
"classId": this.classId
|
||||
},
|
||||
header: { //默认 无 说明:请求头
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
})
|
||||
.then((res) => {
|
||||
uni.hideLoading()
|
||||
console.log('res获取身份信息',res);
|
||||
this.roleCode = res.result
|
||||
}).catch(e => {
|
||||
uni.hideLoading()
|
||||
this.roleCode = []
|
||||
uni.showToast({
|
||||
title: '获取身份信息失败',
|
||||
icon: 'error'
|
||||
})
|
||||
});
|
||||
|
||||
},
|
||||
// 查询平时表现分
|
||||
getScore() {
|
||||
$http.request({
|
||||
@@ -648,8 +713,8 @@
|
||||
if (this.tijiaoTitleId == textIndex) {
|
||||
return
|
||||
}
|
||||
this.tijiaoTitleId = textIndex
|
||||
console.log('e班内提交子按钮');
|
||||
this.tijiaoTitleId = item.id
|
||||
console.log('e班内提交子按钮',this.tijiaoTitleId);
|
||||
this.pPage = 0
|
||||
this.taskList = []
|
||||
this.myExperience = 0
|
||||
@@ -840,14 +905,10 @@
|
||||
outClass(userId) {
|
||||
let that = this
|
||||
var _useId = undefined
|
||||
var _txt = ''
|
||||
// if (userId) {
|
||||
// _useId = userId
|
||||
// _txt = '即将踢出该学员,是否继续?'
|
||||
// } else {
|
||||
var _txt = ''
|
||||
_useId = this.userInfo.id
|
||||
_txt = '您即将退出当前班级,退出班级后,在本班级提交的作业、医案、心得都将被删除,是否继续?'
|
||||
// }
|
||||
|
||||
|
||||
uni.showModal({
|
||||
title: '提示',
|
||||
@@ -897,7 +958,7 @@
|
||||
clickHelp() {
|
||||
uni.showModal({
|
||||
title: '说明',
|
||||
content: "表现分占最终总成绩的40%,由作业,医案,心得,思考题四部分构成,每部分各占四分之一,且每部分最高为10分,总计40分。",
|
||||
content: `表现分由${this.classModel.isTask == 1 ? '作业('+this.classModel.taskScore+'%),' : ''}${this.classModel.isMedicalcase == 1 ? '医案('+this.classModel.medicalcaseScore+'%),' : ''}${this.classModel.isExperience == 1 ? '心得('+this.classModel.experienceScore+'%),' : ''} ${this.classModel.isQuestion == 1 ? '思考题('+this.classModel.questionScore+'%)' : ''}构成。`,
|
||||
showCancel: false,
|
||||
confirmText: '好的'
|
||||
})
|
||||
@@ -907,7 +968,7 @@
|
||||
url: `/pages/miniClass/classCaskList?id=${this.thisClass.id}&type=${this.tijiaoTitleId}`
|
||||
})
|
||||
},
|
||||
getClassInfo() {
|
||||
getClassInfo() {
|
||||
uni.showLoading({
|
||||
title: '正在加载'
|
||||
})
|
||||
@@ -964,9 +1025,7 @@
|
||||
this.courses = res.result.courses
|
||||
this.students = res.result.students
|
||||
this.refresh = true
|
||||
if (this.thisClass.state != 0) {
|
||||
this.getList()
|
||||
}
|
||||
|
||||
}
|
||||
uni.hideLoading()
|
||||
}).catch(e => {
|
||||
@@ -1452,7 +1511,7 @@
|
||||
}
|
||||
|
||||
.tijiaoTitle {
|
||||
justify-content: space-between;
|
||||
justify-content:space-around;
|
||||
margin-bottom: 20rpx;
|
||||
|
||||
text {
|
||||
|
||||
Reference in New Issue
Block a user