import React, { Component } from 'react'; import {getImageUrl} from 'educoder'; import { Modal,InputNumber} from 'antd'; import axios from 'axios'; import './../questioncss/questioncom.css' class Paperreview_itemModel extends Component { constructor(props) { super(props); this.state={ value:0, } } onChange=(value)=>{ //console.log("设置批量得分"); //console.log(value); this.setState({ value:value, }) } setDownloadysl=()=>{ var re = /^[0-9]+.?[0-9]*$/; //判断字符串是否为数字 //判断正整数 /^[1-9]+[0-9]*]*$/ var nubmer = this.state.value; if (!re.test(nubmer)) { this.props.showNotification(`必须为数值`); return; } try { if(nubmer<1){ this.props.showNotification(`不能小于0`); return; } }catch (e) { } this.props.setDownloady(this.state.value) } render() { return(

{this.props.titilesm}:

分/题

this.props.Singlemagazine("",false)}>取消 this.setDownloadysl()}>确定
) } } export default Paperreview_itemModel;