diff --git a/src/AppConfig.js b/src/AppConfig.js index e102edbe1..45f12c805 100644 --- a/src/AppConfig.js +++ b/src/AppConfig.js @@ -101,7 +101,7 @@ export function initAxiosInterceptors(props) { // 邀请页面不进行404跳转 if( window.location.pathname.includes('/invite') && (responseURL.includes('/simple.json')||responseURL.includes('/detail.json')||responseURL.includes('/menu_list.json'))){ }else{ - // locationurl('/nopage'); + locationurl('/nopage'); } } } diff --git a/src/forge/Component/Component.scss b/src/forge/Component/Component.scss index 1a08309f2..d9680dd50 100644 --- a/src/forge/Component/Component.scss +++ b/src/forge/Component/Component.scss @@ -113,7 +113,7 @@ li.ant-menu-item{ z-index: 10000; } .laterest{ - background-color: #EF3131; + background-color: #4baf50; color: #fff; font-size: 12px; margin-left: 10px; diff --git a/src/forge/Information/Pages/headerPageZone1.jsx b/src/forge/Information/Pages/headerPageZone1.jsx index c1893c61c..92735fa8e 100644 --- a/src/forge/Information/Pages/headerPageZone1.jsx +++ b/src/forge/Information/Pages/headerPageZone1.jsx @@ -1,8 +1,22 @@ import React,{ useState, useEffect } from 'react'; import { httpUrl } from '../fetch'; - -import img1 from '../img/img1.png'; -import img2 from '../img/img2.png'; +import { Button , Anchor } from 'antd'; +import { Link } from 'react-router-dom'; +import arrowWhite from '../img/zone1/jiantouwhite.png'; +import xinpian from '../img/zone1/xinpian.png'; +import system from '../img/zone1/system.png'; +import chain from '../img/zone1/chain.png'; +import eda from '../img/zone1/EDA.png'; +import fu from '../img/zone1/fu.png'; +import team1 from '../img/zone1/team1.png'; +import team2 from '../img/zone1/team2.png'; +import team3 from '../img/zone1/team3.png'; +import team4 from '../img/zone1/team4.png'; +import window from '../img/zone1/window.png'; +import phone from '../img/zone1/phone.png'; +import line from '../img/zone1/line.png'; +import zhao from '../img/zone1/zhao.png'; +import sys from '../img/zone1/sys.png'; import vision0 from '../img/vision0.png'; import vision1 from '../img/vision1.png'; import vision2 from '../img/vision2.png'; @@ -14,20 +28,19 @@ import intro4 from '../img/intro4.png'; import guideArrow from '../img/guideArrow1.png'; import ra from '../img/ra.png' import title from '../img/title.png' -import { Link } from 'react-router-dom'; -import shijian from '../img/shijian.png'; -import Nodata from '../../Nodata'; -import Projects from '../Component/projects'; -import Contributor from '../Component/contributor'; import Partner from '../Component/partner'; -import '../indexZone1.scss' -import { getProjectsLists, getPartnerList, getHomePageList, gethomePageDocList } from '../api' +import '../indexZone1.scss'; +import { getProjectsLists, getPartnerList, getHomePageList, gethomePageDocList , getDocList , getSubDocList } from '../api' + function HeaderPage(props){ - const [ projectList , setProjectList ] = useState(undefined); + // const [ projectList , setProjectList ] = useState(undefined); const [ personList , setPersonList ] = useState(undefined); - const [ newsList, setNewsList ] = useState(undefined); + // const [ newsList, setNewsList ] = useState(undefined); const [ partnerList, setParterList ] = useState(undefined); + const [ recruitId, setRecruitId ] = useState(undefined); + const [ recruitList, setRecruitList ] = useState(undefined); + const [ showAnchor, setShowAnchor ] = useState(false); const { deptId } = props.match.params; const { data, id, temp, history } = props; @@ -52,22 +65,43 @@ function HeaderPage(props){ { type: '计划四', plan: '香山贡献参与' } ] + const introDetail = [ { title: '能力阶梯', icon: intro1, desc: '成长体系按照开发者从⼊门到进阶再到⾹⼭顶级项⽬设⽴了⽤户能⼒提升的阶梯式真实项⽬' }, { title: '贡献分级', icon: intro2, desc: '所有开源项⽬全部为开芯院开源开放的真实项⽬,开发者参与开源项⽬的所有贡献将作为成长等级、知产授权、加⼊⾼级别项⽬(悬赏、获得offer等)、成为核⼼贡献者的参与 依据' }, { title: '成长认证', icon: intro3, desc: '开发者可以通过完成开源项⽬对应的任务,赢取对应能⼒成长认证,开源项⽬对应的⾼级任务将获得对应等级L2或⾼级别的知识产权授权,同时解锁下⼀级别成长任务' }, { title: '顶级认证', icon: intro4, desc: '参与顶级项⽬“⾹⼭”的贡献者,将获得中国科学院计算技术研究所副所长、研究员,北京开源芯⽚研究院⾸席科学家,RISC-V国际基⾦会理事会成员包云岗签名贡献者证书' } ] + useEffect(()=>{ + if(id){ + // getProjectList(); + // getNewsList(); + getPersonList(); + getPartner(); + getHomeDocList(); + } + },[id]) useEffect(()=>{ - if(id){ - getProjectList(); - getNewsList(); - getPersonList(); - getPartner(); + document.addEventListener("scroll", scroll); + if(recruitId){ + getDocById(recruitId) } - },[id]) + return () => { + document.removeEventListener("scroll", scroll); + }; + },[recruitId]) + + + const scroll = () =>{ + let sTop = document.documentElement.scrollTop; + if(sTop >= 2000){ + setShowAnchor(true); + }else{ + setShowAnchor(false); + } + } function getPersonList(){ getHomePageList(id).then(result=>{ @@ -76,25 +110,46 @@ function HeaderPage(props){ } }).catch(error=>{}) } - - function getNewsList(){ - gethomePageDocList(id).then(result=>{ - if(result){ - setNewsList(result.data.rows); - } - }).catch(error=>{}) - } - function getProjectList(){ - getProjectsLists(id,{ isHomepage:1 }).then(result=>{ - if(result){ - if (result.data.rows.length < 3) { - setProjectList(result.data.rows) - } else { - setProjectList([...result.data.rows, {}]); + // 获取所有栏目,找到招聘专栏拿到其id + function getHomeDocList(){ + getDocList(id).then(result=>{ + if(result && result.data.rows){ + let rows = result.data.rows; + let filterRow = rows ? rows.filter(i=>i.name === "招聘专栏") : undefined; + if(filterRow && filterRow.length>0){ + setRecruitId(filterRow[0].id); } } - }).catch(error=>{}) + }) } + // 根据招聘专栏的id获取其栏目下的招聘文章 + function getDocById(recruitId){ + getSubDocList(recruitId,{pageSize:4,pageNum:1,auditStatus:1}).then(result=>{ + if(result && result.data.rows){ + let rows = result.data.rows; + setRecruitList(rows); + } + }) + } + + // function getNewsList(){ + // gethomePageDocList(id).then(result=>{ + // if(result){ + // setNewsList(result.data.rows); + // } + // }).catch(error=>{}) + // } + // function getProjectList(){ + // getProjectsLists(id,{ isHomepage:1 }).then(result=>{ + // if(result){ + // if (result.data.rows.length < 3) { + // setProjectList(result.data.rows) + // } else { + // setProjectList([...result.data.rows, {}]); + // } + // } + // }).catch(error=>{}) + // } function getPartner(){ getPartnerList(id).then(result => { @@ -115,8 +170,220 @@ function HeaderPage(props){ }) } return( -
- { +
+ {showAnchor && + + + + {recruitList && recruitList.length > 0 && } + {data && data.partnersShow === 1 && partnerList && partnerList.length > 0 && } + + + } + +
+

芯片设计创新链

+

欢迎开源芯片企业、高校、开发者、学生参与社区

+
+
+
  • + FPGA商业FPGA +
  • +
  • + FPGA云平台 + 服务“香山”的开源FPGA云平台 +
  • +
    +
  • + SOC + 常开域:LCLKGEN、WatchDog、PMU、RTC +
  • +
    +
    + +
    +
  • CLINT
  • +
  • NOC
  • +
  • PLIC
  • +
  • 存储总线(AMBA)
  • +
  • 存储:ROM、SRAM、DRAM、NAND/NOR Flash、DDR
  • +
    +
    +
      +
    • AMBA
    • +
    • AXI
    • +
    • AHB
    • +
    • APB
    • +
    +
    +
    + 开源IP +
  • UART
  • +
  • SPI
  • +
  • PS2
  • +
  • VGA
  • +
  • Ethernet
  • +
  • USB2.0
  • + 硬件加速卡 +
  • 加速卡:达坦科技 Open-rdma
  • +
    +
    + 商用IP +
  • UART
  • +
  • SPI
  • +
  • GPIO
  • +
  • VGA
  • +
  • HDMI
  • +
  • DP
  • +
  • Ethernet
  • +
  • PCle
  • +
  • SATA
  • +
  • 视频编解码(媒体)
  • +
  • 2D GPU
  • +
  • 3D GPU
  • +
  • AI加速器
  • +
    +
    +
    +
    +
    + +
      +
      EDA工具链
      +
    • + iEDA +
    • +
    • 商业产品
    • +
    + + {/* 将后面模块的id置前,以便滚动到当前位置就选中后面模块 */} +
    +
      +
      操作系统
      +
    • + 桌面端操作系统 + Bianbu操作系统 + 商业产品 +
    • +
    • + AIoT端操作系统 + 润开鸿OpenHarmony + 商业产品 +
    • +
    • + 服务器操作系统 + 开源产品 + 商业产品 +
    • +
    +
    +
    +
    +
    +

    开源芯片技术体系

    +
    +

    构建开源芯片生态

    +

    开源芯片的三个层次

    +
    + +
    +
    +

    开源芯片社区OChip宗旨及愿景

    +
    + { + vision.map((i, k) => { + return ( +
    +
    + +
    +

    { i.title }

    +

    { i.content }

    +
    + ) + }) + } +
    +
    +
    +
    +
    + {/*

    开源芯⽚⽤户成长体系介绍

    */} +

    +

    参与开源芯⽚项⽬的开发者需要签署开源贡献者协议

    +

    建议开发者按照开源项⽬成长路径进⾏参与,稳步提升能⼒,降低跳级参与带来的挑战

    + {/*
    + { + growPathInfo.map((i, k) => { + return ( +
    + { k % 2 === 1 &&
    } +
    +
    +
    +
    + { i.type } +
    +

    { i.plan }

    + { k % 2 === 0 &&
    } + +
    + ) + }) + } +
    +
    */} +
    + +
    + + + +
    +
    +
    + { + introDetail.map((i, k) => { + return ( +
    +

    + + { i.title } +

    +

    { i.desc }

    +
    + ) + }) + } +
    +
    +
    +
    + + {/* { // 专区简介 data && (data.introductionTitle || data.introductionContent || data.introductionImage) &&
    @@ -129,26 +396,9 @@ function HeaderPage(props){ }
    - } -
    -

    宗旨及愿景

    -
    - { - vision.map((i, k) => { - return ( -
    -
    - -
    -

    { i.title }

    -

    { i.content }

    -
    - ) - }) - } -
    -
    - { + } */} + + {/* { // 新闻动态 data && data.cmsShow === 1 && newsList && newsList.length>0 &&
    @@ -195,100 +445,98 @@ function HeaderPage(props){
    - } - { + } */} + {/* { // 精选项目 data && data.projectShow === 1 && projectList && projectList.length > 0 &&

    { data.homepageProjectTitle }

    - } - { - // 核心贡献者 - data && data.memberShow === 1 && personList && personList.length > 0 && -
    -

    { data.homepageMemberTitle }

    - -
    - } + } */} -
    -

    参与社区

    -

    成为社区成员,尽情发挥您的创意

    -
    - { - communityInfo.map((i, k) => { - return ( -
    -

    { i.level }

    -

    { i.todo }

    -
    -
    - ) - }) - } -
    -
    -
    - -
    - {/*

    开源芯⽚⽤户成长体系介绍

    */} -

    -

    参与开源芯⽚项⽬的开发者需要签署开源贡献者协议

    -

    建议开发者按照开源项⽬成长路径进⾏参与,稳步提升能⼒,降低跳级参与带来的挑战

    -
    - { - growPathInfo.map((i, k) => { - return ( -
    - { k % 2 === 1 &&
    } -
    -
    -
    -
    - { i.type } + { + recruitList && recruitList.length > 0 && +
    +

    招聘专栏

    + 查看全部 +
      +
      +

      “职”等你来

      +

      ——企业招聘专栏

      +

      在这里,我们汇聚了开源芯片的精英企业,为您带来最前沿的就业机会。加入我们,让梦想照进现实,共同开启职业生涯的新篇章!

      +
      + { + recruitList.map((i,k)=>{ + return( +
    • +

      {i.name}

      +

      {i.summary}

      + 查看详情 +
    • + ) + }) + } +
    +
    + } +
    + { + // 合作伙伴 + data && data.partnersShow === 1 && partnerList && partnerList.length > 0 && +
    +

    { data.homepagePartnersTitle }

    +

    核心企业CORE ENTERPRISE

    + +
    +
    + } + { + data && data.memberShow === 1 && personList && personList.length > 0 && +
    +

    核心贡献者CORE CONTRIBUTORS

    +
      + {personList.map((item,key)=>{ + return( +
    • + +

      {item.name}

      +

      {item.introduction || "暂无简介"}

      +
    • + ) + }) + } +
    +
    + } +
    +

    开发者加入社区DEVELOPERS INCOMING THE COMMUNITY

    + {/*

    成为社区成员,尽情发挥您的创意

    */} +
    + { + communityInfo.map((i, k) => { + return ( +
    +
    +
    +

    { i.level }

    +

    { i.todo }

    +
    + { k === 0 && } + { k === 1 && } + { k === 2 && } + { k === 3 && } +
    +
    -

    { i.plan }

    - { k % 2 === 0 &&
    } - -
    - ) - }) - } + ) + }) + } +
    +
    +
    -
    -
    - { - introDetail.map((i, k) => { - return ( -
    -

    - - { i.title } -

    -

    { i.desc }

    -
    - ) - }) - } -
    -
    - -
    -

    集萃群智经验 交流心得体会

    - -
    - { - // 合作伙伴 - data && data.partnersShow === 1 && partnerList && partnerList.length > 0 && -
    -

    { data.homepagePartnersTitle }

    - -
    - } -
    ) } diff --git a/src/forge/Information/Pages/main.jsx b/src/forge/Information/Pages/main.jsx index 68cc8fa38..60d3fd758 100644 --- a/src/forge/Information/Pages/main.jsx +++ b/src/forge/Information/Pages/main.jsx @@ -26,6 +26,7 @@ function Main(props){ const { deptId , cateId } = props.match.params; const { id, temp, role, history, sectionCmsTitle } = props; + const menu = ( @@ -82,9 +83,10 @@ function Main(props){ if(result){ let rows = result.data.rows; setMainList(rows); - if (temp !== tempEnum.zone) { - selectCate(rows[0].id) - } + // 隐藏判断原因:首页查看全部跳转过来后要默认选择指定的cateID而不是第一个 + // if (temp !== tempEnum.zone) { + selectCate(cateId) + // } setIsSpin(false); } }).catch(error=>{}) @@ -116,6 +118,7 @@ function Main(props){ props.history.push(`/zone/${deptId}/news/${id}`) } + return(
    @@ -151,7 +154,7 @@ function Main(props){ mainList.map((i,k)=>{ if (k <= 4) { return( -
    selectCate(i.id)} >{i.name}
    +
    selectCate(i.id)} >{i.name}
    ) } }) diff --git a/src/forge/Information/api.js b/src/forge/Information/api.js index c37b42e9c..3c85cb085 100644 --- a/src/forge/Information/api.js +++ b/src/forge/Information/api.js @@ -53,6 +53,30 @@ export function getPartnerList(id){ }) } + +export function getDocList(id){ + return fetch({ + url:`/cms/doc/open/zone/${id}/dirList`, + method: 'get', + }) +} + + +export function getSubDocList(id,params){ + return fetch({ + url:`/cms/doc/open/dir/${id}/docList`, + method: 'get', + params + }) +} +// 专区会员 +export function getVIPAllList(id){ + return fetch({ + url:`/zone/open/${id}/member/overviewList`, + method: 'get' + }) +} + /**领域资讯 */ export function getNewsAllList(id,params){ return fetch({ diff --git a/src/forge/Information/img/cbg2.png b/src/forge/Information/img/cbg2.png index 2f7a42562..51e56e593 100644 Binary files a/src/forge/Information/img/cbg2.png and b/src/forge/Information/img/cbg2.png differ diff --git a/src/forge/Information/img/communicateBg.png b/src/forge/Information/img/communicateBg.png index 2f9c7ff87..f1da2e8f4 100644 Binary files a/src/forge/Information/img/communicateBg.png and b/src/forge/Information/img/communicateBg.png differ diff --git a/src/forge/Information/img/zone1/EDA.png b/src/forge/Information/img/zone1/EDA.png new file mode 100644 index 000000000..6fcfce558 Binary files /dev/null and b/src/forge/Information/img/zone1/EDA.png differ diff --git a/src/forge/Information/img/zone1/chain.png b/src/forge/Information/img/zone1/chain.png new file mode 100644 index 000000000..67d74b80e Binary files /dev/null and b/src/forge/Information/img/zone1/chain.png differ diff --git a/src/forge/Information/img/zone1/core.png b/src/forge/Information/img/zone1/core.png new file mode 100644 index 000000000..03ba0cfd9 Binary files /dev/null and b/src/forge/Information/img/zone1/core.png differ diff --git a/src/forge/Information/img/zone1/fu.png b/src/forge/Information/img/zone1/fu.png new file mode 100644 index 000000000..4b9bd4c69 Binary files /dev/null and b/src/forge/Information/img/zone1/fu.png differ diff --git a/src/forge/Information/img/zone1/jiantouwhite.png b/src/forge/Information/img/zone1/jiantouwhite.png new file mode 100644 index 000000000..eb8cacbc4 Binary files /dev/null and b/src/forge/Information/img/zone1/jiantouwhite.png differ diff --git a/src/forge/Information/img/zone1/last.png b/src/forge/Information/img/zone1/last.png new file mode 100644 index 000000000..e1145d487 Binary files /dev/null and b/src/forge/Information/img/zone1/last.png differ diff --git a/src/forge/Information/img/zone1/line.png b/src/forge/Information/img/zone1/line.png new file mode 100644 index 000000000..2513d61a6 Binary files /dev/null and b/src/forge/Information/img/zone1/line.png differ diff --git a/src/forge/Information/img/zone1/phone.png b/src/forge/Information/img/zone1/phone.png new file mode 100644 index 000000000..7441da148 Binary files /dev/null and b/src/forge/Information/img/zone1/phone.png differ diff --git a/src/forge/Information/img/zone1/sys.png b/src/forge/Information/img/zone1/sys.png new file mode 100644 index 000000000..1de9830ac Binary files /dev/null and b/src/forge/Information/img/zone1/sys.png differ diff --git a/src/forge/Information/img/zone1/system.png b/src/forge/Information/img/zone1/system.png new file mode 100644 index 000000000..d40867f6f Binary files /dev/null and b/src/forge/Information/img/zone1/system.png differ diff --git a/src/forge/Information/img/zone1/team1.png b/src/forge/Information/img/zone1/team1.png new file mode 100644 index 000000000..8e479fd70 Binary files /dev/null and b/src/forge/Information/img/zone1/team1.png differ diff --git a/src/forge/Information/img/zone1/team2.png b/src/forge/Information/img/zone1/team2.png new file mode 100644 index 000000000..bee8cd08b Binary files /dev/null and b/src/forge/Information/img/zone1/team2.png differ diff --git a/src/forge/Information/img/zone1/team3.png b/src/forge/Information/img/zone1/team3.png new file mode 100644 index 000000000..11a8d80eb Binary files /dev/null and b/src/forge/Information/img/zone1/team3.png differ diff --git a/src/forge/Information/img/zone1/team4.png b/src/forge/Information/img/zone1/team4.png new file mode 100644 index 000000000..1e738c0c8 Binary files /dev/null and b/src/forge/Information/img/zone1/team4.png differ diff --git a/src/forge/Information/img/zone1/window.png b/src/forge/Information/img/zone1/window.png new file mode 100644 index 000000000..b9ffe7598 Binary files /dev/null and b/src/forge/Information/img/zone1/window.png differ diff --git a/src/forge/Information/img/zone1/xinpian.png b/src/forge/Information/img/zone1/xinpian.png new file mode 100644 index 000000000..b95aa6cad Binary files /dev/null and b/src/forge/Information/img/zone1/xinpian.png differ diff --git a/src/forge/Information/img/zone1/zhao.png b/src/forge/Information/img/zone1/zhao.png new file mode 100644 index 000000000..4d87815e5 Binary files /dev/null and b/src/forge/Information/img/zone1/zhao.png differ diff --git a/src/forge/Information/index.scss b/src/forge/Information/index.scss index 0f7ea07bf..b346d108a 100644 --- a/src/forge/Information/index.scss +++ b/src/forge/Information/index.scss @@ -1164,7 +1164,6 @@ } } .zone_parter{ - background-color: #fff; padding:70px 0px 90px; .zone_part_lists{ display: flex; @@ -1175,6 +1174,7 @@ justify-content: flex-start; align-items: flex-end; flex-wrap: wrap; + margin-bottom: 20px!important; .zone_part_item { color:#1f2329; font-size:20px; @@ -1186,14 +1186,19 @@ display: inline-block; width: 200px; } + &:nth-child(6n) { + a,div{ + margin-right: 0px; + } + } a, div { display: inline-block; - width: 220px; - height: 88px; - line-height: 88px; - margin-right: 20px; + width: 180px; + height: 80px; + line-height: 80px; + margin-right: 24px; margin-top: 20px; - margin-bottom: 30px!important; + margin-bottom: 25px!important; color:#1f2329; font-size:20px; text-align: center; @@ -1202,8 +1207,8 @@ box-shadow:0px 0px 15px rgba(28, 48, 175, 0.08); transition: 0.1s linear; img{ - max-width: 180px; - max-height: 66px; + max-width: 160px; + max-height: 60px; } &:hover { transform: translate(0, -5px); diff --git a/src/forge/Information/indexZone1.scss b/src/forge/Information/indexZone1.scss index f434bba06..81127220f 100644 --- a/src/forge/Information/indexZone1.scss +++ b/src/forge/Information/indexZone1.scss @@ -2,7 +2,6 @@ .zone1_box{ - padding-top:70px; background-color:#f7f9fc; .zone_infos{ display: flex; @@ -34,7 +33,6 @@ } } .zone_vision { - background-color: #ffffff; .boxmain { display: flex; justify-content: space-between; @@ -349,10 +347,10 @@ } } .zone_community { - background-color:#ebeff5; display: flex; flex-direction: column; align-items: center; + padding:30px 0px 60px; .sub_title { font-size: 17px; line-height: 27px; @@ -366,22 +364,39 @@ justify-content: space-between; z-index: 10; .c_role_item { - width: 260px; - height: 213px; + width: 289px; + height: 243px; background-image: url(./img/cbg2.png); background-size: 100% 100%; position: relative; padding: 30px 23px; + .c_role_div{ + display: flex; + padding:20px; + justify-content: space-between; + align-items: flex-start; + img{ + width: 58px; + } + } + &:first-child{ + margin-left: -15px; + } + &:last-child{ + margin-right: -15px; + } .role_level { font-weight: 700; font-size: 18px; line-height: 27px; + text-align: left; } .role_todo { color: #3d485d; font-size: 15px; line-height: 27px; margin-top: 10px; + text-align: left; } .dot { width:14px; @@ -389,8 +404,8 @@ border-radius: 50%; background-color:#07a583; position: absolute; - left: 6px; - bottom: 7px; + left: 20px; + bottom: 22px; } } } @@ -398,7 +413,7 @@ height: 0px; width: 1200px; border-bottom: dashed 1px #8d95ac; - transform: translate(0, -14px); + transform: translate(0, -28px); } } .zone_grow { @@ -470,6 +485,25 @@ border-bottom: solid 1px #07a583; transform: translate(0, -80px); } + .grow_content{ + position: relative; + .grow_a{ + position: absolute; + left: 0px; + top: 0px; + height: 100%; + padding-top: 60px; + display: flex; + flex-direction: column; + justify-content: space-between; + padding-bottom: 20px; + a{ + display: block; + height: 38px; + width: 145px; + } + } + } .grow_introduction { display: flex; justify-content: space-between; @@ -481,6 +515,7 @@ box-shadow: 0px 0px 12px rgba(29, 72, 129, 0.08); padding: 22px 17px; transition: 0.1s; + text-align: left; .intro_title { font-weight: 700; color: #3d485d; @@ -501,15 +536,15 @@ transform: translate(0, -20px); } } - } + } .zone_communicate { - height: 160px; + height: 547px; background: url('./img/communicateBg.png') no-repeat; background-size: 100% 100%; display: flex; flex-direction: column; align-items: center; - justify-content: space-evenly; + padding:37px 0px; p { font-weight: 500; font-size: 22px; @@ -524,6 +559,77 @@ font-size: 16px; cursor: pointer; border: none; + margin:16px 0px 48px!important; + } + .zone_recruit{ + display: flex; + width: 1200px; + margin:0px auto; + align-items: flex-start; + &>div{ + max-width: 267px; + text-align: left; + p{ + &:last-child{ + font-family:PingFang SC; + color:#ffffff; + font-size:15px; + line-height:36px; + margin-top: 25px; + } + } + } + li{ + background: #ffffff; + border-radius: 11px; + margin-left: 20px; + padding:28px 16px; + text-align: left; + flex: 1; + &:hover{ + background: #e4eaf2; + border-radius: 11px; + box-shadow: 0px 0px 10px rgba(7, 70, 165, 0.11); + .zone_recruit_btn img{ + left:68px; + } + } + .zone_recruit_name{ + font-weight:700; + color:#1f2329; + font-size:18px; + line-height:27px; + height:27px; + } + .zone_recruit_desc{ + color:#3d485d; + font-size:15px; + line-height:30px; + height: 120px; + margin:16px 0px 6px!important; + overflow: hidden; + text-overflow: ellipsis; + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-line-clamp: 4; + word-break: break-all; + white-space:break-spaces; + } + .zone_recruit_btn{ + padding-right: 20px; + position: relative; + height: 20px; + line-height: 20px; + color: #07a583; + transition: 0.1s; + img{ + position: absolute; + left: 62px; + top:5px; + transition: 0.1s; + } + } + } } } } @@ -648,6 +754,10 @@ } } } +.line_key{ + background-color: #fff; + padding:70px 0px; +} .zone1_source_box{ padding-bottom: 30px; .source_h{ @@ -766,4 +876,353 @@ } } } -} \ No newline at end of file +} + +.kxy{ + text-align: center; + position: relative; + .zone_member{ + display: flex; + justify-content: flex-start; + align-items: flex-end; + flex-wrap: wrap; + width: 1200px; + margin:0px auto; + li{ + width: 240px; + height: 124px; + background-image: url(./img/zone1/core.png); + background-size: 100%; + margin-right: 80px; + box-shadow: 0px 0px 15px rgba(28, 48, 175, 0.08); + border-radius: 2px; + font-weight: 400; + font-size: 16px; + color: #4C5876; + margin-bottom: 45px!important; + padding:0px 10px; + img{ + width: 50px; + height: 50px; + background: #D8D8D8; + box-shadow: 0px 0px 6px 1px rgba(0,0,0,0.08); + border: 1px solid #FFFFFF; + border-radius: 50%; + margin-top: -25px; + margin-bottom: 3px; + } + &:nth-child(4n){ + margin-right: 0px; + } + } + } + .zone_parter{ + padding-bottom: 0px; + .zone_part_lists{ + margin-top: 0px; + } + } + // 上面纵向的三部分 + .chainBox{ + width: 1200px; + margin:0px auto; + .chainNews{ + display: flex; + &>li{ + display: flex; + flex-direction: column; + width: 8%; + margin-right: 18px; + padding:15px; + } + &>ul:last-child{ + width: 84%; + } + } + .chainNews_Main{ + flex: 1; + border: 1px dashed rgba(70, 106, 255, 0.5); + padding:22px; + color:#111111; + font-size:16px; + .left_Infos{ + li{ + padding:10px 13px; + margin-bottom: 18px!important; + } + } + .right_infos{ + li{ + margin-bottom: 18px!important; + font-size: 16px; + padding:3px 5px!important; + } + } + .middle_ul{ + width: 110px; + display: flex; + flex-direction: column; + justify-content: space-around; + margin:0px auto; + } + .chainNews_Box{ + display: flex; + flex-wrap: wrap; + .boldFont{ + display: block; + text-align: center; + margin-top: 15px; + width: 100%; + } + } + } + // 下面横向排列的三部分 + &>ul{ + border: 1px dashed rgba(70, 106, 255, 0.5); + padding:15px; + display: flex; + justify-content: space-between; + margin-top: 18px; + color: #111111; + &>div{ + display: flex; + align-items: center; + width: 150px; + padding-left: 25px; + font-weight: 700; + font-size: 18px; + img{ + width: 22px; + margin-right: 10px; + } + } + &>li{ + flex:1; + display: flex; + flex-direction: column; + margin-left: 50px; + font-size: 16px; + &>span{ + margin-bottom: 20px!important; + display: flex; + align-items: center; + justify-content: center; + &:last-child{ + margin-bottom: 0px!important; + } + } + } + } + } + .bord_padding{ + border: 1px dashed rgba(70, 106, 255, 0.5); + padding:5px 22px; + } + .bord_padding14{ + border: 1px dashed rgba(70, 106, 255, 0.5); + padding:14px; + } + .boldFont{ + font-weight: 700; + font-size: 18px; + line-height: 27px; + } + .width30{ + width: 30%; + } + .width60{ + width: 60%; + } + .mlauto{ + margin-left: auto; + } + .width45{ + width: 45%; + } + .flex{ + display: flex; + } + .skybox{ + background: #eff2fb; + padding:3px 15px; + border: 1px dashed rgba(70, 106, 255, 0.5); + display: flex; + align-items: center; + justify-content: center; + word-break: break-all; + } + .greenbox{ + background: #07a583; + padding:3px 15px; + border: 1px dashed rgba(255, 255, 255, 0.5); + display: flex; + align-items: center; + justify-content: center; + word-break: break-all; + color: #fff; + cursor: pointer; + a{ + display: block; + color: #fff; + display: flex; + align-items: center; + justify-content: center; + word-break: break-all; + position: relative; + padding-right: 32px; + } + img{ + margin-left: 5px; + transition: .3s; + position: absolute; + right: 0px; + } + &:hover{ + box-shadow: 0px 0px 6px 1px rgba(31,120,49,0.98); + border-color: #FFFFFF; + img{ + right: -5px; + } + } + &.unHover:hover{ + box-shadow: unset; + border-color: rgba(255, 255, 255, 0.5); + } + } + + .last_box{ + background-image: url('./img/zone1/last.png'); + background-repeat: no-repeat; + background-size: 100% 100%; + } +} +.shandowTitle{ + font-family:Alimama ShuHeiTi; + font-weight:700; + color:#1f2329; + font-size:22px; + position: relative; + width: 1200px; + margin:0px auto; + text-align: left; + span{ + position: absolute; + background:linear-gradient(180deg,#d8ddf0 0%,rgba(224, 229, 250, 0) 100%); + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; + top: -13px; + left: 0px; + } +} +.joinButton{ + width: 140px; + height: 40px; + line-height: 40px!important; + color: #ffffff!important; + background-color: #07a583!important; + border-radius: 2px; + font-size: 16px; + cursor: pointer; + border: none; +} +.anchor_kxy{ + width: 200px; + z-index: 1000; + top: 50%; + left: 200px; + position: fixed; + .ant-anchor-link{ + margin:15px 0px; + text-align: left; + padding-left: 15px; + } + .ant-anchor-ink-ball{ + display: none; + } + .ant-anchor-link-title-active,.ant-anchor-link-active{ + color:#07a583; + position: relative; + } + .ant-anchor-link-active::before{ + position: absolute; + content: ""; + top:0px; + width: 2px; + height: 100%; + border:none; + left: -3px; + background-color:#07a583; + } +} + +.system_open{ + background:#f7f9fc; + padding:80px 0px; + &>div{ + width: 1200px; + margin:0px auto; + } + .sys_box{ + align-items: flex-start; + color: #1f2329; + font-size: 17px; + justify-content: space-evenly; + &>div{ + width: 50%; + } + } + .sys_ul{ + display: flex; + justify-content: space-between; + li{ + width: 180px; + height: 49px; + background: #f6f7fa; + border: 2px solid rgba(255, 255, 255, 0.45); + border-radius: 4px; + box-shadow: 0px 0px 35px rgba(7, 70, 165, 0.11); + color: #111111; + font-size: 16px; + line-height: 49px; + } + } +} + + + +@media screen and (min-width: 1400px) { + .anchor_kxy { + display: none; + } +} +@media screen and (min-width: 1500px) { + .anchor_kxy { + left: 100px; + display: block; + } +} +@media screen and (min-width: 1600px) { + .anchor_kxy { + left: 150px; + display: block; + } +} + +@media screen and (min-width: 1700px) { + .anchor_kxy { + left: 80px; + display: block; + } +} +@media screen and (min-width: 1800px) { + .anchor_kxy { + left: 100px; + display: block; + } +} +@media screen and (min-width: 1900px) { + .anchor_kxy { + left: 190px; + display: block; + } +} diff --git a/src/forge/Main/CoderDepot.jsx b/src/forge/Main/CoderDepot.jsx index 9de0521b6..bb0778aa0 100644 --- a/src/forge/Main/CoderDepot.jsx +++ b/src/forge/Main/CoderDepot.jsx @@ -439,12 +439,17 @@ function CoderDepot(props){ { mirror_status === 2 &&
    - + { projectDetail.permission && mangementOperate.includes(projectDetail.permission) ? -

    导入项目失败,请前往 仓库设置 删除本项目后重新导入!

    +
    +

    导入项目失败,可能存在以下原因:

    +
  • 1、导入的仓库 URL 错误。
  • +
  • 2、您需要导入的可能是一个您无权访问的私有仓库,需要输入授权验证仓库的帐号、密码(或者个人令牌),此信息仅用于本次代码同步,不做任何记录。
  • +

    请前往 仓库设置 删除本项目后重新导入!

    +
    : -

    导入项目失败,请联系管理员重新导入!

    +

    导入项目失败,请联系管理员重新导入!

    }
    } diff --git a/src/forge/Main/Detail.js b/src/forge/Main/Detail.js index 5a43db0f1..c4fef2e13 100644 --- a/src/forge/Main/Detail.js +++ b/src/forge/Main/Detail.js @@ -299,7 +299,7 @@ class Detail extends Component { projectdata = this.props.defaultDetail } else { const res = await getProjectDetailFunc(owner, projectsId, !window.location.host); - if (res.status === 200) { + if (res && res.status === 200) { projectdata = res.data } } diff --git a/src/forge/Main/Index.scss b/src/forge/Main/Index.scss index 1e584c4d6..b894b6484 100644 --- a/src/forge/Main/Index.scss +++ b/src/forge/Main/Index.scss @@ -563,10 +563,18 @@ flex-direction: column; align-items: center; justify-content: center; + flex-direction: column; font-weight: 400; font-size: 15px; color: #4C5B76; + padding-top: 50px; + .failInfo{ + max-width: 480px; + li{ + font-size: 15px; + } + } img{ - margin-bottom: 20px; + margin-bottom: 35px; } } \ No newline at end of file diff --git a/src/forge/Merge/MergeItem.js b/src/forge/Merge/MergeItem.js index 8ca39bce0..583e71651 100644 --- a/src/forge/Merge/MergeItem.js +++ b/src/forge/Merge/MergeItem.js @@ -110,15 +110,22 @@ class MergeItem extends Component { { item.pull_request_head && - - {item.is_original - ? item.fork_project_user_name - : item.author_name} - : {item.pull_request_head} - + { + item.is_original ? + ( + (item.fork_project_user && item.fork_project_identifier) ? + + {item.fork_project_user_name || "仓库已删除"} : {item.pull_request_head || "分支已删除"} + + : + {item.fork_project_user_name || "仓库已删除"} : {item.pull_request_head || "分支已删除"} + ) + : + {item.author_name} :{item.pull_request_head || "分支已删除"} + } } { diff --git a/src/forge/Server/List.jsx b/src/forge/Server/List.jsx index 280c07f56..e5cd281a0 100644 --- a/src/forge/Server/List.jsx +++ b/src/forge/Server/List.jsx @@ -54,7 +54,9 @@ function Main(props){ 查看详情 -
  • + { + // 镜像项目隐藏服务 + projectDetail && parseInt(projectDetail.type) !== 2 &&
  • Reposyncer仓库同步 @@ -64,6 +66,7 @@ function Main(props){ 查看详情
  • + } {/* 是站点仓库则显示,否则隐藏 */} {projectDetail && projectDetail.web_site && projectDetail.author.type === "User" &&
  • diff --git a/src/glcc/home/index.jsx b/src/glcc/home/index.jsx index 8d83695e7..62ea13361 100644 --- a/src/glcc/home/index.jsx +++ b/src/glcc/home/index.jsx @@ -24,7 +24,7 @@ import './index.scss'; // period: 项目报名阶段("repoApply") // match:{params:{id=2023}} 注意默认值记得每届修改 export default (props) => { - const { current_user, history, round, match:{params:{id=2024}}, period, showLoginDialog, glccSettings, repoPublic, showMatchingBut, isResultPublic, hasRole, isMediumExamineByToTutor, isFinalExamineByToTutor, checkedTaskId} = props; + const { current_user, history, round, match:{params:{id=2024}}, period, showLoginDialog, glccSettings, repoPublic, showMatchingBut, isResultPublic, hasRole, isMediumExamineByToTutor, isFinalExamineByToTutor, checkedTaskId, mediumExaminationPass} = props; useEffect(() => { if (!current_user.user_id) { history.push('/403'); @@ -141,7 +141,7 @@ export default (props) => { } {/* 学生结项考核 */} - {period === "finalExamine1" && checkedTaskId && + {period === "finalExamine1" && mediumExaminationPass &&
    结项考核 diff --git a/src/glcc/index.jsx b/src/glcc/index.jsx index be8d045de..d2320ee48 100644 --- a/src/glcc/index.jsx +++ b/src/glcc/index.jsx @@ -93,7 +93,7 @@ const MiddleResult = Loadable({ loading: Loading, }); const Glcc = (propsF) => { - const {current_user, showLoginDialog, match:{params:{id}}} = propsF; + const {current_user, showLoginDialog, match:{params:{id}}, history} = propsF; // round:2022届(1) 2023届(2) 2024届(3) const [round, setRound] = useState(currentRound); // glcc 所处阶段 repoApply(项目报名) stuApply(学生报名阶段) @@ -172,6 +172,7 @@ const Glcc = (propsF) => { // 用户与导师双向选定的课题id const [checkedTaskId, setCheckedTaskId] = useState(undefined); const [studentRegId, setStudentRegId] = useState(undefined); + const [mediumExaminationPass, setMediumExaminationPass] = useState(false); useEffect(()=>{ document.title='确实开源编程夏令营丨GLCC'; @@ -196,12 +197,18 @@ const Glcc = (propsF) => { // setData(response.data.rows); const data = {}; const data1 = {}; + let isLockedTask = false; response.data && response.data.registrationStudentTaskList.map(item=>{ data[item.taskId] = item.id; item.locked && setLockedTaskName(item.taskName); // 结项考核: && item.mediumExaminationPass item.locked && setCheckedTaskId(item.taskId); item.locked && setStudentRegId(item.studentRegId); + // 校验是否可以进行中期考核 + period === "mediumExamine1" && item.locked && (isLockedTask = true); + // 校验是否可以进行结项考核 + period === "finalExamine1" && item.mediumExaminationPass && (isLockedTask = true); + item.mediumExaminationPass && setMediumExaminationPass(true) // 取当前报名的课题数() if(item.subRound === 1){ data1[item.taskId] = item.id; @@ -210,8 +217,15 @@ const Glcc = (propsF) => { setApplyTaskId(data); setApply1TaskId(data1); response.data && setCancelCount(Number(response.data.cancelCount)); + if(window.location.pathname === "/glcc/submit" && (period === "mediumExamine1" || period === "finalExamine1") && (!isLockedTask)){ + history.push('/glcc') + message.error("您当前登录的账号不能参与该阶段开源夏令营"); + } } }) + if(window.location.pathname === "/glcc/submit" && current_user && !current_user.login){ + history.push('/glcc') + } },[studentInfoReset, current_user, period]) // 申请课题按钮点击函数 @@ -350,7 +364,7 @@ const Glcc = (propsF) => { >} {/* 中期/结项审核-学生 */} - {(period === "mediumExamine1" || period === "finalExamine1") && ( @@ -377,7 +391,7 @@ const Glcc = (propsF) => { ( - + )} > @@ -385,7 +399,7 @@ const Glcc = (propsF) => { ( - + )} > diff --git a/src/glcc/interimReview/studentSubmit.jsx b/src/glcc/interimReview/studentSubmit.jsx index 7fdebf23f..d75a0e48f 100644 --- a/src/glcc/interimReview/studentSubmit.jsx +++ b/src/glcc/interimReview/studentSubmit.jsx @@ -47,17 +47,6 @@ function StudentSubmit(props){ // 是否授权主办方 const [isAuthed, setIsAuthed] = useState(false); - useEffect(()=>{ - if(period === "finalExamine1"){ - hasFinalExam({round:currentRound,userId:current_user.user_id}).then((res)=>{ - if(res && res.data && res.data.hasRole) return; - history.push("/glcc"); - }).catch((err)=>{ - history.push("/glcc"); - }) - } - },[]) - useEffect(()=>{ // 查询是否已经提交考核材料 checkedTaskId && getMediumTermExamineInfo(checkedTaskId,{round: currentRound, term: period === "mediumExamine1" ? 1 : 2}).then(res=>{ @@ -108,10 +97,10 @@ function StudentSubmit(props){ }) }else{ setDisabled(false); - const { codeOrPrUrl } = values; - if (codeOrPrUrl) { - checkPrLink("", codeOrPrUrl, () => {}); - } + // const { codeOrPrUrl } = values; + // if (codeOrPrUrl) { + // checkPrLink("", codeOrPrUrl, () => {}); + // } } }) } @@ -186,7 +175,7 @@ function StudentSubmit(props){
    开源夏令营 / 提交{label[period]}考核材料
    材料提交说明:
    -
    1、请各位学生下载PPT模板 ,根据课题开发进展,按照PPT模板要求填写课题学习调研方案、开发进度及开发成果等考核材料;
    +
    1、请各位学生下载PPT模板 ,根据课题开发进展,按照PPT模板要求填写课题学习调研方案、开发进度及开发成果等考核材料;
    2、欢迎各位学生录制本课题答辩视频,将视频链接填写至下方视频介绍填写栏;
    3、学生提交考核材料的时间为{formatParsedResult( period === "mediumExamine1" ? mediumExamine : finalExamine)},请在截止时间前提交;
    4、若导师已给出评分,各位学生可在此页面查看自己的{label[period]}考核成绩。对考核成绩有异议的学生请及时联系您的导师。
    @@ -214,18 +203,18 @@ function StudentSubmit(props){ rules: [ { required: true, - validator: (rule, value, callback) => { - checkPrLink(rule, value, callback, checkedTaskId); - }, + // validator: (rule, value, callback) => { + // checkPrLink(rule, value, callback, checkedTaskId); + // }, }, ], // validateTrigger: "onBlur", })()} - + {/*

    注: 按主办方要求,GLCC官方资助课题最终需要在Gitlink平台进行pr提交。

    请和导师确认您的课题是否官方赞助,如为官方赞助,请确保终期考核的pr提交在Gitlink平台上进行,否则将会影响您的最终考核。

    -
    +
    */} :