637b2558 by 田浩浩

修改分屏以后,别的选项卡内容消失

1 parent fe5fc1f2
...@@ -88,8 +88,8 @@ ...@@ -88,8 +88,8 @@
88 <el-tab-pane 88 <el-tab-pane
89 :label="item.name" 89 :label="item.name"
90 :name="item.value" 90 :name="item.value"
91 v-for="(item, index) in tabList" 91 v-for="item in tabList"
92 :key="index" 92 :key="item.value"
93 > 93 >
94 </el-tab-pane> 94 </el-tab-pane>
95 </el-tabs> 95 </el-tabs>
...@@ -272,16 +272,18 @@ export default { ...@@ -272,16 +272,18 @@ export default {
272 break; 272 break;
273 case "B2": //材料分屏按钮 273 case "B2": //材料分屏按钮
274 this.splitScreen = this.splitScreen ? false : true; 274 this.splitScreen = this.splitScreen ? false : true;
275 this.$store.dispatch("app/settScreen", this.splitScreen); 275 this.$store.dispatch("app/settScreen", this.splitScreen);
276 if (this.splitScreen) { 276 if (this.splitScreen) {
277 //如果当前选项卡为材料信息内容,递减到上一个选项卡内容 277 //如果当前选项卡为材料信息内容,递减到上一个选项卡内容
278 if (this.tabName == this.clxxTab.value) { 278 if (this.tabName == this.clxxTab.value) {
279 this.tabName = this.tabList[this.clxxIndex - 1].value; 279 this.tabName = this.tabList[this.clxxIndex - 1].value;
280 this.getFromRouter(this.tabList[this.clxxIndex - 1].value); 280 this.getFromRouter(this.tabList[this.clxxIndex - 1].value);
281 } 281 }
282 //删除材料信息选项卡数据
282 this.tabList.splice(this.clxxIndex, 1); 283 this.tabList.splice(this.clxxIndex, 1);
283 } else { 284 } else {
284 this.tabList.splice(this.clxxIndex, 1, this.clxxTab); 285 //新增材料信息选项卡数据
286 this.tabList.splice(this.clxxIndex, 0, this.clxxTab);
285 } 287 }
286 break; 288 break;
287 case "B4": 289 case "B4":
......