Skip to content

Commit dcac965

Browse files
Merge pull request #440 from demonray/dev-1.0.1
Support open external link
2 parents 07e19ac + 7fa348a commit dcac965

File tree

1 file changed

+17
-2
lines changed
  • web/src/apps/workflows/view/workflow

1 file changed

+17
-2
lines changed

web/src/apps/workflows/view/workflow/index.vue

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,8 @@
5454
</template>
5555
</template>
5656
<template v-else>
57-
<!-- 其他应用流程 -->
57+
<!-- 其他应用流程 -->
58+
<iframe id="iframe" :src="srcUrl" frameborder="0" width="100%" height="100%"></iframe>
5859
</template>
5960
</WorkflowTabList>
6061
<ProjectForm
@@ -85,6 +86,7 @@ import MakeUp from '@/apps/workflows/module/makeUp'
8586
import ProjectForm from '@/components/projectForm/index.js'
8687
import api from '@/common/service/api';
8788
import mixin from '@/common/service/mixin';
89+
import util from '@/common/util/index.js';
8890
import commonModule from "@/apps/workflows/module/common";
8991
import { DEVPROCESS, ORCHESTRATORMODES } from '@/common/config/const.js';
9092
import { GetDicSecondList, GetAreaMap } from '@/common/service/apiCommonMethod.js';
@@ -154,6 +156,19 @@ export default {
154156
}
155157
}
156158
},
159+
computed: {
160+
srcUrl() {
161+
const url = ''
162+
const found = this.selectDevprocess.find((item) => this.modeOfKey === item.dicValue)
163+
if (found) {
164+
const {projectName, projectId} = this.$route.query
165+
const workspaceId = this.getCurrentWorkspaceId()
166+
const workspaceName = this.getCurrentWorkspaceName()
167+
url = util.replaceHolder(found.url, { workspaceId, workspaceName, projectId, projectName })
168+
}
169+
return url
170+
}
171+
},
157172
created() {
158173
this.getAreaMap();
159174
this.getDicSecondList();
@@ -180,7 +195,7 @@ export default {
180195
},
181196
// 获取当前选择的开发流程
182197
getSelectDevProcess() {
183-
this.selectDevprocess = this.devProcessBase ? this.devProcessBase.filter((item) => this.currentProjectData.devProcessList.includes(item.dicValue)) : []
198+
this.selectDevprocess = this.devProcessBase || []
184199
},
185200
// 获取编排列表
186201
getSelectOrchestratorList() {

0 commit comments

Comments
 (0)