detail update

This commit is contained in:
caishi 2023-06-12 09:38:49 +08:00
parent 937e219a12
commit 322fbb3f03
3 changed files with 14 additions and 7 deletions

View File

@ -39,7 +39,7 @@ const AuthModal: FC<PageProps> = ({
type: 'shixunsDetail/setActionTabs',
payload: {},
});
window.location.href = '/account/certification';
window.location.href = 'https://www.educoder.net/account/certification';
}}
onCancel={() => {
dispatch({

View File

@ -231,7 +231,6 @@ const competitionDetails: FC<PageProps> = ({
let subArr = globalSetting?.setting?.sub_competitions;
if(subArr.length>0){
let filterArr = subArr.filter((i:any)=>i.identifier === item.identifier);
console.log(filterArr);
if(filterArr && filterArr.length >0 ){
setSubComShow(true);
setSubComList(filterArr[0]);
@ -536,7 +535,7 @@ async function JoinTeams(name: any) {
setIsClick(true);
}
}
// console.log('-------',useLocation().query.type);
// console.log('-------',(HeaderDetail.identifier === "track1_2023" || HeaderDetail.identifier === "track2_2023" || HeaderDetail.identifier === "track4_2023" )?false:(StaffDetail.enrolled && !HeaderDetail.need_attachment));
return (
@ -594,7 +593,12 @@ async function JoinTeams(name: any) {
{HeaderDetail.competition_status === "ended" ? <Button type="primary" className={styles.buttonsize} disabled={true} ></Button> : null}
{HeaderDetail.competition_status === 'nearly_published' ? <Button type="primary" className={styles.buttonsize} disabled={true} ></Button> : null}
{HeaderDetail.competition_status !== 'nearly_published' && HeaderDetail.enroll_end && HeaderDetail.competition_status !== 'ended' ? <Button type="primary" className={styles.buttonsize} disabled={true} ></Button> : null}
{HeaderDetail.competition_status === 'progressing' && HeaderDetail.enroll_end != true ? <Button type="primary" disabled={StaffDetail.enrolled && !HeaderDetail.need_attachment} className={styles.buttonsize} onClick={
{HeaderDetail.competition_status === 'progressing' && HeaderDetail.enroll_end != true ?
<Button
type="primary"
disabled={(HeaderDetail.identifier === "track1_2023" || HeaderDetail.identifier === "track2_2023" || HeaderDetail.identifier === "track4_2023" )?false:(StaffDetail.enrolled && !HeaderDetail.need_attachment)}
className={styles.buttonsize}
onClick={
(e) => {
if (StaffDetail.enrolled && HeaderDetail.need_attachment) {
see.current?.handleVisible()
@ -602,7 +606,7 @@ async function JoinTeams(name: any) {
}
gotocourse(e, HeaderDetail, HeaderDetail.mode === 2 ? 'ismodel' : HeaderDetail.personal ? 'personal' : `/competitions/index/${HeaderDetail.identifier}/enroll`)
}
}>{StaffDetail.enrolled ? HeaderDetail.need_attachment ? '上传作品' : '已报名' : HeaderDetail?.enroll_url ? '前往大赛官网报名' : '立即报名'}</Button> : null}
}>{StaffDetail.enrolled ? ((HeaderDetail.identifier === "track1_2023" || HeaderDetail.identifier === "track2_2023" || HeaderDetail.identifier === "track4_2023" ) ? "立即报名" : HeaderDetail.need_attachment ? '上传作品' : '已报名') : (HeaderDetail?.enroll_url ? '前往大赛官网报名' : '立即报名')}</Button> : null}
</div>

View File

@ -324,7 +324,10 @@ const competitionsIndexPage: FC<PageProps> = ({
setshowphone(true)
return
}
if(item.identifier === "track4_2023" || item.identifier === "track2_2023" || item.identifier === "track1_2023"){
openNewWindow(`/competitions/index/${item.identifier}`);
return;
}
let data =await dispatch({
type: 'competitions/GetKylinId',
payload: {