Commit 4606323f by liuyong

修改bug

1 parent 89c21da4
...@@ -213,13 +213,13 @@ const leftCustomGraph = function(that) {//左侧自定义图形 ...@@ -213,13 +213,13 @@ const leftCustomGraph = function(that) {//左侧自定义图形
} }
}) })
}else { }else {
joinGraph.forEach(item => { // joinGraph.forEach(item => {
item.subList.forEach(item2 => { // item.subList.forEach(item2 => {
if(item2.eleType == '1') { // if(item2.eleType == '1') {
console.log(item2) // console.log(item2)
} // }
}) // })
}) // })
} }
} }
......
...@@ -49,25 +49,42 @@ ...@@ -49,25 +49,42 @@
joinGraph.forEach(item => { joinGraph.forEach(item => {
let fns = []; let fns = [];
if(item.arciBelongName == '架构元素关系') {
item.subList.forEach(item2 => { item.eleDtos.forEach(item2 => {
if(item2.eleType == '2' && item2.iconName && item2.color) {
fns.push( fns.push(
this.createVertexTemplateEntry( this.createEdgeTemplateEntry(
item2.iconName + ';fillColor=' + item2.color + ';' + 'attr=[];' + 'assetId=' + item2.assetId + ';' + 'archiBelongId=' + item2.archiBelongId + ';', item2.iconName + 'attr=[]',
150, item2.shapeWidth ? item2.shapeWidth : 150,
75, item2.shapeHeight ? item2.shapeHeight : 75,
null, '',
item2.assetName, item2.elementName,
null, null,
null, '非封闭图形2'
'封闭图形2'
) )
) )
} });
}) }else {
item.eleDtos.forEach(item2 => {
if(item2.assets) {
item2.assets.forEach(item3 => {
fns.push(
this.createVertexTemplateEntry(
item2.iconName + ';fillColor=' + item2.color + ';' + 'attr=[]' + ';assetId=' + item3.assetId + ';archiBelongId=' + item3.archiBelongId + ';',
item2.shapeWidth ? item2.shapeWidth : 150,
item2.shapeHeight ? item2.shapeHeight : 75,
null,
item3.assetName,
null,
null,
'封闭图形2'
)
)
})
}
});
}
this.addPaletteFunctions(item.assetId, item.assetName, false, fns); this.addPaletteFunctions(item.arciBelongId, item.arciBelongName, true, fns);
}); });
} }
}; };
......
...@@ -453,7 +453,7 @@ export function evoluteFunAndLineAdd(params) { ...@@ -453,7 +453,7 @@ export function evoluteFunAndLineAdd(params) {
} }
// 架构视图左侧图元 // 架构视图左侧图元
export function queryArchiGraph(params) { export function queryArchiGraph(params) {
return post('/network/arc-ast-cn/fiveAssetTree', params); return post('/network/ma-ml/archi-asset-list', params);
} }
// 元模型字典管理表格 // 元模型字典管理表格
export function queryCircleModelDicyTable(params) { export function queryCircleModelDicyTable(params) {
...@@ -486,4 +486,8 @@ export function dicyUpdateTableEdit(params) { ...@@ -486,4 +486,8 @@ export function dicyUpdateTableEdit(params) {
// 元模型字典管理,字典维护列表的删除 // 元模型字典管理,字典维护列表的删除
export function dicyUpdateTableDelete(params) { export function dicyUpdateTableDelete(params) {
return post('/network/archi-model-dict-detail/del', params); return post('/network/archi-model-dict-detail/del', params);
}
// 架构视图管理,清单列表
export function queryViewManageQingDan(params) {
return post('/network/ma-ml/asset-ele-list', params);
} }
\ No newline at end of file
...@@ -4,9 +4,24 @@ ...@@ -4,9 +4,24 @@
<Drawio :initGraphId="routerId"></Drawio> <Drawio :initGraphId="routerId"></Drawio>
</div> </div>
<div class="right_graph_container"> <div class="right_graph_container">
<el-card style="width: 100%;height: 100%;">
<div style="text-align: left;">
<span>清单目录</span>
</div>
<div style="display: flex;align-items: center;">
<el-divider direction="vertical" class="divider1"></el-divider>
<div>目录</div>
<el-divider class="divider2"></el-divider>
</div>
<el-table :data="tableData" stripe border height='500'>
<el-table-column type="index" label="序号" width="50" align="center"></el-table-column>
<el-table-column prop="assetName" label="资产名称" align="center"></el-table-column>
</el-table>
<div style="text-align: right;">
<el-button type="text" @click="toBusiAssetslist">更多<i class="el-icon-arrow-right"></i></el-button>
</div>
</el-card>
</div> </div>
<el-dialog <el-dialog
title="属性关联" title="属性关联"
:visible.sync="graph_dialog" :visible.sync="graph_dialog"
...@@ -57,6 +72,7 @@ ...@@ -57,6 +72,7 @@
saveArchiViewManageCardDetails, saveArchiViewManageCardDetails,
saveVersionArchiViewManageCardDetails, saveVersionArchiViewManageCardDetails,
save_drawio_attribute, save_drawio_attribute,
queryViewManageQingDan
} from '@/api/index.js'; } from '@/api/index.js';
import $ from 'jquery'; import $ from 'jquery';
...@@ -67,6 +83,7 @@ ...@@ -67,6 +83,7 @@
}, },
data() { data() {
return { return {
tableData: [],
routerId: null, routerId: null,
graph_dialog: false, graph_dialog: false,
nameIndex: 0, nameIndex: 0,
...@@ -78,6 +95,7 @@ ...@@ -78,6 +95,7 @@
}; };
}, },
mounted(){ mounted(){
this.getQingDanTable();
this.get_search_select1(); this.get_search_select1();
const id = this.$route.query.id; const id = this.$route.query.id;
...@@ -134,15 +152,31 @@ ...@@ -134,15 +152,31 @@
} }
}, },
methods: { methods: {
toBusiAssetslist() {
this.$router.push( `/main/busiAssetslist`, () => {}, () => {} );
},
getQingDanTable() {
const params = {
archiViewId: this.$route.query.viewId,
assetConstant: this.$route.query.assetConstant,
}
queryViewManageQingDan(params).then(res => {
if(res.code == 200) {
this.tableData = res.data;
}else {
Message({
type: 'error',
message: res.msg
});
}
})
},
openDrawer() { openDrawer() {
if(this.status == 1) { if(this.status == 1) {
$(".left_graph_container").animate({ width: "85%" }, 300, 'linear', function() { $(".right_graph_container").animate({ right: "0%" }, 200, 'linear');
$(".right_graph_container").css('display', 'block');
});
this.status = 2; this.status = 2;
}else{ }else{
$(".left_graph_container").animate({ width: "100%" }, 300, 'linear'); $(".right_graph_container").animate({ right: "-15%" }, 200, 'linear');
$(".right_graph_container").css('display', 'none');
this.status = 1; this.status = 1;
} }
}, },
...@@ -263,19 +297,35 @@ ...@@ -263,19 +297,35 @@
} }
</style> </style>
<style scoped> <style scoped>
.el-button--text{
color: #0D867F;
}
.divider1{
width: 6px;
margin-right: 6px;
background-color: #0D867F;
}
.divider2{
margin-left: 6px;
width: 74%;
}
.left_graph_container{ .left_graph_container{
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
.right_graph_container{ .right_graph_container{
width: 15%; width: 265px;
height: 100%; height: 100%;
display: none; position: absolute;
right: -15%;
top: 0;
background-color: rgba(256, 256, 256, 1);
} }
.canvas{ .canvas{
width: 100%; width: 100%;
height: 100%; height: 100%;
display: flex; display: flex;
position: relative;
} }
/deep/ .el-dialog__header{ /deep/ .el-dialog__header{
background-color: #0D867F; background-color: #0D867F;
......
...@@ -198,6 +198,7 @@ export default { ...@@ -198,6 +198,7 @@ export default {
}, },
addStatus: null, addStatus: null,
graphGroup: null, graphGroup: null,
assetConstant: null,
}; };
}, },
mounted(){ mounted(){
...@@ -439,15 +440,19 @@ export default { ...@@ -439,15 +440,19 @@ export default {
Promise.all([ this.queryDrawioGraph(id), this.queryDrawioGraph2(id), this.getArchiGraph() ]).then(res2 => { Promise.all([ this.queryDrawioGraph(id), this.queryDrawioGraph2(id), this.getArchiGraph() ]).then(res2 => {
localStorage.setItem('commonGraph', JSON.stringify({ show: true, graph: res2[0].dataEle })); localStorage.setItem('commonGraph', JSON.stringify({ show: true, graph: res2[0].dataEle }));
localStorage.setItem('standardGraph', JSON.stringify({ show: true, graph: res2[1].dataEle })); localStorage.setItem('standardGraph', JSON.stringify({ show: true, graph: res2[1].dataEle }));
localStorage.setItem('joinGraph', JSON.stringify({ state: 2, graph: res2[2] })); localStorage.setItem('joinGraph', JSON.stringify({ state: 2, graph: res2[2].dataEle }));
this.$router.push( `/main/archiViewManageDetails?id=${id}&info=${this.graphGroup}`, () => {}, () => {} ); this.$router.push( `/main/archiViewManageDetails?id=${id}&info=${this.graphGroup}&viewId=${this.viewId}&assetConstant=${this.assetConstant}`, () => {}, () => {} );
}); });
} }
}); });
}, },
getArchiGraph() {//查询综合图 getArchiGraph() {//查询综合图
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
queryArchiGraph({}).then(res => { const params = {
archiBelongId: this.graphGroup,
assetConstant: this.assetConstant,
}
queryArchiGraph(params).then(res => {
if(res.code == 200) { if(res.code == 200) {
resolve(res.data); resolve(res.data);
}else { }else {
...@@ -463,6 +468,7 @@ export default { ...@@ -463,6 +468,7 @@ export default {
treeClick(data, node, e) {//树点击的时候 treeClick(data, node, e) {//树点击的时候
if(!data.subList) { if(!data.subList) {
this.graphGroup = node.parent.data.viewId; this.graphGroup = node.parent.data.viewId;
this.assetConstant = node.parent.data.archiType;
this.viewId = data.viewId; this.viewId = data.viewId;
this.pager1.current = 1; this.pager1.current = 1;
this.pager2.current = 1; this.pager2.current = 1;
...@@ -487,6 +493,7 @@ export default { ...@@ -487,6 +493,7 @@ export default {
getArchiViewManage(params).then(res => { getArchiViewManage(params).then(res => {
if(res.code == 200) { if(res.code == 200) {
this.graphGroup = res.data[0].viewId; this.graphGroup = res.data[0].viewId;
this.assetConstant = res.data[0].archiType;
this.treeData[0].subList = res.data; this.treeData[0].subList = res.data;
this.treeDefaultExpand = [res.data[0].viewId]; this.treeDefaultExpand = [res.data[0].viewId];
this.currentNodekey = res.data[0].subList[0].viewId; this.currentNodekey = res.data[0].subList[0].viewId;
......
...@@ -8,6 +8,12 @@ ...@@ -8,6 +8,12 @@
<el-input v-model="params.viewName" placeholder="请输入内容" class="search_item"></el-input> <el-input v-model="params.viewName" placeholder="请输入内容" class="search_item"></el-input>
</div> </div>
<div class="search_menu_item"> <div class="search_menu_item">
<span class="search_title">架构大类</span>
<el-select v-model="params.let1" placeholder="请选择" clearable class="search_item">
<el-option v-for="(item,idnex) in levelList" :key="idnex" :label="item.name" :value="item.levelId" ></el-option>
</el-select>
</div>
<div class="search_menu_item">
<span class="search_title">架构层次</span> <span class="search_title">架构层次</span>
<el-select v-model="params.archiLevelId" placeholder="请选择" clearable class="search_item"> <el-select v-model="params.archiLevelId" placeholder="请选择" clearable class="search_item">
<el-option v-for="(item,idnex) in levelList" :key="idnex" :label="item.name" :value="item.levelId" ></el-option> <el-option v-for="(item,idnex) in levelList" :key="idnex" :label="item.name" :value="item.levelId" ></el-option>
...@@ -19,6 +25,14 @@ ...@@ -19,6 +25,14 @@
<el-option v-for="(item,idnex) in belongList" :key="idnex" :label="item.name" :value="item.belongId" ></el-option> <el-option v-for="(item,idnex) in belongList" :key="idnex" :label="item.name" :value="item.belongId" ></el-option>
</el-select> </el-select>
</div> </div>
<div class="search_menu_item">
<span class="search_title">状态</span>
<el-select v-model="params.state" clearable placeholder="请选择" class="search_item">
<el-option label="已发布" value="1"></el-option>
<el-option label="已停用" value="0"></el-option>
<el-option label="暂存" value="2"></el-option>
</el-select>
</div>
</div> </div>
<div class="search_menu_btn_container"> <div class="search_menu_btn_container">
<div class="query_btn" @click="getList"> <div class="query_btn" @click="getList">
...@@ -41,7 +55,7 @@ ...@@ -41,7 +55,7 @@
<p>版本发布</p> <p>版本发布</p>
</div> </div>
</div> </div>
<el-table :data="tableData" stripe border @selection-change="handleSelectionChange" height="450"> <el-table :data="tableData" stripe border @selection-change="handleSelectionChange" :height="tableHeight">
<el-table-column type="selection" width="55" :selectable="selectInit"></el-table-column> <el-table-column type="selection" width="55" :selectable="selectInit"></el-table-column>
<el-table-column type="index" label="序号" width="80" align="center"></el-table-column> <el-table-column type="index" label="序号" width="80" align="center"></el-table-column>
<el-table-column prop="viewName" label="架构视图名称" width="150" align="center"></el-table-column> <el-table-column prop="viewName" label="架构视图名称" width="150" align="center"></el-table-column>
...@@ -237,6 +251,7 @@ import { ...@@ -237,6 +251,7 @@ import {
getYMXZDGLProyDel getYMXZDGLProyDel
} from "@/api/index.js"; } from "@/api/index.js";
import { MessageBox, Message } from 'element-ui'; import { MessageBox, Message } from 'element-ui';
import $ from 'jquery';
export default { export default {
name: 'archiViewConfig', name: 'archiViewConfig',
...@@ -312,6 +327,8 @@ export default { ...@@ -312,6 +327,8 @@ export default {
viewName: "", viewName: "",
archiLevelId: "", archiLevelId: "",
archiBelongId: "", archiBelongId: "",
let1: null,
state: null,
}, },
page: { page: {
current: 1, current: 1,
...@@ -354,12 +371,15 @@ export default { ...@@ -354,12 +371,15 @@ export default {
selectData2: [], selectData2: [],
selectData3: [], selectData3: [],
selectData4: [], selectData4: [],
tableHeight: null,
}; };
}, },
mounted() { mounted() {
}, window.addEventListener('resize', () => {
created() { this.set_table_height();
})
this.set_table_height();
// 获取下拉 // 获取下拉
this.getLevelList(); this.getLevelList();
this.getBelongList(); this.getBelongList();
...@@ -373,9 +393,18 @@ export default { ...@@ -373,9 +393,18 @@ export default {
// 获取元素和元素关系列表 // 获取元素和元素关系列表
this.getEleList(); this.getEleList();
this.gtEleRelList(); this.gtEleRelList();
},
created() {
}, },
methods: { methods: {
set_table_height() {//动态设置表格高度
const table_container_height = $(".table_container").height();
const search_menu_height = $(".search_menu").height();
const search_btn_height = $(".search_btn").outerHeight(true);
this.tableHeight = table_container_height - search_menu_height - search_btn_height - 90 + 'px';
},
queryAllKey() {//查询控件右边的下拉框值 queryAllKey() {//查询控件右边的下拉框值
gAllDictKey().then(res => { gAllDictKey().then(res => {
this.controlValueSelect = res.data; this.controlValueSelect = res.data;
...@@ -571,7 +600,7 @@ export default { ...@@ -571,7 +600,7 @@ export default {
pageSize: 10, pageSize: 10,
rsName: "", rsName: "",
scope: "", scope: "",
state: "", state: null,
} }
}, },
// 分页事件 // 分页事件
...@@ -869,6 +898,10 @@ export default { ...@@ -869,6 +898,10 @@ export default {
align-items: center; align-items: center;
width: 33%; width: 33%;
} }
.tingYong_btn{
color: #DEA82A;
background-color: #FDF6E6;
}
.shanChu_btn{ .shanChu_btn{
color: #DD6A15; color: #DD6A15;
background-color: #F8EBE2; background-color: #F8EBE2;
...@@ -932,15 +965,19 @@ export default { ...@@ -932,15 +965,19 @@ export default {
.search_menu_item_container{ .search_menu_item_container{
display: flex; display: flex;
align-items: center; align-items: center;
height: 60px;
width: 90%;
justify-content: space-between;
} }
.search_menu_btn_container{ .search_menu_btn_container{
display: flex; display: flex;
align-items: center; align-items: center;
width: 10%;
} }
.search_menu_item{ .search_menu_item{
display: flex; display: flex;
align-items: center; align-items: center;
width: 344px; // width: 344px;
} }
.search_title{ .search_title{
/* width: 20%; */ /* width: 20%; */
...@@ -1018,6 +1055,7 @@ export default { ...@@ -1018,6 +1055,7 @@ export default {
.table_container{ .table_container{
width: 97%; width: 97%;
margin-top: 20px; margin-top: 20px;
height: calc(100% - 40px);
.editBtn{ .editBtn{
color: #0D867F; color: #0D867F;
} }
......
...@@ -346,10 +346,6 @@ export default { ...@@ -346,10 +346,6 @@ export default {
display: flex; display: flex;
align-items: center; align-items: center;
} }
.search_menu_item_container{
display: flex;
align-items: center;
}
.search_menu_btn_container{ .search_menu_btn_container{
display: flex; display: flex;
align-items: center; align-items: center;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!