Merge branches 'dev_aliyun' and 'topic_bank' of https://bdgit.educoder.net/Hjqreturn/educoder into topic_bank

dev_aliyun_beta
杨树明 5 years ago
commit ed50432af0

@ -181,15 +181,16 @@ class BoardsNew extends Component{
} }
// 附件相关 START // 附件相关 START
handleChange = (info) => { handleChange = (info) => {
let fileList = info.fileList; if (info.file.status === 'uploading' || info.file.status === 'done' || info.file.status === 'removed') {
this.setState({ fileList: appendFileSizeToUploadFileAll(fileList) let fileList = info.fileList;
}); this.setState({ fileList: appendFileSizeToUploadFileAll(fileList) });
}
} }
onAttachmentRemove = (file) => { onAttachmentRemove = (file) => {
if(!file.percent || file.percent == 100){ if(!file.percent || file.percent == 100){
confirm({ this.props.confirm({
// title: '确定要删除这个附件吗?', // title: '确定要删除这个附件吗?',
title: '是否确认删除?', content: '是否确认删除?',
okText: '确定', okText: '确定',
cancelText: '取消', cancelText: '取消',

@ -291,7 +291,7 @@ class CommonWorkPost extends Component{
} }
// 附件相关 START // 附件相关 START
handleChange = (info) => { handleChange = (info) => {
if (info.file.status === 'uploading' || info.file.status === 'done') { if (info.file.status === 'uploading' || info.file.status === 'done' || info.file.status === 'removed') {
let fileList = info.fileList; let fileList = info.fileList;
this.setState({ fileList: appendFileSizeToUploadFileAll(fileList) }); this.setState({ fileList: appendFileSizeToUploadFileAll(fileList) });

@ -235,12 +235,16 @@ class NewWork extends Component{
} }
handleContentUploadChange = (info) => { handleContentUploadChange = (info) => {
let contentFileList = info.fileList; if (info.file.status === 'uploading' || info.file.status === 'done' || info.file.status === 'removed') {
this.setState({ contentFileList: appendFileSizeToUploadFileAll(contentFileList) }); let contentFileList = info.fileList;
this.setState({ contentFileList: appendFileSizeToUploadFileAll(contentFileList) });
}
} }
handleAnswerUploadChange = (info) => { handleAnswerUploadChange = (info) => {
let answerFileList = info.fileList; if (info.file.status === 'uploading' || info.file.status === 'done' || info.file.status === 'removed') {
this.setState({ answerFileList: appendFileSizeToUploadFileAll(answerFileList) }); let answerFileList = info.fileList;
this.setState({ answerFileList: appendFileSizeToUploadFileAll(answerFileList) });
}
} }
onAttachmentRemove = (file, stateName) => { onAttachmentRemove = (file, stateName) => {

@ -116,7 +116,7 @@ class GraduationTasksSubmitedit extends Component{
this.setState({ fileList:appendFileSizeToUploadFileAll(fileList) }); this.setState({ fileList:appendFileSizeToUploadFileAll(fileList) });
} }
if (info.file.status === 'done') { if (info.file.status === 'done' || info.file.status === 'removed') {
let fileList = info.fileList; let fileList = info.fileList;
this.setState({ fileList:appendFileSizeToUploadFileAll(fileList) }); this.setState({ fileList:appendFileSizeToUploadFileAll(fileList) });
} }

@ -125,7 +125,7 @@ class GraduationTasksSubmitnew extends Component{
this.setState({ fileList:appendFileSizeToUploadFileAll(fileList) }); this.setState({ fileList:appendFileSizeToUploadFileAll(fileList) });
} }
if (info.file.status === 'done') { if (info.file.status === 'done' || info.file.status === 'removed') {
let fileList = info.fileList; let fileList = info.fileList;
this.setState({ fileList:appendFileSizeToUploadFileAll(fileList) }); this.setState({ fileList:appendFileSizeToUploadFileAll(fileList) });
} }

@ -553,7 +553,7 @@ class MemoNew extends Component {
return attachments; return attachments;
} }
handleChange = (info) => { handleChange = (info) => {
if (info.file.status === 'uploading' || info.file.status === 'done') { if (info.file.status === 'uploading' || info.file.status === 'done' || info.file.status === 'removed') {
let fileList = info.fileList; let fileList = info.fileList;
this.setState({ this.setState({
fileList: appendFileSizeToUploadFileAll(fileList) fileList: appendFileSizeToUploadFileAll(fileList)

@ -92,7 +92,7 @@ class CaseNew extends Component{
} }
// 上传附件-change // 上传附件-change
handleContentUploadChange = (info) => { handleContentUploadChange = (info) => {
if (info.file.status === 'done' || info.file.status === 'uploading') { if (info.file.status === 'done' || info.file.status === 'uploading' || info.file.status === 'removed') {
let contentFileList = info.fileList; let contentFileList = info.fileList;
this.setState({ contentFileList: appendFileSizeToUploadFileAll(contentFileList)}); this.setState({ contentFileList: appendFileSizeToUploadFileAll(contentFileList)});
let list = appendFileSizeToUploadFileAll(contentFileList); let list = appendFileSizeToUploadFileAll(contentFileList);

Loading…
Cancel
Save