dev_forum
杨树林 5 years ago
parent 66dea92f25
commit 3c4151ce65

@ -80,6 +80,8 @@ class TraineetraininginformationModal extends Component {
} }
render() { render() {
var columns; var columns;
console.log(83);
console.log(this.props.boolgalist);
if(this.props.boolgalist&&this.props.boolgalist === true) { if(this.props.boolgalist&&this.props.boolgalist === true) {
columns = [ columns = [
{ {

@ -625,7 +625,7 @@ submittojoinclass=(value)=>{
{/* />*/} {/* />*/}
{/* :""*/} {/* :""*/}
{/*}*/} {/*}*/}
<Trialapplication {...this.state} ></Trialapplication> <Trialapplication {...this.state} Cancel={() => this.cancelModulationModels()} ></Trialapplication>
<div className="educontent clearfix"> <div className="educontent clearfix">
{/*<%= link_to image_tag("/images/educoder/logo.png", alt:"高校智能化教学与实训平台", className:"logoimg"), home_path %>*/} {/*<%= link_to image_tag("/images/educoder/logo.png", alt:"高校智能化教学与实训平台", className:"logoimg"), home_path %>*/}
<a href="/"> <a href="/">

@ -181,6 +181,7 @@ class Newshixuns extends Component {
systemenvironment:undefined, systemenvironment:undefined,
testcoderunmode:undefined, testcoderunmode:undefined,
file:undefined, file:undefined,
deleteisnot:true,
} }
} }
@ -547,7 +548,7 @@ class Newshixuns extends Component {
// if (id) { // if (id) {
if(this.state.file !== undefined){ if(this.state.file !== undefined){
console.log("549"); console.log("549");
this.deleteAttachment(this.state.file); // this.deleteAttachment(this.state.file);
this.setState({ this.setState({
file:undefined, file:undefined,
languagewrite:"", languagewrite:"",
@ -579,7 +580,7 @@ class Newshixuns extends Component {
}) })
if(this.state.file !== undefined){ if(this.state.file !== undefined){
console.log("580"); console.log("580");
this.deleteAttachment(this.state.file); // this.deleteAttachment(this.state.file);
this.setState({ this.setState({
file:undefined, file:undefined,
languagewrite:"", languagewrite:"",
@ -655,7 +656,8 @@ class Newshixuns extends Component {
handleChange = (info) => { handleChange = (info) => {
console.log("handleChange1"); console.log("handleChange1");
let fileList = info.fileList; let fileList = info.fileList;
this.setState({ fileList }); this.setState({ fileList:fileList,
deleteisnot:false});
} }
onAttachmentRemove = (file) => { onAttachmentRemove = (file) => {
confirm({ confirm({
@ -686,11 +688,13 @@ class Newshixuns extends Component {
// console.log('--- success') // console.log('--- success')
this.setState((state) => { this.setState((state) => {
const index = state.fileList.indexOf(file); const index = state.fileList.indexOf(file);
const newFileList = state.fileList.slice(); const newFileList = state.fileList.slice();
newFileList.splice(index, 1); newFileList.splice(index, 1);
return { return {
fileList: newFileList, fileList: newFileList,
deleteisnot:true
}; };
}); });
} }
@ -736,7 +740,7 @@ class Newshixuns extends Component {
render() { render() {
const { getFieldDecorator } = this.props.form; const { getFieldDecorator } = this.props.form;
const thiss=this; const thiss=this;
let {testcoderunmode ,systemenvironment,languagewrite, fileList,TimePickervalue, scope_partmenttype, opensmail, newshixunlist, name, scope_partment, departmentslist, postapplyvisible, sendsure_applyvalue, postapplytitle, shixun_nametype, main_types, trainee_types, SelectTheCommandtype, opers, operss, onSearchvalue} = this.state; let {testcoderunmode ,systemenvironment,languagewrite,deleteisnot, fileList,TimePickervalue, scope_partmenttype, opensmail, newshixunlist, name, scope_partment, departmentslist, postapplyvisible, sendsure_applyvalue, postapplytitle, shixun_nametype, main_types, trainee_types, SelectTheCommandtype, opers, operss, onSearchvalue} = this.state;
let options let options
if (departmentslist != undefined) { if (departmentslist != undefined) {
options = this.state.departmentslist.map((d, k) => { options = this.state.departmentslist.map((d, k) => {
@ -764,7 +768,7 @@ class Newshixuns extends Component {
} }
if(thiss.state.file !== undefined){ if(thiss.state.file !== undefined){
console.log("763") console.log("763")
thiss.deleteAttachment(thiss.state.file); // thiss.deleteAttachment(thiss.state.file);
thiss.setState({ thiss.setState({
file:file file:file
}) })
@ -797,6 +801,7 @@ class Newshixuns extends Component {
// return isLt50M; // return isLt50M;
// }, // },
// }; // };
return ( return (
<div className="newMain clearfix" onClick={this.bigopens}> <div className="newMain clearfix" onClick={this.bigopens}>
@ -934,12 +939,23 @@ class Newshixuns extends Component {
{/* rules:[{*/} {/* rules:[{*/}
{/* }]*/} {/* }]*/}
{/* })(*/} {/* })(*/}
{
deleteisnot=== true?
<Upload {...uploadProps} > <Upload {...uploadProps} >
<Icon type="upload" className="fl mt5" > </Icon> <Icon type="upload" className="fl mt5" > </Icon>
<span className="color-blue fl">上传附件</span> <span className="color-blue fl">上传附件</span>
<span className="color-grey-c fl ml10 ">(单个文件50M以内)</span> <span className="color-grey-c fl ml10 ">(单个文件50M以内)</span>
</Upload> </Upload>
:
<Upload disabled={true} >
<Icon type="upload" className="fl mt5" > </Icon>
<span className="color-grey-c fl">上传附件</span>
<span className="color-grey-c fl ml10 ">(单个文件50M以内)</span>
</Upload>
}
{/* )*/} {/* )*/}
{/* }*/} {/* }*/}
{/*</Form.Item>*/} {/*</Form.Item>*/}

Loading…
Cancel
Save