|
@@ -165,15 +165,17 @@ export default {
|
|
|
if (na || nb || nc || oa || ob || oc) {
|
|
|
// 替换当前页签
|
|
|
this.replaceTab(newVal, oldVal)
|
|
|
+ // 从列表打开新增,编辑
|
|
|
+ this.$store.state.app.isNewTab = na || nb || nc
|
|
|
+ // 从编辑,新增返回列表
|
|
|
+ this.$store.state.app.updateList = ob || oc
|
|
|
} else {
|
|
|
this.tabsList.push(newVal.name)
|
|
|
this.pages.push(newVal)
|
|
|
this.pagesRecordList.push(newVal.name)
|
|
|
+ this.$store.state.app.isNewTab = true
|
|
|
+ this.$store.state.app.updateList = false
|
|
|
}
|
|
|
- // 从列表打开新增,编辑
|
|
|
- this.$store.state.app.isNewTab = na || nb || nc
|
|
|
- // 从编辑,新增返回列表
|
|
|
- this.$store.state.app.updateList = ob || oc
|
|
|
} else { // 已存在
|
|
|
this.pages.splice(index, 1, newVal)
|
|
|
this.tabsList.splice(index, 1, newVal.name)
|