From e962318b2bf0ddbc5a9c608fc92176cf4bd15555 Mon Sep 17 00:00:00 2001 From: lion <120344285@qq.com> Date: Tue, 3 Dec 2024 16:45:51 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=A1=E6=A0=B8=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 8 +- src/components/LxHeader/index.vue | 3 +- src/utils/common.js | 8 ++ src/views/course/apply_list.vue | 47 ++++++-- .../course/components/updateStaturReason.vue | 102 +++++++++++++++++ src/views/student/components/detail.vue | 103 +++++++++++++++++- 6 files changed, 251 insertions(+), 20 deletions(-) create mode 100644 src/views/course/components/updateStaturReason.vue diff --git a/.env.development b/.env.development index b0cc0e4..8577249 100644 --- a/.env.development +++ b/.env.development @@ -2,8 +2,8 @@ ENV='development' # base api -VUE_APP_BASE_API=https://suzhoukeji-test.ali251.langye.net -VUE_APP_UPLOAD_API=https://suzhoukeji-test.ali251.langye.net/api/admin/upload-file +#VUE_APP_BASE_API=https://suzhoukeji-test.ali251.langye.net +#VUE_APP_UPLOAD_API=https://suzhoukeji-test.ali251.langye.net/api/admin/upload-file -#VUE_APP_BASE_API = https://wx.sstbc.com -#VUE_APP_UPLOAD_API = https://wx.sstbc.com/api/admin/upload-file +VUE_APP_BASE_API = https://wx.sstbc.com +VUE_APP_UPLOAD_API = https://wx.sstbc.com/api/admin/upload-file diff --git a/src/components/LxHeader/index.vue b/src/components/LxHeader/index.vue index b423786..7fba733 100644 --- a/src/components/LxHeader/index.vue +++ b/src/components/LxHeader/index.vue @@ -10,7 +10,8 @@ - {{text || $route.meta.title}} + {{text || $route.meta.title}} +
diff --git a/src/utils/common.js b/src/utils/common.js index b65c343..34ba4f0 100644 --- a/src/utils/common.js +++ b/src/utils/common.js @@ -1,6 +1,7 @@ import { Message } from 'element-ui' +import moment from "moment" let base = { showMessage(msg,type){ return Message({ @@ -48,6 +49,13 @@ let base = { return maskedPhoneNumber; }, + formatDate(date){ + if(this.isNull(date)){ + return "-" + }else{ + return moment(date).format('YYYY-MM-DD HH:mm:ss') + } + }, checkUrl (url) { // url= 协议://(ftp的登录信息)[IP|域名](:端口号)(/或?请求参数) var strRegex = diff --git a/src/views/course/apply_list.vue b/src/views/course/apply_list.vue index b7aae31..5b8679a 100644 --- a/src/views/course/apply_list.vue +++ b/src/views/course/apply_list.vue @@ -94,9 +94,12 @@ 导入 导出 - - 批量审核 - + + 批量审核通过 + + + 批量审核不通过 +
@@ -120,6 +123,16 @@ {{getIndex(scope.$index)}} + + - + + + + - + + @@ -165,12 +182,13 @@ import { download } from "@/utils/downloadRequest"; - + import updateStaturReason from "./components/updateStaturReason.vue" export default { mixins: [myMixins, formMixin], components: { studentDetail, - imports + imports, + updateStaturReason }, data() { return { @@ -216,7 +234,7 @@ fixed: 'left' }, { - prop: 'user.username', + prop: 'username', label: '姓名', align: 'center', width: 120, @@ -388,12 +406,21 @@ if (this.selectids.length < 1) { this.$message.warning("请先选择要审核的学员") return + } + let ids = this.selectids.join(',') + if(status==2){ + this.$refs.updateStaturReason.setIds({ + course_id: this.select.course_id, + ids: ids, + status: status, + }) + this.$refs.updateStaturReason.isShow = true + return } - let ids = this.selectids.join(',') updateStatus({ course_id: this.select.course_id, ids: ids, - status: 1, + status: status, }).then(res => { this.$Message.success('审核成功') this.getList() diff --git a/src/views/course/components/updateStaturReason.vue b/src/views/course/components/updateStaturReason.vue new file mode 100644 index 0000000..4de8735 --- /dev/null +++ b/src/views/course/components/updateStaturReason.vue @@ -0,0 +1,102 @@ + + + + + diff --git a/src/views/student/components/detail.vue b/src/views/student/components/detail.vue index b9cb0de..14ff680 100644 --- a/src/views/student/components/detail.vue +++ b/src/views/student/components/detail.vue @@ -13,8 +13,14 @@
课程体系:{{subjectObj.leibie}}
- + +
@@ -75,6 +81,64 @@ +
+ + + + +
+ + + + + +
@@ -113,7 +177,7 @@ {{sign_result.reason?sign_result.reason:''}}
- + @@ -275,7 +339,24 @@ file_ids: [], reason: '', position: '' - }, + }, + audit_item:[{ + prop:'username', + label:'操作人' + },{ + prop:'ip_address', + label:'Ip', + width:120 + },{ + prop:'event', + label:'操作类型' + },{ + prop:'values', + label:'操作详情' + },{ + prop:'created_at', + label:'操作时间' + },], } }, created() {}, @@ -305,7 +386,19 @@ submit() { if (this.id) { this.form.id = this.id - } + } + + // 如果是 不通过, remark必填 + if(this.form.status===2){ + if(this.base.isNull(this.form.reason)){ + this.$message({ + type: 'warning', + message: '审核不通过时,请填写备注' + }) + return + } + } + let _arr = [] if (this.fileList.length > 0) { this.fileList.map(item => {