forked from Gitlink/forgeplus-react
提交成功刷新页面
This commit is contained in:
parent
97e8547c94
commit
fecf0a2b9d
|
@ -68,7 +68,6 @@ export function appendFileSizeToUploadFile(item) {
|
|||
return `${item.title}${uploadNameSizeSeperator}${item.filesize}`
|
||||
}
|
||||
export function appendFileSizeToUploadFileAll(fileList) {
|
||||
console.log('fileList',fileList);
|
||||
return fileList && fileList.map(item => {
|
||||
if(!item.name)item.name=item.fileName;
|
||||
if(!item.uid)item.uid="rc-upload" + item.id;
|
||||
|
|
|
@ -238,7 +238,7 @@ const Qz2022 = (props) => {
|
|||
{/* 提案提交 */}
|
||||
<Route path="/competition/qz2022/refer"
|
||||
render={
|
||||
() => (<Refer {...props} enrollStatus={enrollStatus} qzDetail={qzDetail}/>)
|
||||
() => (<Refer {...props} enrollStatus={enrollStatus} qzDetail={qzDetail} setReload={setReload}/>)
|
||||
}
|
||||
></Route>
|
||||
{/* 交流互动 */}
|
||||
|
|
|
@ -14,7 +14,7 @@ import './index.scss';
|
|||
import '../../index.scss';
|
||||
const Option = Select.Option;
|
||||
|
||||
function Introduce({ form, showNotification, match, history, enrollStatus, current_user, qzDetail}) {
|
||||
function Introduce({ form, showNotification, match, history, enrollStatus, current_user, qzDetail, setReload}) {
|
||||
// 上传文件时 按钮loading效果
|
||||
const [loading, setLoading] = useState(false);
|
||||
const [files, setFiles] = useState();
|
||||
|
@ -76,6 +76,7 @@ function Introduce({ form, showNotification, match, history, enrollStatus, curre
|
|||
}
|
||||
uploadCompetition(params).then(response=>{
|
||||
if(response && response.status === 200){
|
||||
setReload(Math.random());
|
||||
message.success('提交作品成功');
|
||||
}else{
|
||||
message.error(response.data.message);
|
||||
|
|
Loading…
Reference in New Issue