From c1f94aa7144520644fd304b7307087ef8293b520 Mon Sep 17 00:00:00 2001 From: xuyiming Date: Thu, 13 Aug 2020 15:15:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=81=E7=A8=8B=E7=AE=A1=E7=90=86=E8=B0=83?= =?UTF-8?q?=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../process-management/designer/index.vue | 29 +++++++++++++++---- 1 file changed, 23 insertions(+), 6 deletions(-) diff --git a/src/pages/workbench/component-center/process-management/designer/index.vue b/src/pages/workbench/component-center/process-management/designer/index.vue index c121282..87c1050 100644 --- a/src/pages/workbench/component-center/process-management/designer/index.vue +++ b/src/pages/workbench/component-center/process-management/designer/index.vue @@ -136,6 +136,7 @@ export default { (filter.states && filter.states.map((item) => item.value).join(",")) || "", + filter_by: filter.keyword, page: filter.page, page_size: filter.size, }; @@ -308,10 +309,10 @@ export default { this.dialogInfo.cancelText = "取消"; this.dialogInfo.sunbmitText = "发布"; this.dialogInfo.submit = () => { - console.log(`发布${item.name}`); + this.$router.push(`/fwzc/fwcs?process=${item.workflows_id}`); }; this.showDialog(); - }, // TODO: 发布流程 + }, cancelPublishItem(item) { this.dialogInfo.title = "提示"; this.dialogInfo.msg = `取消发布后,该流程服务将从服务超市下架,仅部署在工作区域${item.workarea_name}中,是否取消发布流程服务“${item.name}”?`; @@ -341,7 +342,7 @@ export default { console.log(`取消部署${item.name}`); }; this.showDialog(); - }, // TODO: 取消流程 + }, // TODO: 取消部署流程 copyItem(item) { this.copyTempItem = { ...item, @@ -355,13 +356,29 @@ export default { submitCopyProcess() { this.$refs.detail_form.validate((valid) => { if (valid) { - console.log(this.copyTempItem); - this.copyProcessHide(); + this.$http + .post("/apaas/serviceapp/v3/workflows/copy", { + id: this.copyTempItem.workflows_id, + name: this.copyTempItem.newName, + }) + .then(({ data }) => { + if (data.success === 1) { + this.$message.success(data.errMsg || "复制成功"); + this.copyProcessHide(); + this.refreshPage(); + } else { + this.$message.error(data.errMsg || "复制失败"); + } + }) + .catch((error) => { + console.log(error); + this.$message.error("复制失败"); + }); } else { return false; } }); - }, // TODO: 复制流程-确定 + }, deleteItem(item) { this.dialogInfo.title = "提示"; this.dialogInfo.msg = `您确定要删除流程服务“${item.name}”吗?`; -- 2.26.0