fix(模板中心):修复后端返回coupon为null,前端渲染报错处理
This commit is contained in:
parent
ee94f44529
commit
da538eabda
|
@ -194,6 +194,21 @@ export default class mytemplate extends React.Component {
|
||||||
}else{
|
}else{
|
||||||
previewInfo=row.exchange;
|
previewInfo=row.exchange;
|
||||||
}
|
}
|
||||||
|
if(!previewInfo){//新增模板,没有数据,需要拼接组装
|
||||||
|
previewInfo={
|
||||||
|
land:{
|
||||||
|
describe:{}
|
||||||
|
},
|
||||||
|
product_list:{
|
||||||
|
list:'',
|
||||||
|
describe:{}
|
||||||
|
|
||||||
|
},
|
||||||
|
product_detail:{
|
||||||
|
describe:{}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
console.log(14,previewInfo);
|
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)' } });
|
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)' } });
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue