-
+
+
{
- if(item.value){
- this.config[item.field]=item.value? item.value:this.config[item.field]
- }
+ this.$set(this.config,item.field,item.value)
})
}
}
@@ -297,6 +316,7 @@ export default {
title:{
set(){
this.config.type=''
+ this.config.padding=[16,16,16,16]
},
get(){
plotList[Symbol.iterator]=function*(){
@@ -332,9 +352,13 @@ export default {
},
data () {
return {
+ // borderWidth:0
}
},
mounted () {
+ // if(this.config.borderWidth){
+ // this.borderWidth=this.config.borderWidth
+ // }
},
methods: {
init(){
diff --git a/data-room-ui/packages/BigScreenDesign/index.vue b/data-room-ui/packages/BigScreenDesign/index.vue
index fe4bd27d..b8f4609c 100644
--- a/data-room-ui/packages/BigScreenDesign/index.vue
+++ b/data-room-ui/packages/BigScreenDesign/index.vue
@@ -205,6 +205,15 @@ export default {
}
},
watch: {
+ chartList(val){
+ // console.log(val,this.activeCode)
+ // if(val.findIndex(item=>item.code==this.activeCode)==-1){
+ // this.updateRightVisiable(false)
+ // }
+ // if(val.length==0){
+ // this.updateRightVisiable(false)
+ // }
+ },
fitZoom (zoom) {
this.zoomList[0] = {
label: `自适应(${zoom}%)`,
@@ -252,7 +261,9 @@ export default {
}
},
mounted () {
- EventBus.$on('closeRightPanel', () => { this.rightVisiable = false })
+ EventBus.$on('closeRightPanel', () => {
+ this.updateRightVisiable(false)
+ })
},
beforeDestroy () {
this.clearTimeline()
@@ -298,7 +309,7 @@ export default {
getScreenInfo(component.code).then(res => {
res.chartList.forEach((item) => {
if (!item.border) {
- item.border={type:'',titleHeight:60,fontSize:30,isTitle:true,padding:[0,0,0,0]}
+ item.border={type:'',titleHeight:60,fontSize:16,isTitle:true,padding:[0,0,0,0]}
}
if(!item.border.padding){
item.border.padding=[0,0,0,0]
diff --git a/data-room-ui/packages/BorderComponents/GcBorder1/setting.js b/data-room-ui/packages/BorderComponents/GcBorder1/setting.js
index 0ab9a4d2..3d2e7131 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder1/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder1/setting.js
@@ -1,9 +1,11 @@
const type = 'GcBorder1'
-const name = '边框一'
+const name = '边框1'
-const isTitle=false
+const isTitle = false
+
+const padding =[16,16,16,16]
// 右侧配置项
const setting = [
@@ -43,7 +45,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -102,5 +104,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder10/setting.js b/data-room-ui/packages/BorderComponents/GcBorder10/setting.js
index 224ea530..19f47a71 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder10/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder10/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder10'
-const name = '边框十'
+const name = '边框10'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -101,5 +103,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder11/setting.js b/data-room-ui/packages/BorderComponents/GcBorder11/setting.js
index a575d00c..935c1131 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder11/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder11/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder11'
-const name = '边框十一'
+const name = '边框11'
+
+const padding =[36,16,16,16]
const isTitle=true
// 右侧配置项
@@ -53,7 +55,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -111,5 +113,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder12/setting.js b/data-room-ui/packages/BorderComponents/GcBorder12/setting.js
index df9deb21..29348df3 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder12/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder12/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder12'
-const name = '边框十二'
+const name = '边框12'
+
+const padding =[16,16,16,16]
const isTitle=false
@@ -43,7 +45,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -102,5 +104,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder13/setting.js b/data-room-ui/packages/BorderComponents/GcBorder13/setting.js
index 2298e1a1..c33889d1 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder13/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder13/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder13'
-const name = '边框十三'
+const name = '边框13'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -101,5 +103,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder14/component.png b/data-room-ui/packages/BorderComponents/GcBorder14/component.png
index 5303c765..56a3df78 100644
Binary files a/data-room-ui/packages/BorderComponents/GcBorder14/component.png and b/data-room-ui/packages/BorderComponents/GcBorder14/component.png differ
diff --git a/data-room-ui/packages/BorderComponents/GcBorder14/index.vue b/data-room-ui/packages/BorderComponents/GcBorder14/index.vue
index 52a988a7..e1423a8f 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder14/index.vue
+++ b/data-room-ui/packages/BorderComponents/GcBorder14/index.vue
@@ -60,17 +60,17 @@ export default {
return this.config.border.borderColor || ''
},
width () {
- return this.config.border.borderWidth || 2
+ return this.config.border.borderWidth || 0
},
gradientColor0 () {
- if (this.config.border.gradientColor) {
+ if (this.config.border.gradientColor&&this.config.border.gradientColor.length) {
return this.config.border.gradientColor[0] || this.config.border.gradientColor[1]
} else {
return 'transparent'
}
},
gradientColor1 () {
- if (this.config.border.gradientColor) {
+ if (this.config.border.gradientColor&&this.config.border.gradientColor.length) {
return this.config.border.gradientColor[1] || this.config.border.gradientColor[0]
} else {
return 'transparent'
diff --git a/data-room-ui/packages/BorderComponents/GcBorder14/setting.js b/data-room-ui/packages/BorderComponents/GcBorder14/setting.js
index e2dd650b..c49db291 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder14/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder14/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder14'
-const name = '边框十四'
+const name = '边框14'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: ['#83bff6','#188df0'],
},
{
label: '渐变色方向',
@@ -152,5 +154,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder15/component.png b/data-room-ui/packages/BorderComponents/GcBorder15/component.png
index 5303c765..af6d4530 100644
Binary files a/data-room-ui/packages/BorderComponents/GcBorder15/component.png and b/data-room-ui/packages/BorderComponents/GcBorder15/component.png differ
diff --git a/data-room-ui/packages/BorderComponents/GcBorder15/index.vue b/data-room-ui/packages/BorderComponents/GcBorder15/index.vue
index 14ff0f01..8dee0798 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder15/index.vue
+++ b/data-room-ui/packages/BorderComponents/GcBorder15/index.vue
@@ -22,7 +22,7 @@
:style="`
line-height:${config.border.titleHeight}px;
height:${config.border.titleHeight};
- border-bottom:3px solid ${fontBottomColor};
+ border-bottom:${fontBottomColor?3:0}px solid ${fontBottomColor};
background-image: linear-gradient(${gradientDirection}, ${
fontGradientColor0 ? fontGradientColor0 : fontGradientColor1
} , ${fontGradientColor1 ? fontGradientColor1 : fontGradientColor0})
@@ -70,31 +70,31 @@ export default {
return this.config.border.borderColor || ''
},
width () {
- return this.config.border.borderWidth!=null?this.config.border.borderWidth : 2
+ return this.config.border.borderWidth!=null?this.config.border.borderWidth : 0
},
gradientColor0 () {
- if(this.config.border.gradientColor){
+ if(this.config.border.gradientColor&&this.config.border.gradientColor.length){
return this.config.border.gradientColor[0] ||this.config.border.gradientColor[1]
}else{
return 'transparent'
}
},
gradientColor1 () {
- if(this.config.border.gradientColor){
+ if(this.config.border.gradientColor&&this.config.border.gradientColor.length){
return this.config.border.gradientColor[1] ||this.config.border.gradientColor[0]
}else{
return 'transparent'
}
},
fontGradientColor0 () {
- if(this.config.border.fontGradientColor){
+ if(this.config.border.fontGradientColor&&this.config.border.fontGradientColor.length){
return this.config.border.fontGradientColor[0] ||this.config.border.fontGradientColor[1]
}else{
return 'transparent'
}
},
fontGradientColor1 () {
- if(this.config.border.fontGradientColor){
+ if(this.config.border.fontGradientColor&&this.config.border.fontGradientColor.length){
return this.config.border.fontGradientColor[1]||this.config.border.fontGradientColor[0]
}else{
return 'transparent'
@@ -107,7 +107,7 @@ export default {
return this.config.border.fontBottomColor || ''
},
fontLeftWidth(){
- return this.config.border.fontLeftWidth!=null?this.config.border.fontLeftWidth : 6
+ return this.config.border.fontLeftWidth || 6
},
radiusLeftTop () {
return this.config.border.radiusLeftTop || 2
diff --git a/data-room-ui/packages/BorderComponents/GcBorder15/setting.js b/data-room-ui/packages/BorderComponents/GcBorder15/setting.js
index b93bdf19..5705ac46 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder15/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder15/setting.js
@@ -1,9 +1,11 @@
const type = 'GcBorder15'
-const name = '边框十五'
+const name = '边框15'
-const isTitle=true
+const isTitle = true
+
+const padding =[0,0,0,0]
// 右侧配置项
const setting = [
@@ -17,7 +19,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
// 背景色
// {
@@ -66,7 +68,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: 6,
+ value: 4,
},
{
label:'标题底部分割线颜色',
@@ -78,7 +80,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '#007aff',
+ value: '',
},
{
label:'外边框线颜色',
@@ -102,7 +104,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: 1,
+ value: 0,
},
{
label:'背景色',
@@ -114,7 +116,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
// {
// label:'背景色一',
@@ -248,5 +250,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder2/setting.js b/data-room-ui/packages/BorderComponents/GcBorder2/setting.js
index 37e0468a..88211451 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder2/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder2/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder2'
-const name = '边框二'
+const name = '边框2'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -41,7 +43,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -100,5 +102,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder3/setting.js b/data-room-ui/packages/BorderComponents/GcBorder3/setting.js
index 0709432f..33238a97 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder3/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder3/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder3'
-const name = '边框三'
+const name = '边框3'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -101,5 +103,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder4/setting.js b/data-room-ui/packages/BorderComponents/GcBorder4/setting.js
index 5e291ee1..a6b1eff5 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder4/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder4/setting.js
@@ -3,7 +3,8 @@ const type = 'GcBorder4'
const isTitle=false
-const name='边框四'
+const name = '边框4'
+const padding =[16,16,16,16]
// 右侧配置项
const setting = [
// 背景色
@@ -42,7 +43,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -113,5 +114,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder5/setting.js b/data-room-ui/packages/BorderComponents/GcBorder5/setting.js
index 9e3a37df..1fe3a75b 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder5/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder5/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder5'
-const name = '边框五'
+const name = '边框5'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -112,5 +114,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder6/setting.js b/data-room-ui/packages/BorderComponents/GcBorder6/setting.js
index 3deb2996..c607fa17 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder6/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder6/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder6'
-const name = '边框六'
+const name = '边框6'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -100,5 +102,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder7/setting.js b/data-room-ui/packages/BorderComponents/GcBorder7/setting.js
index ce726655..e7b934bc 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder7/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder7/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder7'
-const name = '边框七'
+const name = '边框7'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -100,5 +102,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder8/setting.js b/data-room-ui/packages/BorderComponents/GcBorder8/setting.js
index 01def878..1e8e6e78 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder8/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder8/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder8'
-const name = '边框八'
+const name = '边框8'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -126,5 +128,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/GcBorder9/setting.js b/data-room-ui/packages/BorderComponents/GcBorder9/setting.js
index f257ce06..6e47646a 100644
--- a/data-room-ui/packages/BorderComponents/GcBorder9/setting.js
+++ b/data-room-ui/packages/BorderComponents/GcBorder9/setting.js
@@ -1,7 +1,9 @@
const type = 'GcBorder9'
-const name = '边框九'
+const name = '边框9'
+
+const padding =[16,16,16,16]
const isTitle=false
// 右侧配置项
@@ -42,7 +44,7 @@ const setting = [
// 是否多选
multiple: false,
// 绑定的值
- value: '',
+ value: [],
},
{
label: '渐变色方向',
@@ -100,5 +102,6 @@ export default {
setting,
type,
name,
- isTitle
+ isTitle,
+ padding
}
diff --git a/data-room-ui/packages/BorderComponents/settingList.js b/data-room-ui/packages/BorderComponents/settingList.js
index 4d78fe17..f3bcc97e 100644
--- a/data-room-ui/packages/BorderComponents/settingList.js
+++ b/data-room-ui/packages/BorderComponents/settingList.js
@@ -5,12 +5,13 @@ const plotList = []
// ./折线图/基础折线图.js
// 取到 "基础折线图"
const config = files(key).default
- plotList.push({
- type: config.type,
- setting: config.setting,
- name: config.name,
- isTitle:config.isTitle
- })
+ plotList.push({
+ type: config.type,
+ setting: config.setting,
+ name: config.name,
+ isTitle: config.isTitle,
+ padding: config.padding
+ })
})
export default plotList
diff --git a/data-room-ui/packages/BorderSelect/index.vue b/data-room-ui/packages/BorderSelect/index.vue
index ad8f74a7..e3b30f6d 100644
--- a/data-room-ui/packages/BorderSelect/index.vue
+++ b/data-room-ui/packages/BorderSelect/index.vue
@@ -126,6 +126,9 @@ export default {
},
mounted () {
this.remoteComponentlist = [...borderComponents]
+ this.remoteComponentlist.sort((a,b)=>{
+ return a.title.slice(8) - b.title.slice(8)
+ })
},
methods: {
getName(title){
diff --git a/data-room-ui/packages/G2Plots/plotList.js b/data-room-ui/packages/G2Plots/plotList.js
index 18f7595c..3a644fa9 100644
--- a/data-room-ui/packages/G2Plots/plotList.js
+++ b/data-room-ui/packages/G2Plots/plotList.js
@@ -32,7 +32,7 @@ function getPlotList (files) {
category: configMapKey,
name: config.name,
title: config.title,
- border:{ type: '', titleHeight: 60, fontSize: 30, isTitle: true, padding: [16, 16, 16, 16] },
+ border:{ type: '', titleHeight: 60, fontSize: 16, isTitle: true, padding: [16, 16, 16, 16] },
icon: null,
img: require(`../G2Plots/images/componentLogo/${config.title}.png`),
className:
@@ -66,7 +66,7 @@ export function getCustomPlots () {
category: config.category,
name: config.name,
title: config.title,
- border:{ type: '', titleHeight: 60, fontSize: 30, isTitle: true, padding: [16, 16, 16, 16] },
+ border:{ type: '', titleHeight: 60, fontSize: 16, isTitle: true, padding: [16, 16, 16, 16] },
icon: null,
img: config.img,
className:
diff --git a/data-room-ui/packages/RemoteComponents/remoteComponentsList.js b/data-room-ui/packages/RemoteComponents/remoteComponentsList.js
index 4a38268c..34289c06 100644
--- a/data-room-ui/packages/RemoteComponents/remoteComponentsList.js
+++ b/data-room-ui/packages/RemoteComponents/remoteComponentsList.js
@@ -32,7 +32,7 @@ export function getRemoteComponents (comList) {
title: config.title,
icon: null,
img: config.img,
- border:{type:'',titleHeight:60,fontSize:30,isTitle:true,padding:[16,16,16,16]},
+ border:{type:'',titleHeight:60,fontSize:16,isTitle:true,padding:[16,16,16,16]},
className:
'com.gccloud.dataroom.core.module.chart.components.RemoteComponentChart',
w: 450,
@@ -64,7 +64,7 @@ export function getRemoteComponentConfig (code, name) {
title: name,
icon: null,
img: null,
- border:{type:'',titleHeight:60,fontSize:30,isTitle:true,padding:[16,16,16,16]},
+ border:{type:'',titleHeight:60,fontSize:16,isTitle:true,padding:[16,16,16,16]},
className:
'com.gccloud.dataroom.core.module.chart.components.RemoteComponentChart',
w: 450,
diff --git a/data-room-ui/packages/js/store/actions.js b/data-room-ui/packages/js/store/actions.js
index a16edc2f..3da88517 100644
--- a/data-room-ui/packages/js/store/actions.js
+++ b/data-room-ui/packages/js/store/actions.js
@@ -19,7 +19,7 @@ export default {
// 兼容边框配置
pageInfo.chartList.forEach((item) => {
if (!item.border) {
- item.border = { type: '', titleHeight: 60, fontSize: 30, isTitle: true, padding: [0, 0, 0, 0] }
+ item.border = { type: '', titleHeight: 60, fontSize: 16, isTitle: true, padding: [0, 0, 0, 0] }
}
if (!item.border.padding) {
item.border.padding = [0, 0, 0, 0]
diff --git a/data-room-ui/packages/js/store/mutations.js b/data-room-ui/packages/js/store/mutations.js
index 35498e04..a5e7f32c 100644
--- a/data-room-ui/packages/js/store/mutations.js
+++ b/data-room-ui/packages/js/store/mutations.js
@@ -166,11 +166,13 @@ export default {
}
// 存储删除后的状态
saveTimeLineFunc(state, '删除组件')
- // 删除后,清空当前选中组件
- state.activeItemConfig = null
- state.activeCode = null
+ if (state.pageInfo.chartList.findIndex(item=>item.code===state.activeCode)==-1) {
+ state.activeItemConfig = null
+ state.activeCode = null
+ EventBus.$emit('closeRightPanel')
+ }
// 发送事件,关闭配置面板
- EventBus.$emit('closeRightPanel')
+
},
changePageConfig (state, pageConfig) {
Vue.set(state.pageInfo, 'pageConfig', cloneDeep(pageConfig))