forked from github/dataease
fix(视图): 修复设置默认时间后手动清除默认时间再复制视图显示数据依然是默认时间设置的数据
This commit is contained in:
parent
8cc8541bdb
commit
00864766c0
@ -350,6 +350,10 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
computed: {
|
computed: {
|
||||||
|
//首次加载且非编辑状态新复制的视图,使用外部filter
|
||||||
|
initLoad() {
|
||||||
|
return !(this.isEdit && this.currentCanvasNewId.includes(this.element.id)) && this.isFirstLoad
|
||||||
|
},
|
||||||
scaleCoefficient() {
|
scaleCoefficient() {
|
||||||
if (this.terminal === 'pc' && !this.mobileLayoutStatus) {
|
if (this.terminal === 'pc' && !this.mobileLayoutStatus) {
|
||||||
return 1.1
|
return 1.1
|
||||||
@ -396,7 +400,7 @@ export default {
|
|||||||
},
|
},
|
||||||
filter() {
|
filter() {
|
||||||
const filter = {}
|
const filter = {}
|
||||||
filter.filter = this.isFirstLoad ? this.filters : this.cfilters
|
filter.filter = this.initLoad ? this.filters : this.cfilters
|
||||||
filter.linkageFilters = this.element.linkageFilters
|
filter.linkageFilters = this.element.linkageFilters
|
||||||
filter.outerParamsFilters = this.element.outerParamsFilters
|
filter.outerParamsFilters = this.element.outerParamsFilters
|
||||||
filter.drill = this.drillClickDimensionList
|
filter.drill = this.drillClickDimensionList
|
||||||
@ -455,6 +459,7 @@ export default {
|
|||||||
return this.element.commonBackground && this.element.commonBackground.innerPadding || 0
|
return this.element.commonBackground && this.element.commonBackground.innerPadding || 0
|
||||||
},
|
},
|
||||||
...mapState([
|
...mapState([
|
||||||
|
'currentCanvasNewId',
|
||||||
'nowPanelTrackInfo',
|
'nowPanelTrackInfo',
|
||||||
'nowPanelJumpInfo',
|
'nowPanelJumpInfo',
|
||||||
'publicLinkStatus',
|
'publicLinkStatus',
|
||||||
|
@ -151,7 +151,8 @@ const data = {
|
|||||||
height: 0
|
height: 0
|
||||||
},
|
},
|
||||||
previewVisible: false,
|
previewVisible: false,
|
||||||
previewComponentData: []
|
previewComponentData: [],
|
||||||
|
currentCanvasNewId: []
|
||||||
},
|
},
|
||||||
mutations: {
|
mutations: {
|
||||||
...animation.mutations,
|
...animation.mutations,
|
||||||
@ -271,6 +272,7 @@ const data = {
|
|||||||
state.componentData.splice(index, 0, component)
|
state.componentData.splice(index, 0, component)
|
||||||
} else {
|
} else {
|
||||||
state.componentData.push(component)
|
state.componentData.push(component)
|
||||||
|
state.currentCanvasNewId.push(component.id)
|
||||||
}
|
}
|
||||||
this.commit('setCurComponent', { component: component, index: index || state.componentData.length - 1 })
|
this.commit('setCurComponent', { component: component, index: index || state.componentData.length - 1 })
|
||||||
},
|
},
|
||||||
@ -749,6 +751,7 @@ const data = {
|
|||||||
this.commit('clearLinkageSettingInfo', false)
|
this.commit('clearLinkageSettingInfo', false)
|
||||||
this.commit('resetViewEditInfo')
|
this.commit('resetViewEditInfo')
|
||||||
this.commit('initCurMultiplexingComponents')
|
this.commit('initCurMultiplexingComponents')
|
||||||
|
state.currentCanvasNewId = []
|
||||||
state.batchOptStatus = false
|
state.batchOptStatus = false
|
||||||
// Currently selected components
|
// Currently selected components
|
||||||
state.curBatchOptComponents = []
|
state.curBatchOptComponents = []
|
||||||
|
Loading…
Reference in New Issue
Block a user