From f18624902e52691fb2fcf2e547af790cdd8d82e6 Mon Sep 17 00:00:00 2001 From: liudianxin Date: Fri, 21 Aug 2020 18:48:22 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=91=E8=B5=84=E6=BA=90=E5=AD=97=E6=AE=B5?= =?UTF-8?q?=E8=87=AA=E5=8A=A8=E6=B7=BB=E5=8A=A0=EF=BC=8C=E6=A3=80=E6=B5=8B?= =?UTF-8?q?=E9=97=AD=E7=8E=AF=EF=BC=8C=E8=AE=A2=E5=8D=95=E5=88=97=E8=A1=A8?= =?UTF-8?q?=E7=AD=9B=E9=80=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/order-list/order-list-com.vue | 14 ++++--- src/components/shop-cloud/shop-cloud.vue | 4 +- .../process-design/edit.vue | 39 +++++++++++-------- .../process-design/index.vue | 39 +++++++++++-------- 4 files changed, 55 insertions(+), 41 deletions(-) diff --git a/src/components/order-list/order-list-com.vue b/src/components/order-list/order-list-com.vue index 8b92f04..f7a1ab1 100644 --- a/src/components/order-list/order-list-com.vue +++ b/src/components/order-list/order-list-com.vue @@ -127,7 +127,7 @@ export default { buttonList.forEach((item) => { item.state = false; }); - buttonList.unshift({ id: 0, name: "全部", state: false }); + buttonList.unshift({ id: 0, name: "全部", state: true }); buttonList.push({ id: "cloud", name: "云资源", state: false }); buttonList.push({ id: "app", name: "应用镜像", state: false }); this.buttonList = buttonList; @@ -147,6 +147,12 @@ export default { } this.buttonList[0].state = !this.buttonList[0].state; } + let i = this.buttonList.findIndex((item) => { + return item.state == true; + }); + if (i == -1) { + this.buttonList[0].state = true; + } this.pagination.page = 1; this.getData(); }, @@ -179,11 +185,7 @@ export default { } } }); - if (arr.length == 0) { - service = 1; - app = 1; - resource = 1; - } + // console.log(service, app, resource); let params = { select: this.search, page: this.pagination.page, diff --git a/src/components/shop-cloud/shop-cloud.vue b/src/components/shop-cloud/shop-cloud.vue index 037fa43..97fcef7 100644 --- a/src/components/shop-cloud/shop-cloud.vue +++ b/src/components/shop-cloud/shop-cloud.vue @@ -564,7 +564,7 @@ -