diff --git a/src/pages/exchangepage/edittemplate/main.js b/src/pages/exchangepage/edittemplate/main.js index e1f7d21e..92c537df 100644 --- a/src/pages/exchangepage/edittemplate/main.js +++ b/src/pages/exchangepage/edittemplate/main.js @@ -236,7 +236,7 @@ export default class edittemplate extends React.Component { let pageChange = sessionStorage.getItem('pageChange') if (myInfoData) { let template = myInfoData.page - this.setState({ showType: Number(myInfoData.page) }) + this.setState({ showType: Number(myInfoData.page),systemTitle: myInfoData.title}) let newEditor = _.clone(myInfoData) if (typePage) { this.setState({ showType: Number(typePage) }) @@ -374,17 +374,17 @@ export default class edittemplate extends React.Component { } if (mouldType == 0) { //系统模板新增 - formdata.sort = exchangeStateData.model.sort - formdata.type_id = exchangeStateData.model.type_id.key + formdata.title=exchangeStateData.systemTitle; + formdata.sort = exchangeStateData.model.sort; + formdata.type_id = exchangeStateData.model.type_id.key; let infoExchange = {} infoExchange.land = exchangeStateData.model infoExchange.product_list = exchangeStateData.product_list infoExchange.product_detail = exchangeStateData.product_detail - _.omit(infoExchange.land, ['title', 'sort']); - _.omit(infoWhite.land, ['title', 'sort']); formdata.exchange = infoExchange formdata.access_conf = infoWhite formdata.coupon = infoCoupon + console.log(387,exchangeStateData); if (myInfoData) { //编辑 putSystemTemplate(myInfoData.id, formdata).then((res) => {