|
@@ -1,19 +1,72 @@
|
|
|
<template>
|
|
<template>
|
|
|
<div>
|
|
<div>
|
|
|
- <el-button type="primary" @click="showData">测试</el-button>
|
|
|
|
|
- <!-- <div style="margin-left: 1%;padding-top: 1%;position: absolute;z-index: 1000;cursor: pointer;" @click="back">
|
|
|
|
|
|
|
+ <!-- <el-button type="primary" @click="showData">测试</el-button> -->
|
|
|
|
|
+ <div style="display: flex;margin-left: 1%;padding-top: 1%;position: absolute;z-index: 1000;cursor: pointer;justify-content: space-between;width: 98%;" @click="back">
|
|
|
<el-icon size="large"><Back /></el-icon>
|
|
<el-icon size="large"><Back /></el-icon>
|
|
|
- </div> -->
|
|
|
|
|
- <div style="height: 85vh;width: 20vw;position: absolute;float: right;z-index: 1000;right: 1%;top: 1%;border: 0.1px solid #dedfe0;border-radius: 6px;background-color: white;">
|
|
|
|
|
|
|
+ <el-button style="margin-left: auto;" type="danger" size="mini">删除</el-button>
|
|
|
|
|
+ <el-button style="margin-left: 1%;" type="primary" size="mini">保存</el-button>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <div v-if="nodeDeSer" style="height: 85vh;width: 20vw;position: absolute;float: right;z-index: 1000;right: 1%;top: 1%;border: 0.1px solid #dedfe0;border-radius: 6px;background-color: white;">
|
|
|
<div style="display: flex;margin-left: 3%;margin-top: 3%;align-items: center;justify-content: space-between;width: 95%;">
|
|
<div style="display: flex;margin-left: 3%;margin-top: 3%;align-items: center;justify-content: space-between;width: 95%;">
|
|
|
<el-tag class="ml-2" style="" type="warning">服务</el-tag>
|
|
<el-tag class="ml-2" style="" type="warning">服务</el-tag>
|
|
|
<div style="margin-left: 4%;">
|
|
<div style="margin-left: 4%;">
|
|
|
- 获取台风信息列表
|
|
|
|
|
|
|
+ {{servieName}}
|
|
|
</div>
|
|
</div>
|
|
|
- <el-icon style="margin-left: auto;"><Close /></el-icon>
|
|
|
|
|
|
|
+ <el-icon @click="nodeDeSer = false" style="margin-left: auto;cursor: pointer;"><Close /></el-icon>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <div style="display: flex;width: 90%;margin-left: 5%;margin-top:10%;align-items: center;justify-content: space-between;">
|
|
|
|
|
+ <el-input v-model="serviceUrl" style="width: 90%;" placeholder="Please input" disabled>
|
|
|
|
|
+ <template #prepend>
|
|
|
|
|
+ <div v-if="serviceRqtype==='GET'" style="color: #67C23A;background-color: transparent;">
|
|
|
|
|
+ GET
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <div v-if="serviceRqtype==='POST'" style="color: #409EFF;background-color: transparent;">
|
|
|
|
|
+ POST
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-input>
|
|
|
|
|
+ <svg-icon icon-class="startTest" style="margin-left: auto;width: 50px;height: 25px;cursor: pointer;"/>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <div style="display: flex;width: 90%;margin-left: 5%;margin-top:10%;align-items: center;justify-content: space-between;">
|
|
|
|
|
+ <el-table :data="tableDataCan" border style="width: 100%">
|
|
|
|
|
+ <el-table-column prop="paramCode" label="参数名" width="" />
|
|
|
|
|
+ <el-table-column prop="paramValue" label="参数值" width="">
|
|
|
|
|
+ <template #default="scope">
|
|
|
|
|
+ <div style="width: 100%;">
|
|
|
|
|
+ <el-input placeholder="" type="primary" class="noBor" v-model="scope.row.paramValue" size="mini" text style="margin-left: 0%;"></el-input>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ </el-table>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <div style="display: flex;width: 90%;margin-left: 5%;margin-top:10%;align-items: center;justify-content: space-between;">
|
|
|
|
|
+ <el-form ref="deptRef" :model="form" :rules="rules" label-width="80px" label-position="top">
|
|
|
|
|
+ <el-form-item label="BODY">
|
|
|
|
|
+ <!-- 单选 -->
|
|
|
|
|
+ <el-radio-group v-model="form.bodyType">
|
|
|
|
|
+ <el-radio value="none">none</el-radio>
|
|
|
|
|
+ <el-radio value="form-data">form-data</el-radio>
|
|
|
|
|
+ <el-radio value="x-www-form-urlencoded">x-www-form-urlencoded</el-radio>
|
|
|
|
|
+ <el-radio value="JSON">JSON</el-radio>
|
|
|
|
|
+ <el-radio value="raw">raw</el-radio>
|
|
|
|
|
+ </el-radio-group>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ <el-form-item label="失败处理">
|
|
|
|
|
+ <el-select v-model="form.errorPolicy" style="width: 50%">
|
|
|
|
|
+ <el-option label="报错" value="ABORT"></el-option>
|
|
|
|
|
+ <el-option label="忽视" value="IGNORE"></el-option>
|
|
|
|
|
+ <el-option label="重连" value="RETRY"></el-option>
|
|
|
|
|
+ </el-select>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ <el-form-item label="失败重连次数">
|
|
|
|
|
+ <el-input-number v-model="form.retryCount" :min="1" style="width: 50%" :max="30"/>
|
|
|
|
|
+ </el-form-item>
|
|
|
|
|
+ </el-form>
|
|
|
|
|
+ </div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
- <div style="display: flex;height: 85vh;width: 100%;padding-top: 1%;">
|
|
|
|
|
|
|
+ <div style="display: flex;height: 85vh;width: 100%;padding-top:2%;">
|
|
|
<div style="width: 20%;margin-left: 1%;overflow-y: auto;">
|
|
<div style="width: 20%;margin-left: 1%;overflow-y: auto;">
|
|
|
<el-tree :expand-on-click-node="false" ref="treeRef" :filter-node-method="filterNode" :current-node-key="currentNodeKey" class="treeLeft" :data="dataTree" @node-click="handleNodeClick" node-key="id" style="margin-left: 5%;margin-top: 5%;width: 90%;background-color: transparent;" default-expand-all :key="valueKet">
|
|
<el-tree :expand-on-click-node="false" ref="treeRef" :filter-node-method="filterNode" :current-node-key="currentNodeKey" class="treeLeft" :data="dataTree" @node-click="handleNodeClick" node-key="id" style="margin-left: 5%;margin-top: 5%;width: 90%;background-color: transparent;" default-expand-all :key="valueKet">
|
|
|
<template #default="{ node, data }">
|
|
<template #default="{ node, data }">
|
|
@@ -62,7 +115,7 @@
|
|
|
style="border: 0.5px solid #c8c9cc;border-radius: 6px;border-radius: 6px;min-height: 8vh;min-width: 13vw">
|
|
style="border: 0.5px solid #c8c9cc;border-radius: 6px;border-radius: 6px;min-height: 8vh;min-width: 13vw">
|
|
|
<div style='width:100%;font-size:10px;display:flex;align-items:flex-end;height: 10px;margin-top: 2%;justify-content: space-between;'>
|
|
<div style='width:100%;font-size:10px;display:flex;align-items:flex-end;height: 10px;margin-top: 2%;justify-content: space-between;'>
|
|
|
<img style="width: 15px;height:15px;border-radius: 12px;" src="@/assets/images/icon-HTTP.png" alt="">
|
|
<img style="width: 15px;height:15px;border-radius: 12px;" src="@/assets/images/icon-HTTP.png" alt="">
|
|
|
- <div style="margin-left:3%;font-weight: 500;width: 40%;">
|
|
|
|
|
|
|
+ <div style="margin-left:3%;font-weight: 500;">
|
|
|
{{ specialNodeProps.data.label }}
|
|
{{ specialNodeProps.data.label }}
|
|
|
</div>
|
|
</div>
|
|
|
<el-icon style="cursor: pointer;margin-left: auto;"><CaretRight /></el-icon>
|
|
<el-icon style="cursor: pointer;margin-left: auto;"><CaretRight /></el-icon>
|
|
@@ -144,16 +197,16 @@
|
|
|
<dynamic-map v-if="form.bodyType === 'x-www-form-urlencoded'" v-model="form.config.body"></dynamic-map>
|
|
<dynamic-map v-if="form.bodyType === 'x-www-form-urlencoded'" v-model="form.config.body"></dynamic-map>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
<el-row>
|
|
<el-row>
|
|
|
- <el-col :span="12">
|
|
|
|
|
|
|
+ <el-col :span="24">
|
|
|
<el-form-item label="失败处理">
|
|
<el-form-item label="失败处理">
|
|
|
- <el-select v-model="form.errorPolicy" style="width: 100px">
|
|
|
|
|
|
|
+ <el-select v-model="form.errorPolicy" style="width: 100%">
|
|
|
<el-option label="报错" value="ABORT"></el-option>
|
|
<el-option label="报错" value="ABORT"></el-option>
|
|
|
<el-option label="忽视" value="IGNORE"></el-option>
|
|
<el-option label="忽视" value="IGNORE"></el-option>
|
|
|
<el-option label="重连" value="RETRY"></el-option>
|
|
<el-option label="重连" value="RETRY"></el-option>
|
|
|
</el-select>
|
|
</el-select>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
</el-col>
|
|
</el-col>
|
|
|
- <el-col :span="12">
|
|
|
|
|
|
|
+ <el-col :span="24">
|
|
|
<el-form-item v-if="form.errorPolicy === 'RETRY'" label="失败重连次数">
|
|
<el-form-item v-if="form.errorPolicy === 'RETRY'" label="失败重连次数">
|
|
|
<el-input-number v-model="form.retryCount" :min="1" :max="30"/>
|
|
<el-input-number v-model="form.retryCount" :min="1" :max="30"/>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
@@ -176,7 +229,7 @@ import { onMounted, ref } from 'vue'
|
|
|
import {useVueFlow, VueFlow ,MarkerType } from '@vue-flow/core'
|
|
import {useVueFlow, VueFlow ,MarkerType } from '@vue-flow/core'
|
|
|
import SpecialNode from './components/SpecialNode.vue'
|
|
import SpecialNode from './components/SpecialNode.vue'
|
|
|
import SpecialEdge from './components/SpecialEdge.vue'
|
|
import SpecialEdge from './components/SpecialEdge.vue'
|
|
|
-import {getPtServiceList} from "@/api/service/info.js";
|
|
|
|
|
|
|
+import {getPtServiceList,getSerDe} from "@/api/service/info.js";
|
|
|
import {getModelList2} from "@/api/register/regCom.js";
|
|
import {getModelList2} from "@/api/register/regCom.js";
|
|
|
import {copyObject} from "@/utils/index.js";
|
|
import {copyObject} from "@/utils/index.js";
|
|
|
import {getWorkflowByModelId, saveWorkflow} from "@/api/standardization/workflow.js";
|
|
import {getWorkflowByModelId, saveWorkflow} from "@/api/standardization/workflow.js";
|
|
@@ -200,6 +253,11 @@ const {
|
|
|
removeEdges,
|
|
removeEdges,
|
|
|
} = useVueFlow()
|
|
} = useVueFlow()
|
|
|
snapToGrid.value = true
|
|
snapToGrid.value = true
|
|
|
|
|
+const servieName = ref()
|
|
|
|
|
+const serviceRqtype = ref()
|
|
|
|
|
+const serviceUrl = ref()
|
|
|
|
|
+const tableDataCan = ref()
|
|
|
|
|
+const nodeDeSer = ref(false)
|
|
|
const {proxy} = getCurrentInstance();
|
|
const {proxy} = getCurrentInstance();
|
|
|
const modelQueryParams = ref({
|
|
const modelQueryParams = ref({
|
|
|
name: undefined,
|
|
name: undefined,
|
|
@@ -263,13 +321,18 @@ function handleModelClick(mid) {
|
|
|
|
|
|
|
|
onNodeClick(({event, node}) => {
|
|
onNodeClick(({event, node}) => {
|
|
|
console.log(node)
|
|
console.log(node)
|
|
|
- // form.value = node.data
|
|
|
|
|
- open.value = true
|
|
|
|
|
- // title.value = node.data.label
|
|
|
|
|
- // nodeId.value = node.id
|
|
|
|
|
|
|
+ if(node.data.nodeType==='SERVICE'){
|
|
|
|
|
+ getSerDe(node.data.id).then(res=>{
|
|
|
|
|
+ servieName.value = res.data.ptService.name
|
|
|
|
|
+ tableDataCan.value = res.data.list
|
|
|
|
|
+ serviceUrl.value = res.data.ptService.url
|
|
|
|
|
+ dataReturn.value = res.data.returnList
|
|
|
|
|
+ })
|
|
|
|
|
+ nodeDeSer.value = true
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
-
|
|
|
|
|
const data = reactive({
|
|
const data = reactive({
|
|
|
form: {config: {}},
|
|
form: {config: {}},
|
|
|
queryParams: {
|
|
queryParams: {
|
|
@@ -405,10 +468,6 @@ const filterNode = (value, data) => {
|
|
|
return data.label.indexOf(value) !== -1;
|
|
return data.label.indexOf(value) !== -1;
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
-/** 节点单击事件 */
|
|
|
|
|
-function handleNodeClick(node,data,event) {
|
|
|
|
|
- console.log(data)
|
|
|
|
|
-}
|
|
|
|
|
|
|
|
|
|
/** 搜索按钮操作 */
|
|
/** 搜索按钮操作 */
|
|
|
function handleQuery() {
|
|
function handleQuery() {
|