|
|
|
@ -195,10 +195,10 @@ export default class TPManswer extends Component {
|
|
|
|
|
this.setState({ answers: newAnswers})
|
|
|
|
|
}
|
|
|
|
|
answerOnChange = (val, index) => {
|
|
|
|
|
// if (!this.state.answers[index]) {
|
|
|
|
|
// // 1、2、3删除2会走到这里
|
|
|
|
|
// return;
|
|
|
|
|
// }
|
|
|
|
|
if (!this.state.answers[index]) {
|
|
|
|
|
// 1、2、3删除2会走到这里
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
const newAnswer = Object.assign({}, this.state.answers[index])
|
|
|
|
|
newAnswer.contents = val
|
|
|
|
|
const newAnswers = this.state.answers.slice(0)
|
|
|
|
@ -314,7 +314,7 @@ export default class TPManswer extends Component {
|
|
|
|
|
|
|
|
|
|
{
|
|
|
|
|
answers.map((answer, index) => {
|
|
|
|
|
return <div className="levelSection" id={`levelSection${index}`}>
|
|
|
|
|
return <div className="levelSection" id={`levelSection${index}`} style={{ clear: 'both' }}>
|
|
|
|
|
<span className="mr4 color-orange pt10">*</span>
|
|
|
|
|
<p className="color-grey-6 font-16 mb30 mt10" style={{ display: "inline" }}>级别{index + 1}</p>
|
|
|
|
|
<a className="fr sample_icon_remove mr30 mt8" onClick={()=>this.delanswers(index)}>
|
|
|
|
|