From 70723332c8da415be703be0f3fbf72e13f28ca2b Mon Sep 17 00:00:00 2001 From: Apple <> Date: Thu, 22 Sep 2022 13:45:22 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E7=BC=96=E8=BE=91=E5=99=A8?= =?UTF-8?q?=E5=85=BC=E5=AE=B9=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../couponCard/couponViewConfig/bottomBar.js | 12 + .../couponCard/goodsPage/config/bottomBar.js | 372 +++++++----------- .../edittemplate/couponCard/landPage.js | 2 +- .../edittemplate/exchange/landingPage.js | 2 +- .../edittemplate/goodstemplate.js | 20 - src/pages/exchangepage/edittemplate/main.js | 6 +- .../edittemplate/whiteList/whiteLand.js | 9 +- 7 files changed, 167 insertions(+), 256 deletions(-) diff --git a/src/pages/exchangepage/edittemplate/couponCard/couponViewConfig/bottomBar.js b/src/pages/exchangepage/edittemplate/couponCard/couponViewConfig/bottomBar.js index 59a902b3..3f665fc6 100644 --- a/src/pages/exchangepage/edittemplate/couponCard/couponViewConfig/bottomBar.js +++ b/src/pages/exchangepage/edittemplate/couponCard/couponViewConfig/bottomBar.js @@ -41,6 +41,7 @@ export default class bottomBar extends React.Component { } } componentWillReceiveProps(nextProps){ + console.log(44,nextProps); let navList=nextProps.bottomBarConfig.navlist; let naVisual=navList.filter(item=>item.iswitch); this.setState({navList:naVisual}); @@ -48,7 +49,18 @@ export default class bottomBar extends React.Component { clickIcon(e,index){ this.setState({active:index}); } + componentDidMount(){ + console.log(53); + let config = JSON.parse(sessionStorage.getItem('editorConfig')); + if (config && config.coupon && config.coupon.product_list) { + let { navlist, defaultText, selectText, background, iswitch } = config.coupon.product_list.bottomBar; + this.setState({ defaultText, selectText, background, iswitch }); + let naVisual=navlist.filter(item=>item.iswitch); + this.setState({navList:naVisual}); + } + } render() { + console.log(53,this.state); let active=this.state.active; return (