From e9c48bd7356462ba9257540b130a47a65ad1861d Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期四, 26 八月 2021 17:17:11 +0800 Subject: [PATCH] 2021-08-26 --- src/tabviews/custom/components/carousel/prop-card/index.jsx | 16 +++++++++------- 1 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/tabviews/custom/components/carousel/prop-card/index.jsx b/src/tabviews/custom/components/carousel/prop-card/index.jsx index 8402eb6..392ac7a 100644 --- a/src/tabviews/custom/components/carousel/prop-card/index.jsx +++ b/src/tabviews/custom/components/carousel/prop-card/index.jsx @@ -27,7 +27,8 @@ config: null, // 鍥捐〃閰嶇疆淇℃伅 loading: false, // 鏁版嵁鍔犺浇鐘舵�� sync: false, // 鏄惁缁熶竴璇锋眰鏁版嵁 - data: {} // 鏁版嵁 + data: {}, // 鏁版嵁 + BData: null } UNSAFE_componentWillMount () { @@ -165,12 +166,12 @@ } } - resetParentParam = (MenuID, id) => { + resetParentParam = (MenuID, id, data) => { const { config } = this.state if (config.wrap.datatype === 'static' || !config.setting.supModule || config.setting.supModule !== MenuID) return if (id !== this.state.BID) { - this.setState({ BID: id }, () => { + this.setState({ BID: id, BData: data }, () => { this.loadData() }) } @@ -186,16 +187,16 @@ async loadData () { const { mainSearch, menuType } = this.props - const { config, arr_field, BID } = this.state + const { config, arr_field, BID, BData } = this.state if (config.wrap.datatype === 'static') { this.setState({ - data: {$$BID: BID || ''} + data: {$$BID: BID || '', $$BData: BData} }) return } else if (config.setting.supModule && !BID) { // BID 涓嶅瓨鍦ㄦ椂锛屼笉鍋氭煡璇� this.setState({ - data: {$$BID: BID || ''} + data: {$$BID: BID || '', $$BData: BData} }) return } @@ -218,6 +219,7 @@ if (result.status) { let _data = result.data && result.data[0] ? result.data[0] : {} _data.$$BID = BID || '' + _data.$$BData = BData || '' this.setState({ data: _data, @@ -263,7 +265,7 @@ newtab.param.$BID = item.setting.primaryId } - if (['linkage_navigation', 'linkage'].includes(window.GLOB.navBar)) { + if (['linkage_navigation', 'linkage', 'menu_board'].includes(window.GLOB.navBar)) { this.props.modifyTabview([newtab]) } else { let tabs = this.props.tabviews.filter((tab, i) => { -- Gitblit v1.8.0