解决无回显bug

This commit is contained in:
red-deng-deng 2021-11-25 15:30:24 +08:00
parent f539a05a6c
commit 81200868ba
1 changed files with 22 additions and 18 deletions

View File

@ -36,6 +36,7 @@ export default class exchangedit extends React.Component{
date_time:"",
range:""
},
isload:false,
tempdata:[],
cur_product:null,
productOption:[],
@ -66,6 +67,7 @@ export default class exchangedit extends React.Component{
}
this.setState({codeInfo:codeInfo})
this.setState({isload:true});
console.log("当前的商品信息66")
@ -401,14 +403,14 @@ export default class exchangedit extends React.Component{
width:'auto',
},
];
return(
<div id="editcode">
<div>
<Card style={{ width:'90%',"margin":"10px auto"}} title={'基本信息'}>
<p className="addcode">
<Form model={this.state.codeInfo} rules={codeInfo} ref="code_info" className="addform">
<FormItem labelname="兑换码名称" prop="code_name" id="code_name">
{
this.state.isload? <FormItem labelname="兑换码名称" prop="code_name" id="code_name">
<Ipt onChange={(e)=>{
let model = this.state.codeInfo;
model.code_name = e;
@ -423,7 +425,9 @@ export default class exchangedit extends React.Component{
value={this.state.codeInfo.code_name} placeholder={"请输入兑换码名称"} labelWidth={'0px'} maxLength={10} height={'36px'} width={'520px'} alignment={'left'}/>
</FormItem>
</FormItem>:null
}
<FormItem labelname="发放总量" prop="issued" id="issued">
<Ipt onChange={(e)=>{
let model= this.state.codeInfo;