From ac1e76c9db2f33f07fe73b9b587a1bf0f56d7920 Mon Sep 17 00:00:00 2001
From: liuyg <376836862@qq.com>
Date: Wed, 25 Aug 2021 20:03:47 +0800
Subject: [PATCH] 修改bug
---
src/components/cardPopup/cardPopup.vue | 26 ++++++++++++++++++++------
1 files changed, 20 insertions(+), 6 deletions(-)
diff --git a/src/components/cardPopup/cardPopup.vue b/src/components/cardPopup/cardPopup.vue
index a725b6a..3318e41 100644
--- a/src/components/cardPopup/cardPopup.vue
+++ b/src/components/cardPopup/cardPopup.vue
@@ -32,15 +32,20 @@
></avue-form>
</el-collapse-item>
<el-collapse-item title="附件上传/查询" name="2">
- <attach :type="type"></attach>
+ <attach :type="imgType"></attach>
</el-collapse-item>
</el-collapse>
</div>
<div class="hand-next">
<el-button type="primary" @click="tip1up1">上一页</el-button>
- <el-button type="primary" @click="tip1">暂存</el-button>
- <el-button type="primary" @click="up()">提交审批</el-button>
+ <el-button type="primary" @click="tip1" :disabled="!canDoIt"
+ >暂存</el-button
+ >
+ <el-button type="primary" @click="up()" :disabled="!canDoIt">{{
+ //canDoIt ? "提交审批" : "已成功提交"
+ canDoIt ? "提交审批" : "提交审批"
+ }}</el-button>
<el-button type="info" @click="qx">取消</el-button>
</div>
</div>
@@ -63,6 +68,7 @@
see: false,
name: "",
type: "",
+ imgType: "",
apiName: [],
forms: 1,
data0: {},
@@ -77,18 +83,25 @@
};
},
computed: {
- ...mapGetters(["useWhere"]),
+ ...mapGetters(["useWhere", "canDoIt"]),
},
watch: {
useWhere() {
+ // console.log(this.canDoIt, "canDoIt");
for (var k in this.data) {
if (this.useWhere == this.data[k].type) {
this.see = true;
this.type = this.data[k].type;
+ this.imgType = this.data[k].imgType;
this.htmls = this.data[k].datas.htmls;
- this.option.column = this.data[k].datas.column;
+
this.apiName = this.data[k].datas.apiName;
this.name = this.data[k].menuName;
+ var d = this.data[k].datas.column;
+ for (var k in d) {
+ d[k]["disabled"] = !this.canDoIt;
+ }
+ this.option.column = d;
console.log("已选择type:" + this.useWhere + "--" + this.name);
this.convert();
}
@@ -101,7 +114,7 @@
methods: {
convert: function () {
var caridid = this.$store.getters.userInfo.Id;
- selectIn(this.apiName[2], caridid).then((res) => {
+ selectIn(this.apiName[2], caridid, this.type).then((res) => {
var d = res.data.data;
for (var k in d) {
this.obj0[k.toLowerCase()] = d[k];
@@ -159,6 +172,7 @@
message: "提交申请成功",
type: "success",
});
+ this.$store.commit("changecanDoIt", false);
});
},
tipover() {
--
Gitblit v1.9.3