兵马未动 粮草先行

This commit is contained in:
RISE
2026-02-08 23:47:50 +08:00
parent 00a005e65f
commit 2670340af3
47 changed files with 3909 additions and 257 deletions

View File

@@ -204,7 +204,8 @@ const dataRules = ref({
{ required: true, message: '学院不能为空', trigger: 'change' }
],
classCode: [
{ required: true, message: '班级代码不能为空', trigger: 'blur' }
{ required: true, message: '班级代码不能为空', trigger: 'blur' },
{ min: 4, message: '班级代码至少4位班号取后4位', trigger: 'blur' }
],
classNo: [
{ required: true, message: '班号不能为空', trigger: 'blur' }
@@ -406,11 +407,11 @@ watch(() => form.enterDate, (newVal) => {
}
})
// 监听班级代码,取后四位为班号
// 监听班级代码,取后四位为班号班级代码至少4位
watch(() => form.classCode, (newVal) => {
if (newVal) {
const length = newVal.length
if (length > 4) {
if (length >= 4) {
// 只在新增模式下自动填充班号,编辑模式下如果班号为空才填充
if (!form.id || !form.classNo) {
form.classNo = newVal.substring(length - 4, length)

View File

@@ -196,7 +196,7 @@
</el-tag>
</template>
</el-table-column>
<el-table-column label="操作" align="center" fixed="right" width="200">
<el-table-column label="操作" align="center" fixed="right" width="260">
<template #default="scope">
<el-button
icon="View"