From aaa2a9ef163ee992f142466c87ee1aeea3651285 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=88=E8=A3=95=E8=B4=A2?= Date: Wed, 31 Jan 2024 18:12:10 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=B2=97=E4=BD=8D=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=E7=BB=B4=E6=8A=A4=E7=95=8C=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/mdp/sys/post/Form.vue | 36 ++++++++++++++++++++++----------- 1 file changed, 24 insertions(+), 12 deletions(-) diff --git a/src/views/mdp/sys/post/Form.vue b/src/views/mdp/sys/post/Form.vue index 6fed8d6..398011a 100644 --- a/src/views/mdp/sys/post/Form.vue +++ b/src/views/mdp/sys/post/Form.vue @@ -3,27 +3,28 @@ - - - + + + + - + - + - - + + - - + + @@ -60,8 +61,15 @@ export default { currOpType:'mng',//表单 add、edit,所有按钮可动、detail-只看不能操作 editFormRules: { id:[ - //{ required: true, message: '此项必填', trigger: 'change' }, - //{ min: 1,max: 200, message: '长度在1到200之间', trigger: 'change'} + //{ required: true, message: '此项必填', trigger: 'change' }, + { min: 1,max: 50, message: '长度在1到50之间', trigger: 'change'} + ], + postName:[ + { required: true, message: '此项必填', trigger: 'change' }, + { min: 1,max: 50, message: '长度在1到50之间', trigger: 'change'} + ], + remark:[ + { min: 1,max: 200, message: '长度在1到200之间', trigger: 'change'} ] }, editForm: { @@ -79,7 +87,11 @@ export default { methods: { //由组件扩展添加其它的初始页面的逻辑(mounted+onOpen都会调用此函数,建议只添加公共逻辑) initCurrData(){ - + if(this.currOpType=='add'){ + this.editForm.postLvl='1' + this.editForm.postType='1' + this.editForm.branchId=this.userInfo.branchId + } }, /** * 检查参数是否满足调用后台接口的条件