Commit fd1868b1 authored by 黄奎's avatar 黄奎

页面修改

parent b04d6680
......@@ -12,7 +12,7 @@
<view>{{item.StuName}}</view>
<view class="flex">
<text>{{item.ShowTypeStr}}</text>
<van-image @click="editRules" class="img" width="31rpx" height="30rpx" fit="cover" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653980151000_180.png" />
<van-image @click="editRules(item)" class="img" width="31rpx" height="30rpx" fit="cover" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653980151000_180.png" />
</view>
<view class="Wire"></view>
</view>
......@@ -27,7 +27,7 @@
<view>暂无评论规则数据</view>
</view>
</view>
<commentDetailsPopu ref="getcommentPopup"></commentDetailsPopu>
<commentDetailsPopu ref="getcommentPopup" @change="changeData"></commentDetailsPopu>
</view>
</template>
<script>
......@@ -73,9 +73,9 @@
data.show = true
refs.getcommentPopup.$vm.showFun()
},
editRules(){//编辑规则
editRules(item){//编辑规则
data.show = true
refs.getcommentPopup.$vm.showFun()
refs.getcommentPopup.$vm.showFun(item)
},
deleteRules (){//删除规则
uni.showModal({
......@@ -98,7 +98,6 @@
item.optionsShow = !item.optionsShow;
},
clickoptions(item,subItem) {
let showTypeMsg = {
CourseId: item.CourseId,
Times: item.Times,
......@@ -111,6 +110,12 @@
})
item.optionsShow = false;
//调用父组件方法
context.emit('refreshData');
},
//刷新数据
changeData()
{
//调用父组件方法
context.emit('refreshData');
}
......
<template>
<view class="commentPopup-box">
<van-popup :show="show" :round="true" @close="closepopup">
<view class="commentPopup-box">
<van-icon class="commentPopup-closure" name="cross" @click="closepopup"/>
<view class="commentPopup-title">修改评语</view>
<view class="commentPopup-content">
<textarea placeholder="请填写评语内容"></textarea>
</view>
<view class="commentPopup-save flex">
<view @click="save">确认</view>
</view>
</view>
</van-popup>
<van-popup :show="show" :round="true" @close="closepopup">
<view class="commentPopup-box">
<van-icon class="commentPopup-closure" name="cross" @click="closepopup" />
<view class="commentPopup-title">修改评语</view>
<view class="commentPopup-content">
<textarea placeholder="请填写评语内容" v-model="stuCommentObj.Info"></textarea>
</view>
<view class="commentPopup-save flex">
<view @click="save">确认</view>
</view>
</view>
</van-popup>
</view>
</template>
<script>
import {
ref,
ref,
reactive,
toRefs,
onMounted,
getCurrentInstance,
inject,
watch
watch
} from "vue";
import { uploadFile } from "@/utils/index";
import {
uploadFile
} from "@/utils/index";
export default {
props: {
},
components: {},
setup(props,ctx) {
// 双滑块模式时,值必须是数组
const value = ref([10, 50]);
let {
emits: ['change'],
setup(props, ctx) {
// 双滑块模式时,值必须是数组
const value = ref([10, 50]);
let {
proxy
} = getCurrentInstance();
let data = reactive({
valueNum: ref([0, 0]),
show: false,
loading: false,
show: false,
loading: false,
stuCommentObj: {
Id: 0,
Info: ""
}
});
let methods = {
showFun(){
data.show = true
},
closepopup(){
data.show = false
},
onChange(value){
console.log(value)
// data.valueNum = value
// console.log(data.valueNum)
},
save(){
data.show = false
}
};
let methods = {
showFun(item) {
if (item) {
data.stuCommentObj.Id = item.Id;
data.stuCommentObj.Info = item.Info;
}
data.show = true
},
closepopup() {
data.show = false
},
save() {
proxy.$request("/Teacher/SetStuCommentInfo", data.stuCommentObj).then(res => {
if (res.Code == 1) {
uni.showToast({
icon: 'none',
duration: 500
});
}
});
ctx.emit("change");
data.show = false
}
};
let that = methods;
return {
...toRefs(data),
value,
...methods
value,
...methods
};
},
onLoad(){
},
onShow() {
onLoad() {
},
onShow() {
}
};
</script>
<style scoped>
.custom-button {
width: 26rpx;
color: #fff;
font-size: 20rpx;
line-height: 36rpx;
text-align: center;
background-color: #ee0a24;
border-radius: 100rpx;
}
.commentPopup-content{
background: #F7F7F7;
border-radius: 30rpx;
min-height: 152rpx;
padding: 37rpx 43rpx;
}
.commentPopup-save view{
background: #C91727;
font-size: 30rpx;
font-weight: bold;
letter-spacing: 1rpx;
width: 260rpx;
line-height: 88rpx;
border-radius: 44rpx;
text-align: center;
color: #FFFFFF;
}
.commentPopup-save{
justify-content: center;
margin-top: 40rpx;
}
.commentPopup-box .noData{
.custom-button {
width: 26rpx;
color: #fff;
font-size: 20rpx;
line-height: 36rpx;
text-align: center;
background-color: #ee0a24;
border-radius: 100rpx;
}
.commentPopup-content {
background: #F7F7F7;
border-radius: 30rpx;
min-height: 152rpx;
padding: 37rpx 43rpx;
}
.commentPopup-save view {
background: #C91727;
font-size: 30rpx;
font-weight: bold;
letter-spacing: 1rpx;
width: 260rpx;
line-height: 88rpx;
border-radius: 44rpx;
text-align: center;
flex:1;
color: #FFFFFF;
}
.commentPopup-save {
justify-content: center;
margin-top: 40rpx;
}
.commentPopup-box .noData {
text-align: center;
flex: 1;
width: 100%;
}
.commentPopup-box .noData image{
width:200rpx;
.commentPopup-box .noData image {
width: 200rpx;
margin-bottom: 40rpx;
}
.commentPopup-box .noData view{
.commentPopup-box .noData view {
font-size: 24rpx;
color: #cecece;
text-align: center;
}
.commentPopup-name{
background-color: #F7F7F7;
text-align: center;
border: 1px solid #F7F7F7;
height: 88rpx;
line-height: 88rpx;
padding: 0 10rpx;
border-radius: 44rpx;
font-size: 30rpx;
letter-spacing: 1rpx;
}
.commentPopup-title{
width: 100%;
text-align: center;
font-size: 30rpx;
font-weight: 500;
margin-bottom: 73rpx;
letter-spacing: 1rpx;
}
.commentPopup-closure{
position: absolute;
right: 31rpx;
top: 31rpx;
color: #282828;
font-size: 38rpx;
}
.commentPopup-box{
position: relative;
width: 548rpx;
padding: 48rpx 55rpx 60rpx 55rpx;
}
.commentPopup-box{
}
.commentPopup-name {
background-color: #F7F7F7;
text-align: center;
border: 1px solid #F7F7F7;
height: 88rpx;
line-height: 88rpx;
padding: 0 10rpx;
border-radius: 44rpx;
font-size: 30rpx;
letter-spacing: 1rpx;
}
.commentPopup-title {
width: 100%;
text-align: center;
font-size: 30rpx;
font-weight: 500;
margin-bottom: 73rpx;
letter-spacing: 1rpx;
}
.commentPopup-closure {
position: absolute;
right: 31rpx;
top: 31rpx;
color: #282828;
font-size: 38rpx;
}
.commentPopup-box {
position: relative;
width: 548rpx;
padding: 48rpx 55rpx 60rpx 55rpx;
}
.commentPopup-box {}
</style>
......@@ -113,7 +113,7 @@
homeWorks:[],
exams:[],
pageState: "more",
currentCourseId:189666293,
currentCourseId:45329247,
userData:{},
loading:false
});
......@@ -138,9 +138,9 @@
},
changeCourseHandler(id){
console.log(id,'........................')
data.Msg.courseId=189666293
data.OperationMsg.courseId=189666293
data.currentCourseId=189666293
data.Msg.courseId=45329247
data.OperationMsg.courseId=45329247
data.currentCourseId=45329247
methods.getCourseStuList()
methods.getExamPageList()
methods.getCourseHomeWorkList()
......
......@@ -25,7 +25,7 @@
</view>
</view>
</view>
<commentDetails :CourseCommentTimesList="courseTimeList" @refreshData="getCourseCommentTimes"></commentDetails>
<commentDetails :CourseCommentTimesList="courseTimeList" @refreshData="getStuCommentList"></commentDetails>
</view>
......@@ -96,8 +96,8 @@
uni.navigateBack({
delta: 1
})
},
//获取系统生成学员评价列表
getStuCommentList(){
proxy.$request("/Teacher/GetStuCommentList", data.Msg).then(res => {
if (res) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment