|
@@ -1012,14 +1012,26 @@ export default {
|
|
|
let { subReportId } = route.query
|
|
|
const { pageType } = route.query
|
|
|
const [tabKey, subTabKey] = state.subTabsActive
|
|
|
+ console.log(state, 1016)
|
|
|
+ // 查询
|
|
|
if (!subReportId) {
|
|
|
if (pageType !== 'readAll') {
|
|
|
subReportId = state.tabsActive.replace(/tab_/, '')
|
|
|
}
|
|
|
if (pageType === 'readAll') {
|
|
|
- const tabName = state.tabsActive.replace(/tab_/, '')
|
|
|
+ let tabName = ''
|
|
|
+ console.log(tabName)
|
|
|
+ // 找到当前 domkey 对应的业务线名称
|
|
|
+ state.tabPageData.children.forEach(elm => {
|
|
|
+ elm.children && elm.children.forEach(item => {
|
|
|
+ if (item.domKey === domKey && !tabName) {
|
|
|
+ tabName = elm.title
|
|
|
+ }
|
|
|
+ })
|
|
|
+ })
|
|
|
+ // 根据找到的业务线名称查询业务线ID
|
|
|
state.subReportInfo.forEach(elm => {
|
|
|
- if (elm.reportName === tabName) {
|
|
|
+ if(elm.reportName === tabName) {
|
|
|
subReportId = elm.id
|
|
|
}
|
|
|
})
|