forked from Gitlink/forgeplus-react
学生报名页面删除2022年的时间判断
This commit is contained in:
parent
5672b3a73e
commit
f5b0b07f33
|
|
@ -53,19 +53,9 @@ function Apply(props) {
|
|||
|
||||
useEffect(() => {
|
||||
// 进入此页面到填写页面
|
||||
// setTimeout(()=>{
|
||||
// let clientWidth = document.body.clientWidth;
|
||||
// let scrollHeight = 500 * clientWidth / 1920;
|
||||
// window.scrollTo(0, scrollHeight);
|
||||
// },200);
|
||||
window.scrollTo(0, 50);
|
||||
|
||||
if (new Date().getTime() < new Date('2022/05/26').getTime()) {
|
||||
// 不在开源夏令营报名时间之内
|
||||
window.location.href = "/glcc/subjects";
|
||||
} else if (current_user && current_user.login) {
|
||||
|
||||
} else {
|
||||
// 未登录
|
||||
if (current_user && !current_user.login){
|
||||
window.location.href = `/login?go_page=/glcc/student/apply/${taskId}`;
|
||||
}
|
||||
}, [])
|
||||
|
|
|
|||
Loading…
Reference in New Issue