From 3a97ce5b9dd472c3d0264d98bbf95cadc9b37849 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=AE=B8=E5=AE=8F=E6=9D=B0?= <1943105267@qq.com> Date: Tue, 4 Mar 2025 18:58:03 +0800 Subject: [PATCH] =?UTF-8?q?web=E8=B5=84=E4=BA=A7=E4=BC=81=E4=B8=9A?= =?UTF-8?q?=E7=AB=AF=E6=96=B0=E5=A2=9E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/components/myAssetsType/index.vue | 31 ++- src/views/unitPages/myAssets/index.vue | 286 ++++++++++++++------ 2 files changed, 231 insertions(+), 86 deletions(-) diff --git a/src/views/components/myAssetsType/index.vue b/src/views/components/myAssetsType/index.vue index d4896bf..b9b7cf6 100644 --- a/src/views/components/myAssetsType/index.vue +++ b/src/views/components/myAssetsType/index.vue @@ -3,7 +3,7 @@
- 基本信息 + 基本信息0
- + 取消 { + if (value.length == 0) { + callback(new Error("请填写")); + } else { + value.forEach((item) => { + for (let key in item) { + if (!item[key]) { + callback(new Error("填写项存在控制")); + } + } + }); + callback(); + } + }; //表单校验 var validateName = (rule, value, callback) => { if (!this.ruleForm.ywxttpwj && !this.ruleForm.ywxttpt) { @@ -5392,6 +5409,9 @@ export default { this.disabled = true; } } + if (this.pageType == "add") { + this.ruleForm.dwmc = this.nickName; + } }, methods: { // 获取详情 @@ -6027,11 +6047,12 @@ export default { this.loading = false; }); } else { + this.ruleForm.xzType = 1; assetUnitData("post", this.ruleForm).then((res) => { // console.log(res,"res"); this.loading = false; this.$modal.msgSuccess("新增成功"); - this.$router.go(-1); + this.$router.push({ name: this.name, params: this.queryData }); }); } } else { diff --git a/src/views/unitPages/myAssets/index.vue b/src/views/unitPages/myAssets/index.vue index 672791d..f4c3df0 100644 --- a/src/views/unitPages/myAssets/index.vue +++ b/src/views/unitPages/myAssets/index.vue @@ -3,11 +3,20 @@
- - - - + + + + - + - - + + - +
-
-