NEZ-2901 fix:Record rules查看Metric时展开隐藏开关保存Chart,隐藏开关未被覆盖

This commit is contained in:
zhangyu
2023-06-21 14:51:01 +08:00
parent 8e8a7efaaa
commit c256f7f44d
4 changed files with 28 additions and 10 deletions

View File

@@ -175,6 +175,7 @@ export default {
},
viewGraph () {
this.$refs.recordRulesQueryTab.viewGraph()
this.dropdownHandler(true)
},
dropdownHandler (show) {
if (!show) {

View File

@@ -65,6 +65,7 @@ export default {
historiesLength: 0
}
},
inject: ['option'],
props: {
meta2dId: {
require: true
@@ -81,10 +82,16 @@ export default {
undo () { // 撤销
getTopology(this.meta2dId).undo()
// getTopology(this.meta2dId).inactive()
if (this.option.map) {
getTopology(this.meta2dId).showMap()
}
bus.$emit('changeSelectPens', [])
},
redo () { // 重做
getTopology(this.meta2dId).redo()
if (this.option.map) {
getTopology(this.meta2dId).showMap()
}
// getTopology(this.meta2dId).inactive()
bus.$emit('changeSelectPens', [])
},

View File

@@ -131,6 +131,11 @@ import { globalStore } from '@meta2d/core'
export default {
name: 'meta2dMain',
mixins: [meta2dMainCalc, topoUtil],
provide () {
return {
option: this.option
}
},
props: {
meta2dId: {}, // 唯一id 不可重复
iconArray: {
@@ -160,6 +165,20 @@ export default {
default: true
},
},
data () {
return {
option: {
lineName: 'curve',
lineWidth: 1,
fromArrow: '',
toArrow: 'triangleSolid',
scale: 100,
grid: false,
rule: false,
map: false
},
}
},
computed: {
},
components: {

View File

@@ -98,18 +98,9 @@ import { deepClone, s8 } from '@meta2d/core'
import lineData from './js/defaultPenLineData'
export default {
name: 'topologyTopTool',
inject: ['option'],
data () {
return {
option: {
lineName: 'curve',
lineWidth: 1,
fromArrow: '',
toArrow: 'triangleSolid',
scale: 100,
grid: false,
rule: false,
map: false
},
dragstartFlag: false,
drawLineFlag: false,
scaleNum: 100,