Commit 0536833b by 史敦盼

中台修改

1 parent c306a069
...@@ -39,4 +39,8 @@ export function qryStatDetPage(data) { ...@@ -39,4 +39,8 @@ export function qryStatDetPage(data) {
// 查询关联资产回显 // 查询关联资产回显
export function qryAssetsPage(data) { export function qryAssetsPage(data) {
return post(EADC_ARRCHITECTURE + "/arc-aby-ast/qryAssetsPage", data); return post(EADC_ARRCHITECTURE + "/arc-aby-ast/qryAssetsPage", data);
}
// 中台服务清单列表,不分页
export function comCenterServeQryAll(data) {
return post(EADC_ARRCHITECTURE + "/arc-aby-iy/qryAll", data);
} }
\ No newline at end of file
...@@ -396,14 +396,14 @@ export default { ...@@ -396,14 +396,14 @@ export default {
// }, // },
{ {
label: "业务对象名称", label: "业务对象名称",
prop: "buildType2", prop: "assetName",
minWidth: 120, minWidth: 120,
showOverflowTooltip: true, showOverflowTooltip: true,
align: "center", align: "center",
}, },
{ {
label: "业务对象编码", label: "业务对象编码",
prop: "buildType2", prop: "assetNumber",
minWidth: 120, minWidth: 120,
showOverflowTooltip: true, showOverflowTooltip: true,
align: "center", align: "center",
...@@ -414,6 +414,9 @@ export default { ...@@ -414,6 +414,9 @@ export default {
minWidth: 120, minWidth: 120,
showOverflowTooltip: true, showOverflowTooltip: true,
align: "center", align: "center",
render: (h, params) => {
return h("span", {}, this.handleName(params.parentAssetNames, 0) || '--');
},
}, },
{ {
label: "业务职能", label: "业务职能",
...@@ -421,6 +424,9 @@ export default { ...@@ -421,6 +424,9 @@ export default {
minWidth: 120, minWidth: 120,
showOverflowTooltip: true, showOverflowTooltip: true,
align: "center", align: "center",
render: (h, params) => {
return h("span", {}, this.handleName(params.parentAssetNames, 1) || '--');
},
}, },
{ {
label: "业务域", label: "业务域",
...@@ -428,6 +434,9 @@ export default { ...@@ -428,6 +434,9 @@ export default {
minWidth: 120, minWidth: 120,
showOverflowTooltip: true, showOverflowTooltip: true,
align: "center", align: "center",
render: (h, params) => {
return h("span", {}, this.handleName(params.parentAssetNames, 2) || '--');
},
}, },
], ],
getList() { getList() {
...@@ -455,14 +464,14 @@ export default { ...@@ -455,14 +464,14 @@ export default {
// }, // },
{ {
label: "应用服务名称", label: "应用服务名称",
prop: "buildType2", prop: "assetName",
minWidth: 120, minWidth: 120,
showOverflowTooltip: true, showOverflowTooltip: true,
align: "center", align: "center",
}, },
{ {
label: "应用服务编码", label: "应用服务编码",
prop: "buildType2", prop: "assetNumber",
minWidth: 120, minWidth: 120,
showOverflowTooltip: true, showOverflowTooltip: true,
align: "center", align: "center",
...@@ -741,6 +750,16 @@ export default { ...@@ -741,6 +750,16 @@ export default {
} }
}, },
methods: { methods: {
handleName(name,idx) {
let strArr = ['', '', '']
if(name) {
let str = name.split(',')
strArr[0] = str[str.length - 3]
strArr[1] = str[str.length - 2]
strArr[2] = str[str.length - 1]
}
return strArr[idx]
},
getQryStatDetPage(inventoryEnum, archiTypeId, archiType) { getQryStatDetPage(inventoryEnum, archiTypeId, archiType) {
const params = { const params = {
inventoryId: this.row.row.inventoryEnum, inventoryId: this.row.row.inventoryEnum,
......
...@@ -56,11 +56,11 @@ ...@@ -56,11 +56,11 @@
</el-col> </el-col>
</el-row> </el-row>
</el-form> </el-form>
<el-table-column slot="end" fixed="right" label="操作" align="center" :width="120"> <el-table-column slot="end" fixed="right" label="操作" align="center" :width="200">
<template slot-scope="scope"> <template slot-scope="scope">
<div class="btns"> <div class="btns">
<img src="@/assets/btn1.jpg" style="cursor: pointer" width="26" height="26" <img v-for="(item, idx) in btns" :key="idx" :src="item.url" style="cursor: pointer" width="26" height="26"
@click="concatService(scope.row)" alt=""> @click="concatService(scope.row, item.archiType)" alt="">
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
...@@ -72,7 +72,7 @@ ...@@ -72,7 +72,7 @@
<el-row class="comDialogContent"> <el-row class="comDialogContent">
<el-col :span="12"> <el-col :span="12">
<div style="height: 400px;overflow-y:auto"> <div style="height: 400px;overflow-y:auto">
<el-tree ref="tree" :data="treeData" show-checkbox check-on-click-node node-key="assetId" default-expand-all :props="treeProps" <el-tree ref="tree" :data="treeData" show-checkbox check-on-click-node :node-key="handleNodeKey" default-expand-all :props="treeProps"
@check-change="checkChange"> @check-change="checkChange">
</el-tree> </el-tree>
</div> </div>
...@@ -95,7 +95,7 @@ ...@@ -95,7 +95,7 @@
</template> </template>
<script> <script>
import { stateOptions, serverTypeOptions, abilitySourceOptions, midGroundNameOptions, midGroundTypeOptions } from '../options.js' import { stateOptions, serverTypeOptions, abilitySourceOptions, midGroundNameOptions, midGroundTypeOptions } from '../options.js'
import { getServiceList, correlationSave, qryAssetsPage } from '@/api/comCenterServeListNew' import { getServiceList, correlationSave, qryAssetsPage, comCenterServeQryAll } from '@/api/comCenterServeListNew'
import EditService from './editService.vue' import EditService from './editService.vue'
import ETable from "@/newComponents/ETable/index.vue"; import ETable from "@/newComponents/ETable/index.vue";
import tableMixin from "@/mixins/tableMixin"; import tableMixin from "@/mixins/tableMixin";
...@@ -396,19 +396,90 @@ export default { ...@@ -396,19 +396,90 @@ export default {
}, },
], ],
// dialogData: [] // dialogData: []
btns: [{
url: require('@/assets/comCenterServe/btn1.png'),
archiType: 1
},{
url: require('@/assets/comCenterServe/btn2.png'),
archiType: 2
},{
url: require('@/assets/comCenterServe/btn3.png'),
archiType: 3
},{
url: require('@/assets/comCenterServe/btn4.png'),
archiType: 4
},{
url: require('@/assets/comCenterServe/btn5.png'),
archiType: 6
}],
operationArchiType: null
}; };
}, },
computed: {
handleNodeKey() {
if(this.operationArchiType === 6) {
return 'inventoryId'
} else {
return 'assetId'
}
},
handleTreeProps() {
if(this.operationArchiType === 6) {
return {
children: 'children',
label: 'abilityName'
}
} else {
return {
children: 'children',
label: 'assetName'
}
}
}
},
mounted() { mounted() {
this.disabledTreeNode(this.treeData) this.disabledTreeNode(this.treeData)
this.getList() this.getList()
}, },
methods: { methods: {
handleOpen() { handleOpen() {
this.getTreeData() if(this.operationArchiType === 6) {
comCenterServeQryAll().then(res => {
if(res.code === 200) {
this.treeData = res.data
}
})
} else {
this.getTreeData()
}
},
getArchiTypeCode(info) {
let archiType = ''
switch (info) {
case 5:
archiType = 'ARCHI_SAFE'
break
case 4:
archiType = 'ARCHI_TECHNOLOGY'
break
case 3:
archiType = 'ARCHI_DATA'
break
case 2:
archiType = 'ARCHI_APPLICATION'
break
case 1:
archiType = 'ARCHI_BUSINESS'
break
}
return archiType
}, },
getTreeData() { getTreeData() {
const params = { const params = {
archiType: 'ARCHI_BUSINESS', archiType: this.getArchiTypeCode(this.operationArchiType),
archiAssetState: 2, archiAssetState: 2,
archiStage: 1, archiStage: 1,
} }
...@@ -422,7 +493,9 @@ export default { ...@@ -422,7 +493,9 @@ export default {
getQryAssetsPage() { getQryAssetsPage() {
const { inventoryId } = this.dialogRow const { inventoryId } = this.dialogRow
const params = { const params = {
inventoryId inventoryId,
archiTypeId: this.operationArchiType,
archiType: this.getArchiType(this.operationArchiType)
} }
qryAssetsPage(params).then(res => { qryAssetsPage(params).then(res => {
if(res.code === 200) { if(res.code === 200) {
...@@ -431,7 +504,8 @@ export default { ...@@ -431,7 +504,8 @@ export default {
} }
}) })
}, },
concatService(row) { concatService(row, type) {
this.operationArchiType = type
this.dialogRow = { ...row } this.dialogRow = { ...row }
console.log("编辑", row); console.log("编辑", row);
this.title = '关联业务' this.title = '关联业务'
...@@ -453,7 +527,7 @@ export default { ...@@ -453,7 +527,7 @@ export default {
// console.log('checkChange', node, checked); // console.log('checkChange', node, checked);
// console.log('checkedNodes', this.$refs.tree.getCheckedNodes()) // console.log('checkedNodes', this.$refs.tree.getCheckedNodes())
this.dialogData = this.$refs.tree.getCheckedNodes() this.dialogData = this.$refs.tree.getCheckedNodes()
this.dialogData = this.dialogData.filter(v => v.parentAssetId != '0') this.dialogData = this.dialogData.filter(v => !v.children || !v.children.length )
}, },
close() { close() {
this.dialogData = [] this.dialogData = []
...@@ -474,8 +548,8 @@ export default { ...@@ -474,8 +548,8 @@ export default {
abilityName, abilityName,
assetId: v.assetId, assetId: v.assetId,
assetName: v.assetName, assetName: v.assetName,
archiType: this.getArchiType(v.archiAssetType), archiType: this.getArchiType(this.operationArchiType),
archiTypeId: v.archiAssetType, archiTypeId: this.operationArchiType,
eleName: v.eleName, eleName: v.eleName,
parentAssetIds: v.parentAssetId, parentAssetIds: v.parentAssetId,
parentAssetNames: v.parentAssetName, parentAssetNames: v.parentAssetName,
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!