forked from Gitlink/forgeplus-react
Merge pull request '更新' (#528) from durian/forgeplus-react:pre_dev_military into pre_dev_military
This commit is contained in:
commit
c85ccf403a
File diff suppressed because it is too large
Load Diff
|
|
@ -141,30 +141,50 @@ const Competition = (props) => {
|
|||
})
|
||||
}, [reload])
|
||||
|
||||
function getTime(data){
|
||||
return Date.parse(data || new Date());
|
||||
}
|
||||
|
||||
let applyStatus; // 是否处于报名阶段
|
||||
let referStatus; // 是否处于提交作品阶段
|
||||
let referEnd; // 是否处于提交作品阶段(提交已经结束)
|
||||
if (qzDetail) {
|
||||
applyStatus = Date.parse(new Date()) < Date.parse(new Date(qzDetail.enroll_date));
|
||||
referStatus = !applyStatus && Date.parse(new Date()) < Date.parse(new Date(qzDetail.upload_date));
|
||||
referEnd = Date.parse(new Date()) > Date.parse(new Date(qzDetail.upload_date));
|
||||
const {start_at, enroll_date, upload_date} = qzDetail
|
||||
applyStatus = start_at ? (getTime() > getTime(start_at) && getTime() < getTime(enroll_date)) : getTime() < getTime(enroll_date);
|
||||
referStatus = !applyStatus && getTime() < getTime(upload_date);
|
||||
referEnd = getTime() > getTime(upload_date);
|
||||
}
|
||||
|
||||
// 参赛报名
|
||||
function applyCompetition(){
|
||||
if(!applyStatus){
|
||||
props.showNotification(getTime() > getTime(qzDetail && qzDetail.enroll_date) ? "报名时间已截止!" : "暂未开始报名");
|
||||
}else if(current_user && !current_user.login){
|
||||
props.showLoginDialog();
|
||||
}else{
|
||||
history.push(`/competition/${competitionId}/apply`);
|
||||
}
|
||||
}
|
||||
|
||||
function goToRefer() {
|
||||
if (current_user && !current_user.login) {
|
||||
if(applyStatus){
|
||||
props.showNotification("竞赛尚未开始提交作品!");
|
||||
}else if(referEnd){
|
||||
props.showNotification("比赛已结束!");
|
||||
}else if(current_user && !current_user.login){
|
||||
props.showLoginDialog();
|
||||
} else if (enrollStatus && !enrollStatus.enroll_status) {
|
||||
}else if(enrollStatus && !enrollStatus.enroll_status){
|
||||
props.showNotification("您还未报名竞赛!");
|
||||
} else if (enrollStatus && enrollStatus.status === 0) {
|
||||
props.showNotification("报名信息被管理员驳回!");
|
||||
} else if ( competitionId === 'zstp2022' && enrollStatus && !enrollStatus.second_round) {
|
||||
props.showNotification("很遗憾,您未进入复赛!");
|
||||
} else if (['ccks', 'zstp2022'].includes(competitionId) && enrollStatus && enrollStatus.status === 1) {
|
||||
props.showNotification("您的报名信息未通过审核!");
|
||||
} else if(['ccks', 'zstp2022'].includes(competitionId) && applyStatus ){
|
||||
} else if (enrollStatus && enrollStatus.status === 1) {
|
||||
props.showNotification("您的报名信息暂未通过审核!");
|
||||
}else{
|
||||
!referStatus ? props.showNotification(!referEnd ? `竞赛尚未开始提交作品,提交作品开始时间为:${qzDetail && qzDetail.enroll_date.substring(0, 10)}` : "比赛已结束") : "";
|
||||
history.push(`/competition/${competitionId}/refer`);
|
||||
}
|
||||
// else if ( competitionId === 'zstp2022' && enrollStatus && !enrollStatus.second_round) {
|
||||
// props.showNotification("很遗憾,您未进入复赛!");
|
||||
// }
|
||||
}
|
||||
|
||||
// 关注和取消关注
|
||||
|
|
@ -228,7 +248,9 @@ const Competition = (props) => {
|
|||
<Link to={{ pathname: `/competition/${competitionId}/notice` }}>通知公告</Link>
|
||||
</li>
|
||||
{/* 处于报名阶段正常跳转到报名页面,不处于右侧弹消息 */}
|
||||
{competitionId === 'qz2022' ? <li className={active === "apply" ? "active" : ""}>
|
||||
<li className={active === "apply" ? "active" : ""}><a onClick={applyCompetition}>参赛报名</a></li>
|
||||
<li className={['refer', 'record'].includes(active) ? "active" : ""}><a onClick={goToRefer}>提案提交</a></li>
|
||||
{/* {competitionId === 'qz2022' ? <li className={active === "apply" ? "active" : ""}>
|
||||
<Link to={{ pathname: applyStatus && current_user && current_user.login ? `/competition/${competitionId}/apply` : '' }} onClick={() => { current_user && current_user.login ? !applyStatus && props.showNotification("报名时间已截止") : props.showLoginDialog() }}>参赛报名</Link>
|
||||
</li> : <li className={active === "apply" ? "active" : ""}>
|
||||
<Link to={{ pathname: applyStatus||( enrollStatus && enrollStatus.status>1) && current_user && current_user.login ? `/competition/${competitionId}/apply` : '' }} onClick={() => { current_user && current_user.login ? !applyStatus&& ( enrollStatus && enrollStatus.status<2 ) && props.showNotification("报名时间已截止") : props.showLoginDialog() }}>参赛报名</Link>
|
||||
|
|
@ -239,7 +261,7 @@ const Competition = (props) => {
|
|||
</li> :
|
||||
<li className={['refer', 'record'].includes(active) ? "active" : ""}>
|
||||
<Link to={{ pathname: !referEnd && current_user && current_user.login && enrollStatus && enrollStatus.status>1 && enrollStatus.second_round ? `/competition/${competitionId}/refer` : '' }} onClick={goToRefer}>提案提交</Link>
|
||||
</li>}
|
||||
</li>} */}
|
||||
|
||||
{
|
||||
['ccks', 'zstp2022'].includes(competitionId) && <li className={active === "rank" ? "active" : ""}>
|
||||
|
|
@ -317,7 +339,7 @@ const Competition = (props) => {
|
|||
{/* 参赛报名 */}
|
||||
<Route path="/competition/:competitionId/apply"
|
||||
render={
|
||||
() => (<Apply {...props} qzDetail={qzDetail} enrollStatus={enrollStatus} setReload={setReload} />)
|
||||
() => (<Apply {...props} qzDetail={qzDetail} applyStatus={applyStatus} enrollStatus={enrollStatus} setReload={setReload} />)
|
||||
}
|
||||
></Route>
|
||||
{/* 模拟结果 */}
|
||||
|
|
@ -329,7 +351,7 @@ const Competition = (props) => {
|
|||
{/* 提案提交 */}
|
||||
<Route path="/competition/:competitionId/refer"
|
||||
render={
|
||||
() => (<Refer {...props} enrollStatus={enrollStatus} qzDetail={qzDetail} setReload={setReload} />)
|
||||
() => (<Refer {...props} referStatus={referStatus} enrollStatus={enrollStatus} qzDetail={qzDetail} setReload={setReload} />)
|
||||
}
|
||||
></Route>
|
||||
{/* 排行榜 */}
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ export default Form.create()((props) => {
|
|||
current_user,
|
||||
history,
|
||||
match,
|
||||
applyStatus
|
||||
} = props;
|
||||
const { competitionId } = match.params;
|
||||
|
||||
|
|
@ -41,9 +42,6 @@ export default Form.create()((props) => {
|
|||
// 上传文件时 按钮loading效果
|
||||
const [files, setFiles] = useState([]);
|
||||
useEffect(() => {
|
||||
const applyStatus = qzDetail
|
||||
? Date.parse(new Date()) < Date.parse(new Date(qzDetail.enroll_date))
|
||||
: true;
|
||||
if ((current_user && !current_user.login) || (!applyStatus && (enrollStatus && enrollStatus.status<2))) {
|
||||
history.push(`/competition/${competitionId}`);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ export default Form.create()((props) => {
|
|||
current_user,
|
||||
history,
|
||||
match,
|
||||
applyStatus
|
||||
} = props;
|
||||
const { competitionId } = match.params;
|
||||
|
||||
|
|
@ -41,9 +42,6 @@ export default Form.create()((props) => {
|
|||
// 上传文件时 按钮loading效果
|
||||
const [files, setFiles] = useState([]);
|
||||
useEffect(() => {
|
||||
const applyStatus = qzDetail
|
||||
? Date.parse(new Date()) < Date.parse(new Date(qzDetail.enroll_date))
|
||||
: true;
|
||||
if ((current_user && !current_user.login) || (!applyStatus && (enrollStatus && enrollStatus.status < 2))) {
|
||||
history.push(`/competition/${competitionId}`);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ import apply_notice from "../image/apply_notice.png";
|
|||
const Option = Select.Option;
|
||||
|
||||
export default Form.create()((props) => {
|
||||
const {form, qzDetail, enrollStatus, setReload, current_user, history,match} = props;
|
||||
const {form, qzDetail, enrollStatus, setReload, current_user, history,match, applyStatus} = props;
|
||||
const { competitionId } = match.params;
|
||||
|
||||
const {getFieldDecorator, validateFields, setFieldsValue} = form;
|
||||
|
|
@ -28,7 +28,6 @@ export default Form.create()((props) => {
|
|||
const [loading, setLoading] = useState(false);
|
||||
const [files, setFiles] = useState([]);
|
||||
useEffect(()=>{
|
||||
const applyStatus = qzDetail ? Date.parse(new Date()) < Date.parse(new Date(qzDetail.enroll_date)) : true;
|
||||
if((current_user && !current_user.login) || !applyStatus){
|
||||
history.push(`/competition/${competitionId}`);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,6 +55,16 @@ export default Form.create()((props) => {
|
|||
}
|
||||
})
|
||||
}
|
||||
|
||||
// 添加模板
|
||||
function addTemplate(value){
|
||||
let template = '<div style="font-family:fangsongGB2312; font-size:21px; line-height:38px; background-color:#fff; padding:60px;">\n<div style="font-family:黑体;"> 一、大赛简介</div>\n 大赛名称:请输入赛事名称<br/>\n 大赛主题:请输入赛事主题<br/>\n 赛区设置:请输入子赛区或子赛项设置<br/>\n 提案要求: 请输入作品提交要求<br/>\n 参赛报名网址: 请输入参赛报名网址<br/>\n 赛事安排: 请输入赛事时间安排<br/>\n 奖励激励: 请输入赛事奖金及奖励方式<br/>\n 联系方式:请输入赛事主办方、承办方联系方式<br/>\n 大赛LOGO:\n<center><img src="https://osredm.com/api/attachments/6279" width="70%" height="70%"></center>\n<div style="font-family:黑体;"> 二、参赛报名</div>\n 请输入参赛报名内容\n<div style="font-family:黑体;"> 三、提案提交</div>\n 请输入提案提交时间安排及提交要求\n<div style="font-family:黑体;"> 四、其他事项</div>\n (一)事项一<br/>\n (二)事项二<br/>\n (三)事项三<br/>\n (四)事项四<br/>\n <a href="请输入附件1下载链接">附件1 </a><br/>\n <a href="请输入附件2下载链接">附件2 </a><br/>\n <a href="请输入附件3下载链接">附件3</a><br/>\n <a href="请输入附件4下载链接">附件4</a><br/></div>';
|
||||
if(!value){
|
||||
template = '<div style="font-family:fangsongGB2312; font-size:21px; line-height:38px; background-color:#fff; padding:8%">\n<div style="font-family:黑体; font-size:21px;">一、赛事简介</div>\n 请输入赛事简介<br/><br/>\n<div style="font-family:黑体; font-size:21px;">二、任务提交及评分</div>\n 请输入任务提交及评分内容<br/><br/>\n<div style="font-family:黑体; font-size:21px;">三、报名方式</div>\n 请输入报名方式<br/><br/>\n<div style="font-family:黑体; font-size:21px;">四、奖励设置</div>\n 任务共提供XX万元奖金给X支获奖团队,奖金设置如下:\n<div style="margin-left: 3%"><ul>\n<li>第一名:12,000元</li>\n<li>第二名:10,000元</li>\n<li>第三名: 8,000元</li>\n<li>创新奖: 5,000元</li></ul></div><br/>\n<div style="font-family:黑体; font-size:21px;">五、时间安排</div>\n 时间安排初定如下,后续如果有调整,以官方发布信息为准:<div style="margin-left: 3%"><ul><li>评测任务发布:XXXX年XX月XX日</li>\n<li>数据发布:XXXX年XX月XX日</li>\n<li>报名时间:XXXX年XX月XX日</li>\n<li>初赛打榜时间:XXXX年XX月XX日</li>\n<li>复赛打榜时间:XXXX年XX月XX日</li>\n<li>任务想定发布:XXXX年XX月XX日</li>\n<li>结果提交:XXXX年XX月XX日</li>\n<li>评测论文提交:XXXX年XX月XX日</li>\n<li>会议日期(评测报告及颁奖):XXXX年XX月XX日</li></ul></div><br/>\n<div style="font-family:黑体; font-size:21px;">六、常见问题</div>\n(一)问:问题内容?<br/> 答:回答内容<br/>\n(二)问:问题内容?<br/> 答:回答内容<br/><br/>\n <a href="请输入附件1下载链接">附件1</a><br/>\n <a href="请输入附件2下载链接">附件2</a><br/></div>'
|
||||
}
|
||||
setDescription(description+template);
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="qz_notice">
|
||||
<div className="qz_main notice_detal qz2022_notice_edit">
|
||||
|
|
@ -85,6 +95,12 @@ export default Form.create()((props) => {
|
|||
initValue={description}
|
||||
onChange={(value)=>{setDescription(value)}}
|
||||
></MDEditor>
|
||||
{/* 添加模板 */}
|
||||
{type === "fingerpost" && <div>
|
||||
<span className="mb10 mr10">添加模板:</span>
|
||||
<a onClick={()=>{addTemplate(1)}} className="mr10">模板A</a>
|
||||
<a onClick={()=>{addTemplate(0)}}>模板B</a>
|
||||
</div>}
|
||||
</div>
|
||||
</Form>
|
||||
<div className="qz2022_notice_but">
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import React, {useState, useCallback} from "react";
|
||||
import React, {useState, useCallback, useEffect} from "react";
|
||||
import Qz2022 from './qz2022';
|
||||
import Ccks from './ccks';
|
||||
import Jqtj from './jqtj';
|
||||
|
|
@ -7,9 +7,13 @@ import './index.scss';
|
|||
import '../index.scss';
|
||||
|
||||
export default (props)=>{
|
||||
const {match} = props;
|
||||
const {match, qzDetail, history} = props;
|
||||
const { competitionId } = match.params;
|
||||
|
||||
useEffect(()=>{
|
||||
if(qzDetail && !qzDetail.is_manager){
|
||||
history.push(`/competition/${competitionId}`);
|
||||
}
|
||||
}, [qzDetail])
|
||||
return(
|
||||
competitionId=="qz2022"? <Qz2022 {...props} />:competitionId=="zstp2022"? <Ccks {...props} />:<Jqtj {...props} />
|
||||
)
|
||||
|
|
|
|||
|
|
@ -176,18 +176,18 @@ function Introduce({ history: { location: { pathname } }, qzDetail, match }) {
|
|||
return <Tooltip title={text[0] && text[0].title} placement="topLeft"><a href={current_main_site_url + (text[0] && text[0].url)} className="attachments_a">{text[0] && text[0].title}</a></Tooltip>;
|
||||
}
|
||||
},
|
||||
// {
|
||||
// title: '操作',
|
||||
// dataIndex: "status",
|
||||
// align: "center",
|
||||
// render: (text, record) => {
|
||||
// return text === 1 ? <Button size="small" disabled>已驳回</Button> : <Popconfirm
|
||||
// title="您确定驳回此用户的作品信息?"
|
||||
// icon={<i className="iconfont icon-shanchu_tc_icon mr3 font-15" style={{ float: 'left', color: "red" }}></i>}
|
||||
// onConfirm={() => { reject(record.user_id, 2) }}
|
||||
// ><Button size="small">驳回</Button></Popconfirm>
|
||||
// }
|
||||
// }
|
||||
{
|
||||
title: '操作',
|
||||
dataIndex: "status",
|
||||
align: "center",
|
||||
render: (text, record) => {
|
||||
return text === 2 ? <Button size="small" disabled>已驳回</Button> : <Popconfirm
|
||||
title="您确定驳回此用户的作品信息?"
|
||||
icon={<i className="iconfont icon-shanchu_tc_icon mr3 font-15" style={{ float: 'left', color: "red" }}></i>}
|
||||
onConfirm={() => { reject(record.user_id, 2) }}
|
||||
><Button size="small">驳回</Button></Popconfirm>
|
||||
}
|
||||
}
|
||||
];
|
||||
}, [qzDetail]);
|
||||
|
||||
|
|
|
|||
|
|
@ -66,6 +66,22 @@ export default Form.create()((props) => {
|
|||
}
|
||||
})
|
||||
}
|
||||
|
||||
// 添加模板
|
||||
function addTemplate(value){
|
||||
let template = description || '';
|
||||
switch(value){
|
||||
case 0:
|
||||
template += '<div style="font-family:fangsongGB2312; font-size:21px; line-height:38px;">“XXX”大赛正式拉开帷幕,现开启报名!<br/><br/>\n<div style="font-family:黑体; font-size:20px;">(一)报名时间</div>\n<div> 请输入报名时间(XXXX年XX月XX日)</div>\n<br/>\n<div style="font-family:黑体; font-size:20px;">(二)提案提交时间</div>\n<div> 请输入提案提交时间(XXXX年XX月XX日)</div>\n<br/>\n<div style="font-family:黑体; font-size:20px;">(三)预赛时间</div>\n<div> 请输入预赛时间(XXXX年XX月XX日)</div>\n<br/>\n<div style="font-family:黑体; font-size:20px;">(四)决赛时间</div>\n<div> 请输入决赛时间(XXXX年XX月XX日)</div>\n<br/>\n<div style="font-family:黑体; font-size:20px;">(五)报名链接</div>\n <a href="请输入报名链接">请输入报名链接</a>\n</div>';
|
||||
break;
|
||||
case 1:
|
||||
template += '<div style="font-family: fangsongGB2312; font-size: 22px; line-height: 38px; background-color: #fff; padding: 6%; margin: 3%;">\n<div style="font-family: KaiTi; font-size: 25px;">各参赛战队:</div>\n 目前,共计X支参赛战队进入复赛,名单如下:<div class="CCKS2022_table">\n<table style="width: 90%; table-layout: fixed; margin: 3% auto;text-align: center;">\n<thead>\n<tr>\n<th style="width: 10%;">名次</th>\n<th style="width: 40%;"> 参赛单位</th>\n<th style="width: 10%;"> 参赛队长</th>\n<th style="width: 20%;">重复三元组个数</th>\n<th style="width: 10%;">分数</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>1</td>\n<td>请输入参赛单位</td>\n<td>请输入参赛者姓名</td>\n<td>请输入个数</td>\n<td>请输入分数</td>\n</tr>\n<tr>\n<td>2</td>\n<td>请输入参赛单位</td>\n<td>请输入参赛者姓名</td>\n<td>请输入个数</td>\n<td>请输入分数</td>\n</tr>\n</tbody>\n</table>\n</div>\n<br/><br/>\n<div style=" text-align: right;">赛事组织方</div>\n<div style=" text-align: right;">XXXX年XX月XX日</div>\n</div>';
|
||||
break;
|
||||
default:
|
||||
template += '<div style="font-family: fangsongGB2312; font-size: 21px; line-height: 38px; background-color: #fff; padding: 6%; margin: 3%;">\n<div style="font-family: KaiTi;">xxx:</div>\n xxxx内容<br/><br/>\n<a href="请输入附件地址"> 附件:请输入附件标题</a>\n<br/>\n<br/>\n<div style=" text-align: right;">赛事工作办公室</div>\n<div style=" text-align: right;">XXXX年XX月XX日</div>\n</div>';
|
||||
}
|
||||
setDescription(template);
|
||||
}
|
||||
return (
|
||||
<div className="qz_notice">
|
||||
<div className="qz_main notice_detal pt30">
|
||||
|
|
@ -96,6 +112,13 @@ export default Form.create()((props) => {
|
|||
initValue={description}
|
||||
onChange={(value)=>{setDescription(value)}}
|
||||
></MDEditor>
|
||||
{/* 添加模板 */}
|
||||
<div>
|
||||
<span className="mb10 mr10">添加模板:</span>
|
||||
<a onClick={()=>{addTemplate(0)}} className="mr10">模板A</a>
|
||||
<a onClick={()=>{addTemplate(1)}} className="mr10">模板B</a>
|
||||
<a onClick={()=>{addTemplate(2)}}>模板c</a>
|
||||
</div>
|
||||
</div>
|
||||
</Form>
|
||||
<div className="qz2022_notice_but">
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ function Introduce({ form, showNotification, match, history, enrollStatus, curre
|
|||
}
|
||||
|
||||
useEffect(() => {
|
||||
if (enrollStatus && (!enrollStatus.upload_status || enrollStatus.upload_status === 1)) {
|
||||
if (enrollStatus && (!enrollStatus.upload_status || enrollStatus.upload_status === 2)) {
|
||||
setUpload(true);
|
||||
}
|
||||
}, [enrollStatus])
|
||||
|
|
@ -82,15 +82,15 @@ function Introduce({ form, showNotification, match, history, enrollStatus, curre
|
|||
|
||||
// 进行文件大小检查
|
||||
function beforeUpload(file) {
|
||||
const isZip = file.name.endsWith(".csv");
|
||||
if (!isZip) {
|
||||
showNotification(`只能上传csv文件`);
|
||||
}
|
||||
// const isZip = file.name.endsWith(".csv");
|
||||
// if (!isZip) {
|
||||
// showNotification(`只能上传csv文件`);
|
||||
// }
|
||||
const isLt100M = file.size / 1024 / 1024 < 50;
|
||||
if (!isLt100M) {
|
||||
showNotification(`文件大小必须小于${50}MB!`);
|
||||
}
|
||||
return isLt100M && isZip;
|
||||
return isLt100M;
|
||||
}
|
||||
|
||||
// 作品提交
|
||||
|
|
@ -128,9 +128,9 @@ function Introduce({ form, showNotification, match, history, enrollStatus, curre
|
|||
<div className="refer_tit">上传作品</div>
|
||||
{upload ? <div className="refer_content">
|
||||
<img src={ccks_upload} className="refer_img mb20" alt="" />
|
||||
<div className="refer_tip">请上传utf-8编码格式的csv格式作品</div>
|
||||
<div className="refer_tip">请上传小于50M的作品</div>
|
||||
<Upload
|
||||
accept=".csv"
|
||||
// accept=".csv"
|
||||
// 开发时 action需要添加?debug=admin
|
||||
action={getUploadActionUrl}
|
||||
fileList={files}
|
||||
|
|
@ -144,13 +144,14 @@ function Introduce({ form, showNotification, match, history, enrollStatus, curre
|
|||
</div>
|
||||
: <div className="refer_content">
|
||||
<img src={ccks_upload_success} className="refer_img mb20" alt="" />
|
||||
<div className="refer_tip">您的作品已上传成功,可在排行榜实时查看作品得分</div>
|
||||
<div className="refer_tip">您的作品已上传成功</div>
|
||||
</div>
|
||||
}
|
||||
|
||||
{
|
||||
Array.isArray(files) && files.map(i => {
|
||||
return <div className="ccks_csv" key={i.name}><img src={ccks_csv} className="ccks_csv_img" alt="" />
|
||||
return <div className="ccks_csv" key={i.name}>
|
||||
<i className="iconfont icon-wenjian5 mr5"></i>
|
||||
<a href={getImageUrl(i.url)}>{i.name} <span className="filesize">{i.filesize}</span></a>
|
||||
{enrollStatus && enrollStatus.enroll_info && enrollStatus.enroll_info && enrollStatus.enroll_info.api_result_text && <div className="error_text">{enrollStatus.enroll_info.api_result_text}</div>}
|
||||
</div>
|
||||
|
|
@ -171,7 +172,7 @@ function Introduce({ form, showNotification, match, history, enrollStatus, curre
|
|||
cancelText=""
|
||||
>
|
||||
<div className="tips mb10"><i className="iconfont icon-shanchu_tc_icon1 font-24 mr10" style={{ color: '#ffa13a' }}></i><span className="tipTitle font-16">确定提交作品</span></div>
|
||||
<span>可重复提交,每天最多可提交 <span className="refer-times">{qzDetail&&qzDetail.api_score_times}</span> 次作品!</span>
|
||||
{/* {qzDetail && qzDetail.api_score_times && <span>可重复提交,每天最多可提交 <span className="refer-times">{qzDetail.api_score_times}</span> 次作品!</span>} */}
|
||||
</Modal>
|
||||
</div>
|
||||
)
|
||||
|
|
|
|||
|
|
@ -4,11 +4,19 @@ import Ccks from './ccks';
|
|||
import Jqtj from './jqtz';
|
||||
import './index.scss';
|
||||
import '../index.scss';
|
||||
import { useEffect } from "react";
|
||||
|
||||
export default (props)=>{
|
||||
const {match} = props;
|
||||
const {match, referStatus, history} = props;
|
||||
const { competitionId } = match.params;
|
||||
|
||||
|
||||
useEffect(()=>{
|
||||
// 不在提交作品时间范围
|
||||
if(!referStatus){
|
||||
history.push(`/competition/${competitionId}`);
|
||||
}
|
||||
}, [referStatus])
|
||||
|
||||
return(
|
||||
competitionId=="qz2022"? <Qz2022 {...props} />: (competitionId=="JQTJ" || competitionId=="jqtj") ? <Jqtj {...props}/>: <Ccks {...props} />
|
||||
)
|
||||
|
|
|
|||
|
|
@ -130,6 +130,10 @@
|
|||
width: 34px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
&>.icon-wenjian5{
|
||||
position: relative;
|
||||
top: -3px;
|
||||
}
|
||||
.filesize {
|
||||
margin-left: 10px;
|
||||
color: #90a0b2;
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ export default (props) => {
|
|||
{item.enterpriseName=="taohuayuan" && <img className="chuangke_icon" src={chuangke_icon}/>}
|
||||
<div className="title-content text-ellipsis">{item.name}</div>
|
||||
{/* 为创客行动特地加的标签,以后会去除 */}
|
||||
{item.status && <span className={classArr[item.status]}>{item.exceptClosedBoolean ? '已关闭' : statusArr[item.status]}</span>}
|
||||
{item.status && <span className={`${classArr[item.status]} ${item.exceptClosedBoolean ? '' : "completed"}`}>{item.exceptClosedBoolean ? '已关闭' : statusArr[item.status]}</span>}
|
||||
{(item.status !== 8) && item.delayTime.indexOf('延期') > -1 ? <span className="list-yellow">延期中</span>
|
||||
: <React.Fragment>
|
||||
{(item.status !== 8) && item.cancelStatus === 1 && <span className="list-yellow">手动延期中</span>}
|
||||
|
|
|
|||
|
|
@ -103,6 +103,9 @@ span.list-error {
|
|||
|
||||
span.list-gray {
|
||||
background: #bababa;
|
||||
&.completed{
|
||||
background: #4154f1;
|
||||
}
|
||||
}
|
||||
|
||||
.center-content .ant-pagination {
|
||||
|
|
|
|||
Loading…
Reference in New Issue