From 4277f985b07d298c17cc7e0b93b5653e8c29dffa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E4=BE=9D=E6=A2=A6?= <15822465730@163.com> Date: Thu, 18 Dec 2025 11:58:36 +0800 Subject: [PATCH] =?UTF-8?q?1=E6=9C=9F=E9=97=AE=E9=A2=98=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/styles/index.scss | 2 +- src/assets/styles/portal-index.scss | 15 +++++-- src/components/signup/AudienceModal.vue | 4 +- src/components/signup/SignupModal.vue | 4 +- src/main.js | 4 +- src/utils/index.js | 13 +++++- src/views/course/CourseManage.vue | 6 +-- src/views/course/ManageListRemote.vue | 54 ++++++++++++------------- src/views/course/TeacherList.vue | 45 +++++++++++++++++---- src/views/study/coursenew.vue | 2 +- 10 files changed, 99 insertions(+), 50 deletions(-) diff --git a/src/assets/styles/index.scss b/src/assets/styles/index.scss index bbf3774e..a39b8336 100644 --- a/src/assets/styles/index.scss +++ b/src/assets/styles/index.scss @@ -19,7 +19,7 @@ body { font-family: "Menlo", "苹方-简" !important; } .el-message { - top: 15%!important + top: 15%; } .el-card.is-always-shadow, .el-card.is-hover-shadow:focus, .el-card.is-hover-shadow:hover{ box-shadow: none; diff --git a/src/assets/styles/portal-index.scss b/src/assets/styles/portal-index.scss index 5c17e452..2a8f4b86 100644 --- a/src/assets/styles/portal-index.scss +++ b/src/assets/styles/portal-index.scss @@ -438,7 +438,7 @@ min-width: 180px !important; height: 52px !important; border-radius: 12px !important; - top: 270px !important; + // top: 270px !important; font-size: 16px !important; font-weight: bold !important; border: none !important; @@ -454,7 +454,7 @@ min-width: 180px !important; height: 52px !important; border-radius: 12px !important; - top: 270px !important; + // top: 270px !important; font-size: 16px !important; border: none !important; @@ -472,7 +472,7 @@ min-width: 180px !important; height: 52px !important; border-radius: 12px !important; - top: 270px !important; + // top: 270px !important; font-size: 16px !important; font-weight: bold !important; @@ -491,7 +491,7 @@ min-width: 180px !important; height: 52px !important; border-radius: 12px !important; - top: 270px !important; + // top: 270px !important; font-size: 16px !important; font-weight: bold !important; border: none !important; @@ -1610,3 +1610,10 @@ } } } + + + .tooltip-multiline { + max-width: 400px; /* 设置最大宽度,超出则换行 */ + white-space: normal; /* 允许换行 */ + word-break: break-all; /* 断行规则 */ + } \ No newline at end of file diff --git a/src/components/signup/AudienceModal.vue b/src/components/signup/AudienceModal.vue index f58aebda..2ed651dc 100644 --- a/src/components/signup/AudienceModal.vue +++ b/src/components/signup/AudienceModal.vue @@ -236,7 +236,7 @@ export default { handleConfirm() { const targetId = this.courseDetail?.id; if(!this.selectedRows.length) { - this.$showMessage('请添加学员', 'error'); + this.$showManageMessage('请添加学员', 'error'); return } saveStu({ @@ -246,7 +246,7 @@ export default { groupIds: [], studentList: this.selectedRows.map((e) => ({ id: e.userId })), }).then(() => { - this.$showMessage("添加成功", 'success'); + this.$showManageMessage("添加成功", 'success'); this.$emit("confirm", this.selectedRows); this.handleClose(); }); diff --git a/src/components/signup/SignupModal.vue b/src/components/signup/SignupModal.vue index 50888b86..76b847ee 100644 --- a/src/components/signup/SignupModal.vue +++ b/src/components/signup/SignupModal.vue @@ -615,7 +615,7 @@ export default { this.groupMemberNumber && this.groupMemberCount < this.groupMemberNumber + this.projectSelectRows.length + this.stuSelectRows.length ) { - return this.$showMessage("添加小组学员超过最大值", 'error'); + return this.$showManageMessage("添加小组学员超过最大值", 'error'); } saveStu({ targetId: this.courseDetail?.id || this.id, @@ -625,7 +625,7 @@ export default { studentList: this.stuSelectRows.map((e) => ({id: e.id})), }).then((res) => { console.log('res', res); - this.$showMessage("添加成功", 'success'); + this.$showManageMessage("添加成功", 'success'); this.$emit("confirm"); this.handleClose(); }); diff --git a/src/main.js b/src/main.js index ba3ba532..ae17c336 100644 --- a/src/main.js +++ b/src/main.js @@ -59,7 +59,7 @@ import 'swiper/dist/css/swiper.css'; Vue.use(VueAwesomeSwiper) import watermark from './utils/warterMark.js' import Bus from './utils/bus.js' -import {showMessage} from './utils/index.js' +import {showMessage, showManageMessage} from './utils/index.js' import MessageBoxService from './utils/simpleMessageBox.js' @@ -68,6 +68,8 @@ Vue.use(MessageBoxService) Vue.prototype.$showMessage = showMessage +Vue.prototype.$showManageMessage = showManageMessage + Vue.prototype.$bus = Bus Vue.prototype.$watermark = watermark diff --git a/src/utils/index.js b/src/utils/index.js index ceba34d4..5b0e9cb7 100644 --- a/src/utils/index.js +++ b/src/utils/index.js @@ -462,6 +462,17 @@ export function showMessage(message, status) { message: message, type: status, duration: 5000, - customClass: 'new-message' + customClass: 'new-message', + offset: 270 + }); +} + +export function showManageMessage(message, status) { + this.$message({ + message: message, + type: status, + duration: 5000, + customClass: 'new-message', + offset: 80 }); } \ No newline at end of file diff --git a/src/views/course/CourseManage.vue b/src/views/course/CourseManage.vue index c5098d9b..6c816349 100644 --- a/src/views/course/CourseManage.vue +++ b/src/views/course/CourseManage.vue @@ -736,14 +736,14 @@ export default { }) .then((res) => { if (res && res.status === 200) { - this.$showMessage("删除成功", 'success'); + this.$showManageMessage("删除成功", 'success'); this.getSignupList(); } else if (res) { - this.$showMessage(res.message || "删除失败", 'error'); + this.$showManageMessage(res.message || "删除失败", 'error'); } }) .catch((err) => { - this.$showMessage("删除失败", 'error'); + this.$showManageMessage("删除失败", 'error'); }); }) .catch((err) => { diff --git a/src/views/course/ManageListRemote.vue b/src/views/course/ManageListRemote.vue index 58c34bfd..44a75fe2 100644 --- a/src/views/course/ManageListRemote.vue +++ b/src/views/course/ManageListRemote.vue @@ -973,7 +973,7 @@ export default { const hasStart = !!this.params.learningTimeStart; const hasEnd = !!this.params.learningTimeEnd; if ((hasStart && !hasEnd) || (!hasStart && hasEnd)) { - this.$showMessage('请选择完整的培训时间范围', 'warning'); + this.$showManageMessage('请选择完整的培训时间范围', 'warning'); return false; } return true; @@ -1160,7 +1160,7 @@ export default { document.body.removeChild(link); window.URL.revokeObjectURL(url); } catch (error) { - this.$showMessage(error.message || '导出失败', 'error'); + this.$showManageMessage(error.message || '导出失败', 'error'); } finally { this.exportLoading = false; } @@ -1188,7 +1188,7 @@ export default { // console.log('fa') apiCourse.setTop(params).then(res => { if (res.status === 200 && res.result === true) { - this.$showMessage('置顶成功!', 'success') + this.$showManageMessage('置顶成功!', 'success') this.searchData(); } else if (res.status === 500) { const confirmText = `已置顶10条课程,若需继续置顶,请对部分课程执行取消置顶操作`; @@ -1200,16 +1200,16 @@ export default { customClass: 'custom-confirm-dialog' }).then(() => {}).catch(() => { }); } else { - this.$showMessage(res.message, 'error'); + this.$showManageMessage(res.message, 'error'); } }) } else if (row.isTop == true) { apiCourse.setTop(params).then(res => { if (res.status === 200 && res.result === true) { - this.$showMessage('取消成功!', 'success') + this.$showManageMessage('取消成功!', 'success') this.searchData(); } else { - this.$showMessage(res.message, 'error'); + this.$showManageMessage(res.message, 'error'); } }) } @@ -1231,13 +1231,13 @@ export default { }; apiCourse.copyCourse(reqdata).then(rs => { if (rs.status === 200) { - this.$showMessage('复制成功', 'success'); + this.$showManageMessage('复制成功', 'success'); this.searchData(); } else { - this.$showMessage(rs.message || '复制失败', 'error'); + this.$showManageMessage(rs.message || '复制失败', 'error'); } }).catch(() => { - this.$showMessage('复制失败', 'error'); + this.$showManageMessage('复制失败', 'error'); }); }).catch(() => { }); }, @@ -1251,13 +1251,13 @@ export default { }).then(() => { apiCourse.revokeSubmit(row.id).then((res) => { if (res.status === 200 && res.result) { - this.$showMessage('撤回成功', 'success'); + this.$showManageMessage('撤回成功', 'success'); this.searchData(); } else { - this.$showMessage(res.message || '撤回失败', 'error'); + this.$showManageMessage(res.message || '撤回失败', 'error'); } }).catch(() => { - this.$showMessage('撤回失败', 'error'); + this.$showManageMessage('撤回失败', 'error'); }); }).catch(() => { }); }, @@ -1312,15 +1312,15 @@ export default { } apiCourse.audit(params).then(res => { if (res.status === 200) { - this.$showMessage('操作成功!', 'success'); + this.$showManageMessage('操作成功!', 'success'); this.dialogVisible = false; this.searchData(); } else { - this.$showMessage(res.message, 'error'); + this.$showManageMessage(res.message, 'error'); } }) } else { - this.$showMessage('暂未开放!', 'warning'); + this.$showManageMessage('暂未开放!', 'warning'); } }, @@ -1353,13 +1353,13 @@ export default { try { const { status } = await apiCourse.setEnabled(params); if (status === 200) { - this.$showMessage(`${actionText}成功`, 'success'); + this.$showManageMessage(`${actionText}成功`, 'success'); row.enabled = nextEnabled; } else { - this.$showMessage(`${actionText}失败`, 'error'); + this.$showManageMessage(`${actionText}失败`, 'error'); } } catch (error) { - this.$showMessage(`${actionText}失败`, 'error'); + this.$showManageMessage(`${actionText}失败`, 'error'); } }, // 课程查询 @@ -1379,11 +1379,11 @@ export default { this.page.count = rs.result.count; this.page.pageSize = rs.result.pageSize; } else { - return this.$showMessage(rs.message, 'error'); + return this.$showManageMessage(rs.message, 'error'); } }).catch(err => { console.error('查询课程列表失败:', err); - this.$showMessage('查询失败,请稍后重试', 'error'); + this.$showManageMessage('查询失败,请稍后重试', 'error'); }); }, @@ -1407,7 +1407,7 @@ export default { }, viewTopic(row) { if (row.status == 1) { - return this.$showMessage('请提交课程再预览!', 'warning') + return this.$showManageMessage('请提交课程再预览!', 'warning') } this.examin = {}; this.examin.detailType = row.type; @@ -1465,7 +1465,7 @@ export default { if (!ele) return; ele.select(); document.execCommand('Copy'); - this.$showMessage('复制成功', 'success'); + this.$showManageMessage('复制成功', 'success'); }, downloadQrcode() { const container = document.getElementById('qrcode'); @@ -1639,10 +1639,10 @@ export default { // } else { // item.isTop = true; // } -// this.$showMessage('xxx', 'success'); +// this.$showManageMessage('xxx', 'success'); // }, delItem(row) { - // this.$showMessage('删除成功', 'success'); + // this.$showManageMessage('删除成功', 'success'); // return false this.$confirm(`确认删除${row.name}吗?`, '删除确认', { confirmButtonText: '确定', @@ -1660,7 +1660,7 @@ export default { // {id:课程id,多个使用逗号分隔,Boolean erasable 是否物理删除,title:课程的名称, remark 备注} const { status } = await apiCourse.del(params); if (status === 200) { - this.$showMessage('删除成功', 'success'); //只是之前发布过的课程删除才可 + this.$showManageMessage('删除成功', 'success'); //只是之前发布过的课程删除才可 // if(!row.erasable){ // let event = { // key: "CourseDelete",//被管理员删除 @@ -1680,11 +1680,11 @@ export default { this.searchData(); } } catch (error) { - this.$showMessage('删除失败', 'error'); + this.$showManageMessage('删除失败', 'error'); } }) .catch((err) => { - // this.$showMessage('已取消删除', 'info'); + // this.$showManageMessage('已取消删除', 'info'); }); }, showAddCatalogZhang(bal) { diff --git a/src/views/course/TeacherList.vue b/src/views/course/TeacherList.vue index dc71e124..9646abf5 100644 --- a/src/views/course/TeacherList.vue +++ b/src/views/course/TeacherList.vue @@ -144,20 +144,31 @@ - + - {{ scope.row.auditState ? '通过' : '不通过' }} + {{ auditTypeEnum[scope.row.auditType] }} - + {{ auditEnum[scope.row.status] }} - - - - + + + + {{ auditResultEnum[scope.row.auditResult] }} + + + + + + + + {{scope.row.auditRemark}} + + + 关 闭 @@ -278,9 +289,19 @@ export default { loading: false, noMore: false, auditEnum: { - 1: "未审核", + 1: "审核中", 2: "审核不通过", 9: "审核通过", + }, + auditTypeEnum: { + 1: "新建", + 2: "编辑", + 3: "停用", + 4: "启用", + }, + auditResultEnum: { + 0: "驳回", + 1: "通过", }, hoverStates: {}, }; @@ -621,6 +642,14 @@ export default {
+ {{scope.row.auditRemark}}