From da538eabdaadad1a5e33fcd8c8f80f598cad6cc1 Mon Sep 17 00:00:00 2001 From: Apple <> Date: Tue, 11 Oct 2022 20:17:39 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E6=A8=A1=E6=9D=BF=E4=B8=AD=E5=BF=83):?= =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=90=8E=E7=AB=AF=E8=BF=94=E5=9B=9Ecoupon?= =?UTF-8?q?=E4=B8=BAnull=EF=BC=8C=E5=89=8D=E7=AB=AF=E6=B8=B2=E6=9F=93?= =?UTF-8?q?=E6=8A=A5=E9=94=99=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/exchangepage/template/main.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/pages/exchangepage/template/main.js b/src/pages/exchangepage/template/main.js index 20857dc3..4ef89652 100644 --- a/src/pages/exchangepage/template/main.js +++ b/src/pages/exchangepage/template/main.js @@ -194,6 +194,21 @@ export default class mytemplate extends React.Component { }else{ previewInfo=row.exchange; } + if(!previewInfo){//新增模板,没有数据,需要拼接组装 + previewInfo={ + land:{ + describe:{} + }, + product_list:{ + list:'', + describe:{} + + }, + product_detail:{ + describe:{} + } + } + } console.log(14,previewInfo); this.setState({ preview_visible: true,previewData:previewInfo, showType: row.page,moudleData: row, showPage: 1, pageStep: 1, activeHeight: 667, setStyle: { width: '375px', height: '667px', transform: 'scale(0.75)' } }); }