|
|
|
@ -189,10 +189,14 @@ export default class TPMevaluation extends Component {
|
|
|
|
|
}
|
|
|
|
|
let newevaluationlist=[]
|
|
|
|
|
if(response.data.test_sets.length===0){
|
|
|
|
|
let newlist=[
|
|
|
|
|
{hidden:0,input:"",output:"",score:50},
|
|
|
|
|
{hidden:1,input:"",output:"",score:50}
|
|
|
|
|
]
|
|
|
|
|
// let newlist=[
|
|
|
|
|
// {hidden:0,input:"",output:"",score:50},
|
|
|
|
|
// {hidden:1,input:"",output:"",score:50}
|
|
|
|
|
// ]
|
|
|
|
|
let newlist=[
|
|
|
|
|
{input:"",output:"",score:50},
|
|
|
|
|
{input:"",output:"",score:50}
|
|
|
|
|
]
|
|
|
|
|
newevaluationlist=newlist
|
|
|
|
|
}else{
|
|
|
|
|
newevaluationlist=response.data.test_sets
|
|
|
|
@ -243,7 +247,8 @@ export default class TPMevaluation extends Component {
|
|
|
|
|
addevaluationon=()=>{
|
|
|
|
|
let {evaluationlist,markvalue}=this.state;
|
|
|
|
|
let newevaluationlist=evaluationlist;
|
|
|
|
|
newevaluationlist.push({hidden:0,input:"",output:"",score:0});
|
|
|
|
|
// newevaluationlist.push({hidden:0,input:"",output:"",score:0});
|
|
|
|
|
newevaluationlist.push({input:"",output:"",score:0});
|
|
|
|
|
newevaluationlist=this.oneditevaluationlist(newevaluationlist,markvalue);
|
|
|
|
|
this.setevaluationlist(newevaluationlist);
|
|
|
|
|
}
|
|
|
|
@ -1076,7 +1081,7 @@ export default class TPMevaluation extends Component {
|
|
|
|
|
>%</span>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<Checkbox onChange={()=>this.evaluationonChange(item.hidden,key)} checked={item.hidden===1?true:false}>隐藏</Checkbox>
|
|
|
|
|
{/*<Checkbox onChange={()=>this.evaluationonChange(item.hidden,key)} checked={item.hidden===1?true:false}>隐藏</Checkbox>*/}
|
|
|
|
|
</span>
|
|
|
|
|
|
|
|
|
|
<Tooltip placement="bottom" title={"删除"}>
|
|
|
|
|