From 2371b8d3eb3eabae42c184636d3bcd99b0057687 Mon Sep 17 00:00:00 2001 From: Apple <> Date: Tue, 9 Aug 2022 11:50:51 +0800 Subject: [PATCH 1/2] =?UTF-8?q?key=E6=89=B9=E6=AC=A1=E5=A4=8D=E5=88=B6?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0copy=5Fkey=5Fbatch=5Fid=EF=BC=8C=E8=AE=A1?= =?UTF-8?q?=E7=AE=97=E5=A4=8D=E5=88=B6=E6=AC=A1=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/exchangecode/add/add.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/pages/exchangecode/add/add.js b/src/pages/exchangecode/add/add.js index ba7b4278..66c4f1ab 100644 --- a/src/pages/exchangecode/add/add.js +++ b/src/pages/exchangecode/add/add.js @@ -124,7 +124,8 @@ export default class acclist extends React.Component { newGoodsBtnLoading: false, newGoldLoading: false, product_title: '新建商品', - addIsType: '' + addIsType: '', + keyCodeId:'',//key批次ID } } @@ -141,7 +142,7 @@ export default class acclist extends React.Component { this.setState({ white_visible: true }) } - //编辑 + //复制 if (batch_id > 0 || copyOpearo == 2) { // this.setState({isEdit:true}) getKeyBatchDetail(batch_id).then((res) => { @@ -160,7 +161,6 @@ export default class acclist extends React.Component { let model = { title: req.plan_title, - batch_name: '', style: req.style, quantity: req.quantity, allow_repetition: req.allow_repetition, @@ -173,7 +173,7 @@ export default class acclist extends React.Component { this.setState({ model: model }) this.setState({ endtime: req.end_time }) this.setState({ begintime: req.begin_time }) - + this.setState({ keyCodeId: req.id }) let list = _.map(req.code_batch, (item) => { item.product = item.product.map((item1) => { let obj = {} @@ -226,7 +226,6 @@ export default class acclist extends React.Component { productRange.push(item.product_name) }) productRange = productRange.toString() - console.log(255, productRange) pr.range = productRange pr.restrict = item.restrict pr.title = item.title @@ -744,6 +743,7 @@ export default class acclist extends React.Component { this.setState({ audit_visible: false }) let id = sessionStorage.getItem('key_plan_id') + data.copy_key_batch_id=this.state.keyCodeId; addKeysBatchInfo(id, data).then((res) => { handelResponse( res, From 5c9f9067bafc74e86c1609f9228969dc39bf3ce1 Mon Sep 17 00:00:00 2001 From: wangsongsole Date: Tue, 9 Aug 2022 14:04:04 +0800 Subject: [PATCH 2/2] =?UTF-8?q?key=E5=88=97=E8=A1=A8=E6=9D=A1=E4=BB=B6?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2=20=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/plan/keyList/index.jsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/pages/plan/keyList/index.jsx b/src/pages/plan/keyList/index.jsx index a93563c9..0527a096 100644 --- a/src/pages/plan/keyList/index.jsx +++ b/src/pages/plan/keyList/index.jsx @@ -122,7 +122,9 @@ export default class acclist extends React.Component { this.setState({ distdata: req.data }) this.setState({ dataCount: req.total }) }, - (err) => {} + (err) => { + Notify.warn(err) + } ) }) }