diff --git a/src/views/system/user/index.vue b/src/views/system/user/index.vue index bda1725..037aed2 100644 --- a/src/views/system/user/index.vue +++ b/src/views/system/user/index.vue @@ -234,10 +234,10 @@ - - + + - + @@ -258,12 +258,12 @@ >{{dict.label}} - - - - - - + + + + + + @@ -291,34 +291,13 @@ - - - -
将文件拖到此处,或点击上传
-
-
- 是否更新已经存在的用户数据 -
- 仅允许导入xls、xlsx格式文件。 - 下载模板 -
-
- -
+ @@ -331,12 +310,13 @@ import FormCol from "@/components/FormCol/index.vue"; import {$showColumns} from "@/utils/mixins"; import {calcBirthDay, calcFullYear} from "@/utils/date"; import {parseTime} from "@/utils/ruoyi"; +import ImportDialog from "@/components/ImportDialog/index.vue"; export default { name: "User", mixins: [$showColumns], dicts: ['sys_normal_disable', 'sys_user_sex', 'user_employ_status'], - components: {FormCol, Treeselect }, + components: {ImportDialog, FormCol, Treeselect }, data() { return { // 排序方式 @@ -418,10 +398,17 @@ export default { ], // 表单校验 rules: { + userNo: [ + { required: true, message: "工号不能为空", trigger: "blur" } + ], userName: [ { required: true, message: "用户名称不能为空", trigger: "blur" }, { min: 2, max: 20, message: '用户名称长度必须介于 2 和 20 之间', trigger: 'blur' } ], + phonenumber: [ + { required: true, message: "手机号码不能为空", trigger: "blur" }, + { pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/, message: "请输入正确的手机号码", trigger: "blur"} + ], deptId: [ { required: true, message: "归属部门不能为空", trigger: "blur" } ], @@ -434,19 +421,8 @@ export default { { pattern: /^[^<>"'|\\]+$/, message: "不能包含非法字符:< > \" ' \\\ |", trigger: "blur" } ], email: [ - { - type: "email", - message: "请输入正确的邮箱地址", - trigger: ["blur", "change"] - } + {type: "email", message: "请输入正确的邮箱地址", trigger: ["blur", "change"]} ], - phonenumber: [ - { - pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/, - message: "请输入正确的手机号码", - trigger: "blur" - } - ] } }; }, @@ -511,7 +487,7 @@ export default { // 表单重置 reset() { this.form = { - userId: undefined, + userId: null, deptId: undefined, userName: undefined, nickName: undefined, diff --git a/src/views/yh/price/index.vue b/src/views/yh/price/index.vue index 606faf5..fa4ca91 100644 --- a/src/views/yh/price/index.vue +++ b/src/views/yh/price/index.vue @@ -324,6 +324,7 @@ template-url="/yh/price/importTemplate" url="/yh/price/importData" @success="getList" + template-name="单价导入模板" />