Commit 8c12371c authored by 罗超's avatar 罗超

Merge branch 'master' of http://gitlab.oytour.com/youjie/thinkapp

parents b38307c4 dba62eab
<script> <script>
export default { export default {
onLaunch() { onLaunch() {
// console.log('App Launch') //调用定义的更新方法
// this.VersionUpdate();
}, },
onShow() { onShow() {
// console.log('App Show') // console.log('App Show')
...@@ -12,6 +13,63 @@ export default { ...@@ -12,6 +13,63 @@ export default {
onHide() { onHide() {
// console.log('App Hide') // console.log('App Hide')
}, },
methods:{
//定义更新方法
VersionUpdate() {
// 判断应用的 getUpdateManager 是否在当前版本可用
if (uni.canIUse('getUpdateManager')) {
const updateManager = uni.getUpdateManager()
// 向小程序后台请求完新版本信息
updateManager.onCheckForUpdate(function(res) {
if (res.hasUpdate) {
//小程序有新版本,静默下载新版本,新版本下载完成
updateManager.onUpdateReady(function() {
//模态弹窗(确认、取消)
uni.showModal({
title: '更新提示',
content: '小程序已发布新版本,是否重启?',
success: function(res) {
//用户点击确定
if (res.confirm) {
//当新版本下载完成,调用该方法会强制当前小程序应用上新版本并重启
updateManager.applyUpdate()
} //用户点击取消
else if (res.cancel) {
//强制用户更新,弹出第二次弹窗
uni.showModal({
title: '提示',
content: '小程序已发布新版本,是否重启',
showCancel: false, //隐藏取消按钮
success: function(res) {
//第二次提示后,强制更新
if (res.confirm) {
// 当新版本下载完成,调用该方法会强制当前小程序应用上新版本并重启
updateManager.applyUpdate()
}
}
})
}
}
})
})
// 当新版本下载失败
updateManager.onUpdateFailed(function() {
uni.showModal({
title: '提示',
content: '请您删除当前小程序,重新打开小程序',
})
})
}
})
} else {
// 提示用户在最新版本的客户端上体验
uni.showModal({
title: '温馨提示',
content: '当前微信版本过低,可能无法使用该功能,请升级到最新版本后重试。'
})
}
}
}
}; };
</script> </script>
......
...@@ -174,7 +174,7 @@ ...@@ -174,7 +174,7 @@
queryTecherCourse(){ queryTecherCourse(){
getTeacherCourse().then(r=>{ getTeacherCourse().then(r=>{
data.courses=r.Data data.courses=r.Data
data.titleList[0].data=r.Data.AllCourseList.reverse() data.titleList[0].data=r.Data.AllCourseList;
data.titleList[1].data=r.Data.NotFinishList data.titleList[1].data=r.Data.NotFinishList
data.titleList[2].data=r.Data.FinishList data.titleList[2].data=r.Data.FinishList
data.currentCourse=r.Data.AllCourseList.length>0?r.Data.AllCourseList[0]:null data.currentCourse=r.Data.AllCourseList.length>0?r.Data.AllCourseList[0]:null
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<van-icon class="commentPopup-closure" name="cross" @click="closepopup" /> <van-icon class="commentPopup-closure" name="cross" @click="closepopup" />
<view class="commentPopup-title">修改评语</view> <view class="commentPopup-title">修改评语</view>
<view class="commentPopup-content"> <view class="commentPopup-content">
<textarea placeholder="请填写评语内容" v-model="stuCommentObj.Info"></textarea> <textarea placeholder="请填写评语内容" v-model="stuCommentObj.Info" maxlength="-1"></textarea>
</view> </view>
<view class="commentPopup-save flex"> <view class="commentPopup-save flex">
......
...@@ -13,7 +13,8 @@ ...@@ -13,7 +13,8 @@
</view> </view>
</view> </view>
<view class="RuleSettings-content"> <view class="RuleSettings-content">
<textarea placeholder="请填写评论内容" v-model="ruleObj.Info"></textarea> <!-- <van-field v-model="ruleObj.Info" rows="10"/> -->
<textarea placeholder="请填写评论内容" v-model="ruleObj.Info" maxlength="-1"></textarea>
</view> </view>
<view class="rulesPopup-save flex"> <view class="rulesPopup-save flex">
<van-loading color="#f5f5f5" v-if="loading" /> <van-loading color="#f5f5f5" v-if="loading" />
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<view class="setComments-content" @click="goComment(item)"> <view class="setComments-content" @click="goComment(item)">
<view class="center-line"></view> <view class="center-line"></view>
<view class="setComments-title flex"> <view class="setComments-title flex">
<text class="setComments-title-left">{{item.Times}}次评价</text> <text class="setComments-title-left">{{item.Title}}</text>
<view class="setComments-title-right"> <view class="setComments-title-right">
<view class="setComments-options flex"> <view class="setComments-options flex">
<view class="setComments-options-title flex" @click.stop="showActionHandler(item)"> <view class="setComments-options-title flex" @click.stop="showActionHandler(item)">
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
} from "vue"; } from "vue";
import navbar from '../../components/navbar.vue' import navbar from '../../components/navbar.vue'
export default { export default {
props: ["CourseCommentTimesList","courseId"], props: ["CourseCommentTimesList","courseId","courseName"],
emits: ['refreshData'], emits: ['refreshData'],
components: { components: {
navbar, navbar,
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
addComments(){ addComments(){
console.log(props.courseId) console.log(props.courseId)
uni.navigateTo({ uni.navigateTo({
url: '/pages/setComments/teacher-commit?courseId=' + props.courseId url: '/pages/setComments/teacher-commit?courseId=' + props.courseId +'&courseName=' + props.courseName
}) })
}, },
showActionHandler(item){ showActionHandler(item){
...@@ -100,11 +100,11 @@ ...@@ -100,11 +100,11 @@
// item.optionsShow = !item.optionsShow; // item.optionsShow = !item.optionsShow;
// }, // },
clickoptions(type) { clickoptions(type) {
console.log("data.currentAction",data.currentAction);
let showTypeMsg = { let showTypeMsg = {
CourseId: data.currentAction.CourseId, CourseId: data.currentAction.CourseId,
Times: data.currentAction.Times, CommentMainId: data.currentAction.Id,
ShowType: type ShowType: type,
}; };
proxy.$request("/Teacher/SetStuCommentShowTypeByTimes", showTypeMsg).then(res => { proxy.$request("/Teacher/SetStuCommentShowTypeByTimes", showTypeMsg).then(res => {
if (res.Code==1) { if (res.Code==1) {
......
<template>
<view class="signOut-box" @click="signOut">
<view class="index-header-signOut flex">
<van-image width="72rpx" height="72rpx" fit="cover" class="img"
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1654580469000_635.png" />
<text>退出登录</text>
</view>
</view>
</template>
<script>
import { reactive, toRefs, onMounted } from "vue";
export default {
name: "",
props: {
},
components: {},
setup(props) {
let data = reactive({
});
let methods = {
signOut(){
uni.showModal({
title: '提示',
content: '将退出登录,是否继续',
success: function(res) {
if (res.confirm) {
uni.reLaunch({
url: '/pages/login/accountLogin'
});
uni.removeStorageSync('userInfo')
} else if (res.cancel) {
}
}
});
}
};
onMounted(() => {
});
return {
...toRefs(data),
...methods,
};
},
};
</script>
<style scoped>
.index-header-signOut text{
font-size: 26rpx;
font-weight: bold;
color: #282828;
margin-left: 20rpx;
letter-spacing: 2rpx;
}
.index-header-signOut{
align-items: center;
}
.signOut-box{
padding: 0 30rpx;
}
</style>
\ No newline at end of file
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<page-meta :page-style="showPopu?'overflow:hidden;':''"> <page-meta :page-style="showPopu?'overflow:hidden;':''">
<view class="indexpage"> <view class="indexpage">
<navbar class="navbarSticky" bg="#F6F6F6"> <navbar class="navbarSticky" bg="#F6F6F6">
<view class="index-header-box"> <!-- <view class="index-header-box">
<view class="index-header-img"> <view class="index-header-img">
<van-image width="100%" height="100%" fit="cover" class="img" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653464014000_713.png" /> <van-image width="100%" height="100%" fit="cover" class="img" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653464014000_713.png" />
</view> </view>
...@@ -12,7 +12,8 @@ ...@@ -12,7 +12,8 @@
</view> </view>
<view class="index-header-name">{{userData.AccountName}}</view> <view class="index-header-name">{{userData.AccountName}}</view>
</view> </view>
</view> </view> -->
<signOut></signOut>
</navbar> </navbar>
<view style="margin: 40rpx 0 10rpx 0;"> <view style="margin: 40rpx 0 10rpx 0;">
<view style="padding:0 50rpx;font-weight: 800;color: #282828;"> <view style="padding:0 50rpx;font-weight: 800;color: #282828;">
...@@ -47,6 +48,7 @@ ...@@ -47,6 +48,7 @@
import JobComponents from '@/components/index/JobComponents' import JobComponents from '@/components/index/JobComponents'
import examComponents from '@/components/index/examComponents' import examComponents from '@/components/index/examComponents'
import commentsComponents from '@/components/index/commentsComponents' import commentsComponents from '@/components/index/commentsComponents'
import signOut from "@/components/signOut";
import vue, { import vue, {
ref, ref,
reactive, reactive,
...@@ -77,7 +79,8 @@ ...@@ -77,7 +79,8 @@
courseCard, courseCard,
JobComponents, JobComponents,
examComponents, examComponents,
commentsComponents commentsComponents,
signOut
}, },
setup(props) { setup(props) {
let { let {
...@@ -104,7 +107,6 @@ ...@@ -104,7 +107,6 @@
}); });
}, },
changeCourseHandler(id){ changeCourseHandler(id){
console.log(id,',,,,,,,,,,,,,')
methods.getStuHomeWorkAndExam(id) methods.getStuHomeWorkAndExam(id)
}, },
getStuCourse() { getStuCourse() {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<page-meta :page-style="showPopu?'overflow:hidden;':''"> <page-meta :page-style="showPopu?'overflow:hidden;':''">
<view class="workSituationpage"> <view class="workSituationpage">
<navbar class="navbarSticky" bg="#F6F6F6"> <navbar class="navbarSticky" bg="#F6F6F6">
<view class="index-header-box" @click="back"> <!-- <view class="index-header-box" @click="back">
<view class="index-header-img"> <view class="index-header-img">
<van-image width="100%" height="100%" fit="cover" class="img" <van-image width="100%" height="100%" fit="cover" class="img"
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653464014000_713.png" /> src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653464014000_713.png" />
...@@ -13,7 +13,8 @@ ...@@ -13,7 +13,8 @@
</view> </view>
<view class="index-header-name">{{userData.AccountName}}</view> <view class="index-header-name">{{userData.AccountName}}</view>
</view> </view>
</view> </view> -->
<signOut></signOut>
</navbar> </navbar>
<view style="margin: 40rpx 0 10rpx 0;" class="workSituationAccountName flex"> <view style="margin: 40rpx 0 10rpx 0;" class="workSituationAccountName flex">
<view style="padding:0 50rpx;font-weight: 800;color: #282828;"> <view style="padding:0 50rpx;font-weight: 800;color: #282828;">
...@@ -63,6 +64,7 @@ ...@@ -63,6 +64,7 @@
import operation from '@/components/index/workSituation/operation' import operation from '@/components/index/workSituation/operation'
import studentList from '@/components/index/workSituation/studentList' import studentList from '@/components/index/workSituation/studentList'
import examList from '@/components/index/workSituation/examList' import examList from '@/components/index/workSituation/examList'
import signOut from "@/components/signOut";
import vue, { import vue, {
ref, ref,
reactive, reactive,
...@@ -92,7 +94,8 @@ ...@@ -92,7 +94,8 @@
operation, operation,
studentList, studentList,
examList, examList,
Loadmore Loadmore,
signOut
}, },
setup(props) { setup(props) {
let { let {
...@@ -167,8 +170,10 @@ ...@@ -167,8 +170,10 @@
//获取学生列表 //获取学生列表
getCourseStuList(){ getCourseStuList(){
data.pageState = "loading"; data.pageState = "loading";
uni.showLoading()
proxy.$request("/Teacher/GetCourseStu", data.OperationMsg).then(res => { proxy.$request("/Teacher/GetCourseStu", data.OperationMsg).then(res => {
if(res){ if(res){
uni.hideLoading()
data.titleList.forEach(item => { data.titleList.forEach(item => {
if(item.name=='学生列表'){ if(item.name=='学生列表'){
item.num = res.Data.length item.num = res.Data.length
...@@ -182,8 +187,10 @@ ...@@ -182,8 +187,10 @@
//获取作业情况列表 //获取作业情况列表
getCourseHomeWorkList(){ getCourseHomeWorkList(){
data.pageState = "loading"; data.pageState = "loading";
uni.showLoading()
proxy.$request("/Teacher/GetCourseHomeWork", data.OperationMsg).then(res => { proxy.$request("/Teacher/GetCourseHomeWork", data.OperationMsg).then(res => {
if(res){ if(res){
uni.hideLoading()
data.titleList.forEach(item => { data.titleList.forEach(item => {
if(item.name=='作业情况'){ if(item.name=='作业情况'){
item.num = res.Data.length item.num = res.Data.length
...@@ -197,8 +204,10 @@ ...@@ -197,8 +204,10 @@
//获取考试信息列表 //获取考试信息列表
getExamPageList(){ getExamPageList(){
data.pageState = "loading"; data.pageState = "loading";
uni.showLoading()
proxy.$request("/Exam/GetExamPageList", data.Msg).then(res => { proxy.$request("/Exam/GetExamPageList", data.Msg).then(res => {
if(res){ if(res){
uni.hideLoading()
data.titleList.forEach(item => { data.titleList.forEach(item => {
if(item.name=='考试信息'){ if(item.name=='考试信息'){
item.num = res.Data.RowsCount item.num = res.Data.RowsCount
...@@ -380,6 +389,7 @@ ...@@ -380,6 +389,7 @@
margin-right: 20rpx; margin-right: 20rpx;
background: #FFFFFF; background: #FFFFFF;
} }
.workSituationpage { .workSituationpage {
min-height: 100vh; min-height: 100vh;
background-color: #f6f6f6; background-color: #f6f6f6;
......
...@@ -13,15 +13,27 @@ ...@@ -13,15 +13,27 @@
<view class="login-title"> <view class="login-title">
账号登录 账号登录
</view> </view>
<view style="margin:60rpx auto;text-align: center;"> <view style="margin:60rpx auto;text-align: center;height: 256rpx;overflow: hidden;">
<div style="display: inline-block;" @click="changeTypeHandler(1)"> <div style="display: inline-block;" @click="changeTypeHandler(1)">
<image :class="{'login-grey-avatar':userLoginType==2}" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653894192000_645.png" mode="widthFix" style="width:142rpx;"></image> <van-image
:class="{'login-grey-avatar':userLoginType==2}"
width="142rpx"
height="142rpx"
lazy-load
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653894192000_645.png"
/>
<view style="color: #282828;font-size: 24rpx;font-weight: 800;"> <view style="color: #282828;font-size: 24rpx;font-weight: 800;">
学员 学员
</view> </view>
</div> </div>
<div style="display: inline-block;margin-left:148rpx;" @click="changeTypeHandler(2)"> <div style="display: inline-block;margin-left:148rpx;" @click="changeTypeHandler(2)">
<image :class="{'login-grey-avatar':userLoginType==1}" src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653894197000_691.png" mode="widthFix" style="width:142rpx;"></image> <van-image
:class="{'login-grey-avatar':userLoginType==1}"
width="142rpx"
height="142rpx"
lazy-load
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1653894197000_691.png"
/>
<view style="color: #282828;font-size: 24rpx;font-weight: 800;"> <view style="color: #282828;font-size: 24rpx;font-weight: 800;">
教师 教师
</view> </view>
...@@ -226,6 +238,7 @@ ...@@ -226,6 +238,7 @@
.login-background{ .login-background{
position: fixed; position: fixed;
width: 100%; width: 100%;
height: 100%;
top: 0; top: 0;
bottom: 0; bottom: 0;
background: -moz-linear-gradient(top, #C41726 0%, #831D1C 100%); background: -moz-linear-gradient(top, #C41726 0%, #831D1C 100%);
......
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
<view class="addComment-textarea-box"> <view class="addComment-textarea-box">
<view class="hotsopt" @click="expendStatus=!expendStatus"></view> <view class="hotsopt" @click="expendStatus=!expendStatus"></view>
<view class="content-textarea-box"> <view class="content-textarea-box">
<textarea placeholder="请填写评论内容" v-model="postMsg.Info"></textarea> <textarea placeholder="请填写评论内容" v-model="postMsg.Info" maxlength="-1"></textarea>
</view> </view>
</view> </view>
<van-popup :z-index="1000" :show="show" :round="true" position="bottom" custom-style="height: 70vh" @close="closepopup"> <van-popup :z-index="1000" :show="show" :round="true" position="bottom" custom-style="height: 70vh" @close="closepopup">
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
<view class="commentDetails-index-setType flex"> <view class="commentDetails-index-setType flex">
<view class="commentDetails-setType-text flex"> <view class="commentDetails-setType-text flex">
<view> <view>
{{topData.Times}}次评价 {{topData.Title}}
</view> </view>
<view class="flex"> <view class="flex">
<text>{{topData.ShowTypeStr}}</text> <text>{{topData.ShowTypeStr}}</text>
...@@ -77,14 +77,16 @@ ...@@ -77,14 +77,16 @@
checked: '1', checked: '1',
Msg: { Msg: {
CourseId: '', CourseId: '',
CommentTimes:1 CommentTimes:1,
CommentMainId:0,
}, },
courseTimeList: [], courseTimeList: [],
topData:{ topData:{
ShowTypeStr:"", ShowTypeStr:"",
Times:1, Times:1,
CreateTime:"", CreateTime:"",
CreateTypeStr:"" CreateTypeStr:"",
Title:"",
} }
}); });
let methods = { let methods = {
...@@ -146,8 +148,9 @@ ...@@ -146,8 +148,9 @@
this.topData.Times = json.Times; this.topData.Times = json.Times;
this.topData.CreateTime = json.CreateTime; this.topData.CreateTime = json.CreateTime;
this.topData.CreateTypeStr = json.CreateTypeStr; this.topData.CreateTypeStr = json.CreateTypeStr;
this.topData.Title=json.Title;
this.Msg.CommentTimes = json.Times; this.Msg.CommentTimes = json.Times;
this.Msg.CommentMainId=json.Id;
}, },
onShow() { onShow() {
this.getStuCommentList(); this.getStuCommentList();
......
...@@ -146,7 +146,6 @@ ...@@ -146,7 +146,6 @@
}, },
//编辑规则 //编辑规则
editRules(item,index) { editRules(item,index) {
data.editor=index data.editor=index
data.show = true data.show = true
}, },
......
...@@ -30,7 +30,7 @@ ...@@ -30,7 +30,7 @@
</view> </view>
</view> </view>
</view> </view>
<setComments v-if="Msg.CourseId!=''" :CourseCommentTimesList="courseTimeList" :courseId="Msg.CourseId" @refreshData="getCourseCommentTimes"></setComments> <setComments v-if="Msg.CourseId!=''" :CourseCommentTimesList="courseTimeList" :courseId="Msg.CourseId" :courseName="CourseName" @refreshData="getCourseCommentTimes"></setComments>
</view> </view>
</view> </view>
......
This diff is collapsed.
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