| model: {}, | model: {}, | ||||
| request: {}, | request: {}, | ||||
| layout: { | layout: { | ||||
| title: '菊城人才网', | |||||
| title: '', | |||||
| logo: '/images/onlylogo.jpg', | logo: '/images/onlylogo.jpg', | ||||
| }, | }, | ||||
| routes: routes, | routes: routes, |
| component: './Register', | component: './Register', | ||||
| layout: false | layout: false | ||||
| }, | }, | ||||
| // 求职首页 | |||||
| { | |||||
| flatMenu: false, | |||||
| name: '求职·招聘', | |||||
| path: '/', | |||||
| access: 'talent', | |||||
| routes: [ | |||||
| { | |||||
| path: '/', | |||||
| redirect: '/talent/home', | |||||
| }, | |||||
| { | |||||
| name: '求职·招聘', | |||||
| path: '/talent/home', | |||||
| component: './Talent/Home', | |||||
| access: 'talenthome' | |||||
| }, | |||||
| { | |||||
| name: '搜索·职位·企业', | |||||
| path: '/talent/search', | |||||
| component: './Talent/Search', | |||||
| access: 'talentsearch' | |||||
| }, | |||||
| { | |||||
| name: '招聘会', | |||||
| path: '/talent/fair', | |||||
| component: './Talent/Fair', | |||||
| access: 'talentfair' | |||||
| }, | |||||
| { | |||||
| name: '资讯·下载', | |||||
| path: '/talent/information', | |||||
| component: './Talent/Information', | |||||
| access: 'talentinformation' | |||||
| }, | |||||
| // { | |||||
| // name: '下载专区', | |||||
| // path: '/talent/download', | |||||
| // component: './Talent/Download', | |||||
| // access: 'talentdownload' | |||||
| // }, | |||||
| { | |||||
| name: '关于我们', | |||||
| path: '/talent/about', | |||||
| component: './Talent/About', | |||||
| access: 'talentabout' | |||||
| }, | |||||
| { | |||||
| path: '/talent/job/detail', | |||||
| component: './Talent/Detail/Job', | |||||
| access: 'talentjobdetail' | |||||
| }, | |||||
| { | |||||
| path: '/talent/company/detail', | |||||
| component: './Talent/Detail/Company', | |||||
| access: 'talentCompanydetail' | |||||
| }, | |||||
| { | |||||
| path: '/talent/resume/detail', | |||||
| component: './Talent/Detail/Resume', | |||||
| access: 'talentResumedetail' | |||||
| }, | |||||
| { | |||||
| path: '/talent/fair/detail', | |||||
| component: './Talent/Fair/Detail', | |||||
| access: 'talentfairdetail' | |||||
| }, | |||||
| { | |||||
| path: '/talent/information/detail', | |||||
| component: './Talent/Information/Detail', | |||||
| access: 'talentinformationdetail' | |||||
| }, | |||||
| ] | |||||
| }, | |||||
| // 科创园 | // 科创园 | ||||
| { | { | ||||
| flatMenu: false, | flatMenu: false, | ||||
| name: '科创园', | name: '科创园', | ||||
| path: '/', | |||||
| path: '/sciencetechnologypark', | |||||
| access: 'sciencetechnologypark', | access: 'sciencetechnologypark', | ||||
| routes: [ | routes: [ | ||||
| { | |||||
| path: '/', | |||||
| redirect: '/sciencetechnologypark/home', | |||||
| }, | |||||
| { | { | ||||
| name: '首页', | name: '首页', | ||||
| path: '/sciencetechnologypark/home', | path: '/sciencetechnologypark/home', | ||||
| // 合作伙伴 | // 合作伙伴 | ||||
| { | { | ||||
| flatMenu: false, | |||||
| name: '合作伙伴', | name: '合作伙伴', | ||||
| path: '/partner', | path: '/partner', | ||||
| component: './Partner/Home', | component: './Partner/Home', | ||||
| access: 'partner', | access: 'partner', | ||||
| }, | }, | ||||
| // 求职首页 | |||||
| { | |||||
| flatMenu: false, | |||||
| name: '求职·招聘', | |||||
| path: '/', | |||||
| access: 'talent', | |||||
| routes: [ | |||||
| { | |||||
| path: '/', | |||||
| redirect: '/talent/home', | |||||
| }, | |||||
| { | |||||
| name: '求职·招聘', | |||||
| path: '/talent/home', | |||||
| component: './Talent/Home', | |||||
| access: 'talenthome' | |||||
| }, | |||||
| { | |||||
| name: '搜索·职位·企业', | |||||
| path: '/talent/search', | |||||
| component: './Talent/Search', | |||||
| access: 'talentsearch' | |||||
| }, | |||||
| { | |||||
| name: '招聘会', | |||||
| path: '/talent/fair', | |||||
| component: './Talent/Fair', | |||||
| access: 'talentfair' | |||||
| }, | |||||
| { | |||||
| name: '资讯·下载', | |||||
| path: '/talent/information', | |||||
| component: './Talent/Information', | |||||
| access: 'talentinformation' | |||||
| }, | |||||
| // { | |||||
| // name: '下载专区', | |||||
| // path: '/talent/download', | |||||
| // component: './Talent/Download', | |||||
| // access: 'talentdownload' | |||||
| // }, | |||||
| { | |||||
| name: '关于我们', | |||||
| path: '/talent/about', | |||||
| component: './Talent/About', | |||||
| access: 'talentabout' | |||||
| }, | |||||
| { | |||||
| path: '/talent/job/detail', | |||||
| component: './Talent/Detail/Job', | |||||
| access: 'talentjobdetail' | |||||
| }, | |||||
| { | |||||
| path: '/talent/company/detail', | |||||
| component: './Talent/Detail/Company', | |||||
| access: 'talentCompanydetail' | |||||
| }, | |||||
| { | |||||
| path: '/talent/resume/detail', | |||||
| component: './Talent/Detail/Resume', | |||||
| access: 'talentResumedetail' | |||||
| }, | |||||
| { | |||||
| path: '/talent/fair/detail', | |||||
| component: './Talent/Fair/Detail', | |||||
| access: 'talentfairdetail' | |||||
| }, | |||||
| { | |||||
| path: '/talent/information/detail', | |||||
| component: './Talent/Information/Detail', | |||||
| access: 'talentinformationdetail' | |||||
| }, | |||||
| ] | |||||
| }, | |||||
| // 求职者管理 | // 求职者管理 | ||||
| { | { |
| </head> | </head> | ||||
| <body> | <body> | ||||
| <div id="root"></div> | <div id="root"></div> | ||||
| <script src="/umi.e7cc0b41.js"></script> | |||||
| <script src="/umi.c9ab8c08.js"></script> | |||||
| </body> | </body> | ||||
| </html> | </html> |
| import { useState, useEffect, useRef } from 'react'; | import { useState, useEffect, useRef } from 'react'; | ||||
| import type { RequestConfig } from "@umijs/max"; | import type { RequestConfig } from "@umijs/max"; | ||||
| import { Layout, Modal, Dropdown, Flex, Row, Col, ConfigProvider, Button } from "antd"; | |||||
| import { Layout, Modal, Dropdown, Image, Flex, Col, ConfigProvider, Button, Space } from "antd"; | |||||
| import { HomeOutlined, LogoutOutlined, FileTextOutlined } from '@ant-design/icons'; | import { HomeOutlined, LogoutOutlined, FileTextOutlined } from '@ant-design/icons'; | ||||
| import { baseUrl } from './constants/index' | import { baseUrl } from './constants/index' | ||||
| import routes from '../config/routes' | import routes from '../config/routes' | ||||
| return { | return { | ||||
| title: '菊城人才网', | title: '菊城人才网', | ||||
| logo: '/images/onlylogo.jpg', | logo: '/images/onlylogo.jpg', | ||||
| headerTitleRender: (logo, title, props) => { | |||||
| return ( | |||||
| <> | |||||
| <a href="/talent/home"> | |||||
| <Flex align='center' > | |||||
| {logo} | |||||
| <div style={{ margin: '0 40px 0 8px', fontSize: 18, color: '#000000' }}>菊城人才网</div> | |||||
| </Flex> | |||||
| </a> | |||||
| </> | |||||
| ); | |||||
| }, | |||||
| menuRender: false, | menuRender: false, | ||||
| layout: 'top', | layout: 'top', | ||||
| token: { | token: { | ||||
| header: { | header: { | ||||
| colorTextMenuSelected: '#19be6e', | colorTextMenuSelected: '#19be6e', | ||||
| heightLayoutHeader: 90, | heightLayoutHeader: 90, | ||||
| }, | }, | ||||
| }, | }, | ||||
| onPageChange: (location) => { | onPageChange: (location) => { | ||||
| let idx = localStorage.getItem('idx') | let idx = localStorage.getItem('idx') | ||||
| if (Number(idx) == 1) { | if (Number(idx) == 1) { | ||||
| routes[Number(idx)].flatMenu = true; | routes[Number(idx)].flatMenu = true; | ||||
| routes[3].flatMenu = false; | |||||
| routes[2].flatMenu = false; | |||||
| } | } | ||||
| if (Number(idx) != 2) { | |||||
| if (Number(idx) == 2) { | |||||
| routes[Number(idx)].flatMenu = true; | routes[Number(idx)].flatMenu = true; | ||||
| routes[1].flatMenu = false; | |||||
| } | } | ||||
| if (Number(idx) == 3) { | if (Number(idx) == 3) { | ||||
| routes[Number(idx)].flatMenu = true; | |||||
| routes[1].flatMenu = false; | |||||
| routes[2].flatMenu = true; | |||||
| } | } | ||||
| } else { | } else { | ||||
| routes[1].flatMenu = false; | routes[1].flatMenu = false; | ||||
| routes[2].flatMenu = false; | |||||
| routes[3].flatMenu = true; | |||||
| routes[2].flatMenu = true; | |||||
| } | } | ||||
| return [routes[0], routes[1], routes[2], routes[3]] | return [routes[0], routes[1], routes[2], routes[3]] | ||||
| // return [routes[0], routes[3]] | // return [routes[0], routes[3]] |
| setList(res.data.articles && res.data.articles.length > 0 ? res.data.articles : []) | setList(res.data.articles && res.data.articles.length > 0 ? res.data.articles : []) | ||||
| setTotal(res.data.total) | setTotal(res.data.total) | ||||
| }) | }) | ||||
| } else { | |||||
| setList([]) | |||||
| setTotal(0) | |||||
| } | } | ||||
| }, [id]); | }, [id]); | ||||
| const [detail, setDetail] = useState<object | null>(null) | const [detail, setDetail] = useState<object | null>(null) | ||||
| useEffect(() => { | useEffect(() => { | ||||
| console.log(id) | |||||
| if (id) { | if (id) { | ||||
| GetArticleList({ page: 1, pagesize: 10, section_id: id }).then(res => { | GetArticleList({ page: 1, pagesize: 10, section_id: id }).then(res => { | ||||
| if (res.data.articles && res.data.articles.length > 0) { | if (res.data.articles && res.data.articles.length > 0) { | ||||
| GetArticleDetail({ id: res.data.articles[0].id }).then(res => { | GetArticleDetail({ id: res.data.articles[0].id }).then(res => { | ||||
| setDetail(res.data) | setDetail(res.data) | ||||
| }) | }) | ||||
| } else { | |||||
| setDetail(null) | |||||
| } | } | ||||
| }) | }) | ||||
| } else { | |||||
| setDetail(null) | |||||
| } | } | ||||
| }, [id]); | }, [id]); | ||||
| > | > | ||||
| { | { | ||||
| detail && | detail && | ||||
| <div style={{ minHeight: 300, background: '#f2f2f2', borderRadius: 8, padding: 20, lineHeight: 2 }}> | |||||
| <div style={{ minHeight: 300, background: '#f2f2f2', borderRadius: 8, padding: 20, margin: '20px 0', lineHeight: 2 }}> | |||||
| <div dangerouslySetInnerHTML={{ __html: he.decode(detail.content) }} /> | <div dangerouslySetInnerHTML={{ __html: he.decode(detail.content) }} /> | ||||
| </div> | </div> | ||||
| setList(res.data.articles && res.data.articles.length > 0 ? res.data.articles : []) | setList(res.data.articles && res.data.articles.length > 0 ? res.data.articles : []) | ||||
| setTotal(res.data.total) | setTotal(res.data.total) | ||||
| }) | }) | ||||
| } else { | |||||
| setList([]) | |||||
| setTotal(0) | |||||
| } | } | ||||
| }, [id]); | }, [id]); | ||||
| <Space direction='vertical' size={10} style={{ | <Space direction='vertical' size={10} style={{ | ||||
| width: '100%', | width: '100%', | ||||
| }}> | }}> | ||||
| <TitleIndex title="园区企业" link="/sciencetechnologypark/company"></TitleIndex> | |||||
| <TitleIndex title="园区企业" link="/sciencetechnologypark/company" hasMore={true}></TitleIndex> | |||||
| <Row gutter={[16, 16]}> | <Row gutter={[16, 16]}> | ||||
| { | { | ||||
| advertscheduleList && advertscheduleList.length > 0 && advertscheduleList.map((item, index) => ( | advertscheduleList && advertscheduleList.length > 0 && advertscheduleList.map((item, index) => ( |
| } | } | ||||
| }} | }} | ||||
| > | > | ||||
| <TitleIndex title="合作伙伴" link="/sciencetechnologypark/news"></TitleIndex> | |||||
| <TitleIndex title="合作伙伴" link="/sciencetechnologypark/news" hasMore={true}></TitleIndex> | |||||
| <Row gutter={[20, 20]} style={{ marginTop: 10 }}> | <Row gutter={[20, 20]} style={{ marginTop: 10 }}> | ||||
| { | { | ||||
| </Space> | </Space> | ||||
| </Link> | </Link> | ||||
| </Col> | </Col> | ||||
| </> | </> | ||||
| )) | )) | ||||
| } | } | ||||
| { | { | ||||
| !advertscheduleList || advertscheduleList.length == 0 && <Flex justify='center' align='center' style={{ padding: '16px', borderRadius: 8, cursor: 'pointer' }}> | |||||
| !advertscheduleList || advertscheduleList.length == 0 && <Flex justify='center' align='center' style={{ width: '100%', padding: '16px', borderRadius: 8, cursor: 'pointer' }}> | |||||
| <EmptyResult description="暂无数据" /> | <EmptyResult description="暂无数据" /> | ||||
| </Flex> | </Flex> | ||||
| } | } |
| import { useState, useEffect, useRef } from 'react'; | import { useState, useEffect, useRef } from 'react'; | ||||
| import { ProList, PageContainer } from '@ant-design/pro-components'; | import { ProList, PageContainer } from '@ant-design/pro-components'; | ||||
| import { ConfigProvider, Button, Flex, Input, Space, Image, Carousel, Row, Col, Divider, Tag, Card, Avatar, Typography } from 'antd'; | |||||
| import { SearchOutlined, FireOutlined, MessageOutlined, StarOutlined } from '@ant-design/icons'; | |||||
| import { ConfigProvider, Button, Flex, Input, Space, Image, Select, Row, Col, Divider, Tag, Card, Avatar, Typography } from 'antd'; | |||||
| import { SearchOutlined, FireOutlined, MessageOutlined, RightOutlined } from '@ant-design/icons'; | |||||
| import { useModel, connect, history, Link } from 'umi'; | import { useModel, connect, history, Link } from 'umi'; | ||||
| import { Imageprefix } from '@/constants'; | |||||
| import { GetAdvertscheduleList } from '@/services/apis/advertschedule'; | import { GetAdvertscheduleList } from '@/services/apis/advertschedule'; | ||||
| import { Imageprefix } from '@/constants'; | |||||
| const HomeNewJob: React.FC = () => { | |||||
| const HomeProbation: React.FC = () => { | |||||
| const [list, setList] = useState<object[]>([]) | const [list, setList] = useState<object[]>([]) | ||||
| const [total, setTotal] = useState<number>(0) | const [total, setTotal] = useState<number>(0) | ||||
| const [page, setPage] = useState<number>(1) | const [page, setPage] = useState<number>(1) | ||||
| const [pageSize, setPageSize] = useState<number>(12) | const [pageSize, setPageSize] = useState<number>(12) | ||||
| const [adposition, setAdposition] = useState({}); | |||||
| const [adpositionList, setAdpositionList] = useState<any[]>([]); | |||||
| useEffect(() => { | useEffect(() => { | ||||
| GetAdvertscheduleList({ pagesize: 20, code: 'RMQYGGT' }).then(res => { | GetAdvertscheduleList({ pagesize: 20, code: 'RMQYGGT' }).then(res => { | ||||
| setAdposition(res.data.advertarea) | |||||
| setAdpositionList(res.data.advertschedules) | |||||
| setList(res.data.advertschedules) | |||||
| }) | }) | ||||
| }, []); | }, []); | ||||
| } | } | ||||
| }} | }} | ||||
| > | > | ||||
| <Carousel autoplay arrows dots={false} style={{ background: '#364d79', borderRadius: 8, width: '100%', padding: '30px' }}> | |||||
| <div style={{ width: '100%' }}> | |||||
| <Row gutter={[10, 10]}> | |||||
| { | |||||
| adpositionList && adpositionList.length > 0 && adpositionList.map((item: any, index: number) => ( | |||||
| <> | |||||
| <Col span={8}> | |||||
| <Card size="small" | |||||
| // cover={ | |||||
| // <Image src={`${Imageprefix}${item.image_url}`} width={adposition.width + 'px'} height={adposition.height + 'px'} preview={false} /> | |||||
| // } | |||||
| styles={{ | |||||
| cover: { | |||||
| display: 'flex', | |||||
| justifyContent: 'center', | |||||
| alignItems: 'center', | |||||
| paddingTop: '8px', | |||||
| cursor: 'pointer', | |||||
| }, | |||||
| header: { | |||||
| borderBottom: 'none' | |||||
| }, | |||||
| title: { | |||||
| fontSize: '14px' | |||||
| }, | |||||
| }}> | |||||
| <Card.Meta | |||||
| avatar={<Avatar src={`${Imageprefix}${item.image_url}`} size={48} shape='square' />} | |||||
| style={{ marginBottom: 10 }} | |||||
| title={ | |||||
| <> | |||||
| <Link to={{ pathname: `/job/detail?id=${item.id}` }} target="_blank" style={{ color: '#000000', fontSize: '16px' }}> | |||||
| <Flex > | |||||
| {item.company_name} | |||||
| </Flex> | |||||
| </Link> | |||||
| </> | |||||
| } | |||||
| description={ | |||||
| <> | |||||
| <Flex style={{ color: 'gray', fontSize: '12px' }}> | |||||
| {item.company_nature ? item.company_nature : '性质不限'} | |||||
| <Divider type="vertical" /> | |||||
| {item.company_scale ? item.company_scale : '规模不限'} | |||||
| </Flex> | |||||
| </>} | |||||
| /> | |||||
| <div style={{ minHeight: '120px' }}> | |||||
| <Typography.Paragraph ellipsis={{ rows: 4, expandable: true, symbol: '详情' }}> | |||||
| {item.ad_description} | |||||
| </Typography.Paragraph> | |||||
| </div> | |||||
| <Button size='large' block color="primary" variant="filled">21个在招职位</Button> | |||||
| </Card> | |||||
| </Col> | |||||
| </> | |||||
| )) | |||||
| } | |||||
| </Row> | |||||
| </div> | |||||
| </Carousel> | |||||
| <Space direction='vertical' size={20} style={{ width: '1152px' }}> | |||||
| {/* <Flex justify='center' align='center'> | |||||
| <Typography.Title level={2}>见习基地</Typography.Title> | |||||
| </Flex> */} | |||||
| <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>热门企业</Typography.Title></Divider> | |||||
| <Row gutter={[10, 10]}> | |||||
| { | |||||
| list.length > 0 && list.map((item: any, index: number) => ( | |||||
| <> | |||||
| <Col span={8}> | |||||
| <Link to={{ pathname: `/talent/company/detail?id=${item.company_id}` }} target="_blank" style={{ width: '100%' }}> | |||||
| <Space direction='vertical' size={10} align='center' style={{ width: '100%', paddingBottom: 20, background: '#ffffff', borderRadius: 8 }}> | |||||
| <Image src={item.image_url ? `${Imageprefix}${item.image_url}` : '/images/logo.jpg'} preview={false} width={'200px'} height={'112px'} style={{ borderRadius: '8px 8px 0 0' }}></Image> | |||||
| <Typography.Title level={5} style={{ width: '100%', padding: '0 10px' }} | |||||
| > | |||||
| {item.company_name} | |||||
| </Typography.Title> | |||||
| <Flex justify='flex-end' align='center' style={{ fontSize: 14, color: '#999' }}> | |||||
| {item.company_nature ? <>{item.company_nature}</> : <>性质不限</>} | |||||
| {item.industry_text ? <><Divider type='vertical' /> {item.industry_text} </> : <><Divider type='vertical' />行业不限</>} | |||||
| {item.scale_text ? <><Divider type='vertical' /> {item.scale_text} </> : <><Divider type='vertical' />规模不限</>} | |||||
| </Flex> | |||||
| </Space> | |||||
| </Link> | |||||
| </Col> | |||||
| </> | |||||
| )) | |||||
| } | |||||
| </Row> | |||||
| <Flex justify='center' align='center'> | |||||
| <Space> | |||||
| <Link to={{ pathname: '/talent/search' }}> | |||||
| <Button icon={<RightOutlined />} iconPosition='end'>更多企业</Button> | |||||
| </Link> | |||||
| </Space> | |||||
| </Flex> | |||||
| </Space> | |||||
| </ConfigProvider > | </ConfigProvider > | ||||
| ); | ); | ||||
| }; | }; | ||||
| export default HomeNewJob; | |||||
| {/* <ProList | |||||
| ghost | |||||
| grid={{ gutter: 20, column: 2 }} | |||||
| rowKey="id" | |||||
| dataSource={list} | |||||
| request={async (params = {} as Record<string, any>) => | |||||
| PostJobSearch({ | |||||
| page: 1, | |||||
| pagesize: 2, | |||||
| sort: 'id', | |||||
| sortby: 'desc', | |||||
| }).then(res => { | |||||
| setList(res.data.jobs) | |||||
| setTotal(res.data.total) | |||||
| }) | |||||
| } | |||||
| showActions="hover" | |||||
| metas={{ | |||||
| title: { | |||||
| dataIndex: 'name' | |||||
| }, | |||||
| subTitle: { | |||||
| }, | |||||
| actions: { | |||||
| render: () => [<StarOutlined />] | |||||
| }, | |||||
| content: { | |||||
| render: (text, row) => { | |||||
| return ( | |||||
| <> | |||||
| <Space direction='vertical' style={{ marginBottom: 10 }}> | |||||
| <Space size={4}> | |||||
| <Tag> | |||||
| {row.experience_text ? row.experience_text : '经验不限'} | |||||
| </Tag> | |||||
| <Tag> | |||||
| {row.school_degree_text ? row.school_degree_text : '学历不限'} | |||||
| </Tag> | |||||
| <Tag> | |||||
| {row.profelevel_text ? '职称不限' : '职称不限'} | |||||
| </Tag> | |||||
| </Space> | |||||
| <Space size={10}> | |||||
| <Avatar src="/images/onlylogo.jpg" style={{ width: 48, height: 48 }} /> | |||||
| <Space direction='vertical' style={{ height: 48 }}> | |||||
| <Link to='/'>{row.full_name}</Link> | |||||
| <div style={{fontSize: 12}}>{row.locations ? row.locations[0].name : '未知地址'}</div> | |||||
| </Space> | |||||
| </Space> | |||||
| </Space> | |||||
| </> | |||||
| ) | |||||
| } | |||||
| } | |||||
| }} | |||||
| /> */} | |||||
| export default HomeProbation; | |||||
| import { useState, useEffect, useRef } from 'react'; | import { useState, useEffect, useRef } from 'react'; | ||||
| import { ProList, PageContainer } from '@ant-design/pro-components'; | import { ProList, PageContainer } from '@ant-design/pro-components'; | ||||
| import { ConfigProvider, Button, Flex, Input, Space, Image, Pagination, Row, Col, Divider, Tag, Card, Avatar, Typography } from 'antd'; | |||||
| import { ConfigProvider, Button, Flex, Input, Space, Image, Pagination, Row, Col, Divider, Tag, Card, Affix, Typography } from 'antd'; | |||||
| import { EllipsisOutlined, FireOutlined, LeftOutlined, RightOutlined, StarOutlined } from '@ant-design/icons'; | import { EllipsisOutlined, FireOutlined, LeftOutlined, RightOutlined, StarOutlined } from '@ant-design/icons'; | ||||
| import { useModel, connect, history, Link } from 'umi'; | import { useModel, connect, history, Link } from 'umi'; | ||||
| import { Imageprefix } from '@/constants'; | |||||
| import { GetRecruitmentList } from '@/services/apis/fair'; | import { GetRecruitmentList } from '@/services/apis/fair'; | ||||
| <Typography.Title level={2}>知名企业</Typography.Title> | <Typography.Title level={2}>知名企业</Typography.Title> | ||||
| </Flex> */} | </Flex> */} | ||||
| <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>招聘会</Typography.Title></Divider> | <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>招聘会</Typography.Title></Divider> | ||||
| <Row gutter={[10, 10]}> | |||||
| <Row gutter={[16, 16]}> | |||||
| { | { | ||||
| list.length > 0 && list.map((item: any, index: number) => ( | list.length > 0 && list.map((item: any, index: number) => ( | ||||
| <> | <> | ||||
| <Col> | |||||
| <Card size="small" style={{background: '#edfff3'}} | |||||
| styles={{ | |||||
| title: { | |||||
| fontSize: '14px' | |||||
| }, | |||||
| }}> | |||||
| <Card.Meta | |||||
| title={ | |||||
| <> | |||||
| <Link to={{ pathname: `/talent/fair/detail?keyword=${item.title}` }} target="_blank" style={{ color: '#000000', fontSize: '16px' }}> | |||||
| <Flex justify='center' align='center'> | |||||
| {item.title} | |||||
| </Flex> | |||||
| </Link> | |||||
| </> | |||||
| } | |||||
| /> | |||||
| </Card> | |||||
| <Col span={8}> | |||||
| <Link to={{ pathname: `/talent/fair/detail?keyword=${item.title}` }} target="_blank" style={{ width: '100%' }}> | |||||
| <Space direction='vertical' size={10} align='center' style={{ width: '100%', background: '#ffffff', borderRadius: 8 }}> | |||||
| <Image src={item.photo ? `${Imageprefix}${item.photo}` : '/images/bg.jpg'} preview={false} width={'100%'} height={'210px'} style={{ borderRadius: '8px 8px 0 0' }}></Image> | |||||
| <Affix style={{ position: 'absolute', top: 10, right: 0 }}> | |||||
| <Tag color="#19be6e">{item.open_date}</Tag> | |||||
| </Affix> | |||||
| <Typography.Title level={5} style={{ width: '100%', padding: '0 10px' }} | |||||
| > | |||||
| {item.title} | |||||
| </Typography.Title> | |||||
| </Space> | |||||
| </Link> | |||||
| </Col> | </Col> | ||||
| </> | </> | ||||
| )) | )) | ||||
| </Row> | </Row> | ||||
| <Flex justify='center' align='center'> | <Flex justify='center' align='center'> | ||||
| <Space> | <Space> | ||||
| <Link to={{ pathname: '/talent/search' }}> | |||||
| <Link to={{ pathname: '/talent/fair' }}> | |||||
| <Button icon={<RightOutlined />} iconPosition='end'>更多招聘会</Button> | <Button icon={<RightOutlined />} iconPosition='end'>更多招聘会</Button> | ||||
| </Link> | </Link> | ||||
| </Space> | </Space> |
| import { ConfigProvider, Button, Flex, Input, Space, Image, Pagination, Row, Col, Divider, Tag, Card, Avatar, Typography } from 'antd'; | import { ConfigProvider, Button, Flex, Input, Space, Image, Pagination, Row, Col, Divider, Tag, Card, Avatar, Typography } from 'antd'; | ||||
| import { EllipsisOutlined, FireOutlined, LeftOutlined, RightOutlined, StarOutlined } from '@ant-design/icons'; | import { EllipsisOutlined, FireOutlined, LeftOutlined, RightOutlined, StarOutlined } from '@ant-design/icons'; | ||||
| import { useModel, connect, history, Link } from 'umi'; | import { useModel, connect, history, Link } from 'umi'; | ||||
| import { GetCompanyFamousList } from '@/services/apis/company'; | |||||
| import { Imageprefix } from '@/constants'; | |||||
| import { GetCompanyFamousList } from '@/services/apis/company'; | |||||
| const HomeFamous: React.FC = () => { | const HomeFamous: React.FC = () => { | ||||
| const [list, setList] = useState<object[]>([]) | const [list, setList] = useState<object[]>([]) | ||||
| const [pageSize, setPageSize] = useState<number>(12) | const [pageSize, setPageSize] = useState<number>(12) | ||||
| useEffect(() => { | useEffect(() => { | ||||
| GetCompanyFamousList({ page: 1, pagesize: 12 }).then(res => { | |||||
| GetCompanyFamousList({ page: 1, pagesize: 9 }).then(res => { | |||||
| setList(res.data.list) | setList(res.data.list) | ||||
| }) | }) | ||||
| }, []); | }, []); | ||||
| { | { | ||||
| list.length > 0 && list.map((item: any, index: number) => ( | list.length > 0 && list.map((item: any, index: number) => ( | ||||
| <> | <> | ||||
| <Col> | |||||
| <Card size="small" | |||||
| styles={{ | |||||
| title: { | |||||
| fontSize: '14px' | |||||
| }, | |||||
| }}> | |||||
| <Card.Meta | |||||
| title={ | |||||
| <> | |||||
| <Link to={{ pathname: `/talent/company/detail?id=${item.id}` }} target="_blank" style={{ color: '#000000', fontSize: '16px' }}> | |||||
| <Flex justify='center' align='center'> | |||||
| {item.full_name} | |||||
| </Flex> | |||||
| </Link> | |||||
| </> | |||||
| } | |||||
| /> | |||||
| </Card> | |||||
| <Col span={8}> | |||||
| <Link to={{ pathname: `/talent/company/detail?id=${item.id}` }} target="_blank" style={{ width: '100%' }}> | |||||
| <Space direction='vertical' size={10} align='center' style={{ width: '100%', paddingBottom: 20, background: '#ffffff', borderRadius: 8 }}> | |||||
| <Image src={item.photo ? `${Imageprefix}${item.photo}` : '/images/logo.jpg'} preview={false} width={'200px'} height={'112px'} style={{ borderRadius: '8px 8px 0 0' }}></Image> | |||||
| <Typography.Title level={5} style={{ width: '100%', padding: '0 10px' }} | |||||
| > | |||||
| {item.full_name} | |||||
| </Typography.Title> | |||||
| <Flex justify='flex-end' align='center' style={{ fontSize: 14, color: '#999' }}> | |||||
| {item.nature_text ? <>{item.nature_text}</> : <>性质不限</>} | |||||
| {item.industry_text ? <><Divider type='vertical' /> {item.industry_text} </> : <><Divider type='vertical' />行业不限</>} | |||||
| {item.scale_text ? <><Divider type='vertical' /> {item.scale_text} </> : <><Divider type='vertical' />规模不限</>} | |||||
| </Flex> | |||||
| </Space> | |||||
| </Link> | |||||
| </Col> | </Col> | ||||
| </> | </> | ||||
| )) | )) |
| import { useState, useEffect, useRef } from 'react'; | import { useState, useEffect, useRef } from 'react'; | ||||
| import { ProList, PageContainer } from '@ant-design/pro-components'; | import { ProList, PageContainer } from '@ant-design/pro-components'; | ||||
| import { ConfigProvider, Button, Flex, Input, Space, Image, Pagination, Row, Col, Carousel, Tag, Card, Avatar, Typography } from 'antd'; | |||||
| import { EllipsisOutlined, FireOutlined, LeftOutlined, RightOutlined, StarOutlined } from '@ant-design/icons'; | |||||
| import { ConfigProvider, Button, Flex, Input, Space, Image, Pagination, Row, Col, Divider, Tag, Card, Avatar, Typography } from 'antd'; | |||||
| import { EllipsisOutlined, FireOutlined, EnvironmentOutlined, RightOutlined, StarOutlined } from '@ant-design/icons'; | |||||
| import { useModel, connect, history, Link } from 'umi'; | import { useModel, connect, history, Link } from 'umi'; | ||||
| import { PostJobSearch } from '@/services/apis/post'; | import { PostJobSearch } from '@/services/apis/post'; | ||||
| import CommonJob from '@/components/Common/Job' | |||||
| const HomeNewJob: React.FC = () => { | const HomeNewJob: React.FC = () => { | ||||
| const [list, setList] = useState<object[]>([]) | const [list, setList] = useState<object[]>([]) | ||||
| const [total, setTotal] = useState<number>(0) | const [total, setTotal] = useState<number>(0) | ||||
| }} | }} | ||||
| > | > | ||||
| <Space direction='vertical' size={30} style={{ width: '1152px' }}> | |||||
| <Flex justify='center' align='center'> | |||||
| <Typography.Title level={2}>高薪职位</Typography.Title> | |||||
| </Flex> | |||||
| <Space direction='vertical' size={20} style={{ width: '1152px' }}> | |||||
| {/* <Flex justify='center' align='center'> | |||||
| <Typography.Title level={2}>热门职位</Typography.Title> | |||||
| </Flex> */} | |||||
| {/* <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>热门职位</Typography.Title></Divider> */} | |||||
| <Row gutter={[10, 10]}> | <Row gutter={[10, 10]}> | ||||
| { | { | ||||
| list.length > 0 && list.map((item: any, index: number) => ( | list.length > 0 && list.map((item: any, index: number) => ( | ||||
| <> | <> | ||||
| <Col span={12}> | |||||
| <Card size='small' | |||||
| title={ | |||||
| <> | |||||
| <Link to={{ pathname: `/talent/job/detail?id=${item.id}` }} target="_blank" style={{ color: '#000000', fontSize: 16, marginRight: 10 }}> | |||||
| {item.name} | |||||
| </Link> | |||||
| {item.urgent === 1 && <Tag icon={<FireOutlined />} bordered={false} color="#f50">急招</Tag>} | |||||
| </> | |||||
| } | |||||
| extra={<StarOutlined style={{ fontSize: '24px' }} />} | |||||
| styles={{ | |||||
| header: { | |||||
| padding: '8px 16px ', | |||||
| borderBottom: 'none' | |||||
| }, | |||||
| title: { | |||||
| fontSize: '14px' | |||||
| }, | |||||
| }}> | |||||
| <Space size={16} direction='vertical'> | |||||
| <Space size={0}> | |||||
| <Tag>{item.experience_text ? item.experience_text : '经验不限'}</Tag> | |||||
| <Tag> {item.school_degree_text ? item.school_degree_text : '学历不限'}</Tag> | |||||
| <Tag> {item.profelevel_text ? item.profelevel_text : '职称不限'}</Tag> | |||||
| </Space> | |||||
| <Space size={16}> | |||||
| <Avatar src="/images/onlylogo.jpg" size={36} /> | |||||
| <Space direction='vertical' size={0}> | |||||
| <Link to={{ pathname: `/talent/company/detail?id=${item.id}` }} target="_blank" style={{ color: '#000000', fontSize: '12px' }}> | |||||
| {item.full_name} | |||||
| </Link> | |||||
| <div style={{ fontSize: '12px' }}>{item.locations ? item.locations[0].name : '未知地址'}</div> | |||||
| </Space> | |||||
| </Space> | |||||
| </Space> | |||||
| </Card> | |||||
| <Col span={24}> | |||||
| <CommonJob item={item}></CommonJob> | |||||
| </Col> | </Col> | ||||
| </> | </> | ||||
| )) | )) | ||||
| export default HomeNewJob; | export default HomeNewJob; | ||||
| {/* <ProList | |||||
| ghost | |||||
| grid={{ gutter: 20, column: 2 }} | |||||
| rowKey="id" | |||||
| dataSource={list} | |||||
| request={async (params = {} as Record<string, any>) => | |||||
| PostJobSearch({ | |||||
| page: 1, | |||||
| pagesize: 2, | |||||
| sort: 'id', | |||||
| sortby: 'desc', | |||||
| }).then(res => { | |||||
| setList(res.data.jobs) | |||||
| setTotal(res.data.total) | |||||
| }) | |||||
| } | |||||
| showActions="hover" | |||||
| metas={{ | |||||
| title: { | |||||
| dataIndex: 'name' | |||||
| }, | |||||
| subTitle: { | |||||
| }, | |||||
| actions: { | |||||
| render: () => [<StarOutlined />] | |||||
| }, | |||||
| content: { | |||||
| render: (text, row) => { | |||||
| return ( | |||||
| <> | |||||
| <Space direction='vertical' style={{ marginBottom: 10 }}> | |||||
| <Space size={4}> | |||||
| <Tag> | |||||
| {row.experience_text ? row.experience_text : '经验不限'} | |||||
| </Tag> | |||||
| <Tag> | |||||
| {row.school_degree_text ? row.school_degree_text : '学历不限'} | |||||
| </Tag> | |||||
| <Tag> | |||||
| {row.profelevel_text ? '职称不限' : '职称不限'} | |||||
| </Tag> | |||||
| </Space> | |||||
| <Space size={10}> | |||||
| <Avatar src="/images/onlylogo.jpg" style={{ width: 48, height: 48 }} /> | |||||
| <Space direction='vertical' style={{ height: 48 }}> | |||||
| <Link to='/'>{row.full_name}</Link> | |||||
| <div style={{fontSize: 12}}>{row.locations ? row.locations[0].name : '未知地址'}</div> | |||||
| </Space> | |||||
| </Space> | |||||
| </Space> | |||||
| </> | |||||
| ) | |||||
| } | |||||
| } | |||||
| }} | |||||
| /> */} |
| {/* <Flex justify='center' align='center'> | {/* <Flex justify='center' align='center'> | ||||
| <Typography.Title level={2}>热门职位</Typography.Title> | <Typography.Title level={2}>热门职位</Typography.Title> | ||||
| </Flex> */} | </Flex> */} | ||||
| <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>热门职位</Typography.Title></Divider> | |||||
| {/* <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>热门职位</Typography.Title></Divider> */} | |||||
| <Row gutter={[10, 10]}> | <Row gutter={[10, 10]}> | ||||
| { | { | ||||
| list.length > 0 && list.map((item: any, index: number) => ( | list.length > 0 && list.map((item: any, index: number) => ( |
| <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>见习基地</Typography.Title></Divider> | <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>见习基地</Typography.Title></Divider> | ||||
| <Row gutter={[10, 10]}> | <Row gutter={[10, 10]}> | ||||
| { | |||||
| { | |||||
| list.length > 0 && list.map((item: any, index: number) => ( | list.length > 0 && list.map((item: any, index: number) => ( | ||||
| <> | <> | ||||
| <Col> | |||||
| <Card size="small" | |||||
| styles={{ | |||||
| title: { | |||||
| fontSize: '14px' | |||||
| }, | |||||
| }}> | |||||
| <Card.Meta | |||||
| title={ | |||||
| <> | |||||
| <Link to={{ pathname: `/talent/company/detail?id=${item.id}` }} target="_blank" style={{ color: '#000000', fontSize: '16px' }}> | |||||
| <Flex justify='center' align='center'> | |||||
| {item.full_name} | |||||
| </Flex> | |||||
| </Link> | |||||
| </> | |||||
| } | |||||
| /> | |||||
| </Card> | |||||
| <Col span={8}> | |||||
| <Link to={{ pathname: `/talent/company/detail?id=${item.id}` }} target="_blank" style={{ width: '100%' }}> | |||||
| <Space direction='vertical' size={10} align='center' style={{ width: '100%', paddingBottom: 20, background: '#ffffff', borderRadius: 8 }}> | |||||
| <Image src={item.photo ? `${Imageprefix}${item.photo}` : '/images/logo.jpg'} preview={false} width={'200px'} height={'112px'} style={{ borderRadius: '8px 8px 0 0' }}></Image> | |||||
| <Typography.Title level={5} style={{ width: '100%', padding: '0 10px' }} | |||||
| > | |||||
| {item.full_name} | |||||
| </Typography.Title> | |||||
| <Flex justify='flex-end' align='center' style={{ fontSize: 14, color: '#999' }}> | |||||
| {item.nature_text ? <>{item.nature_text}</> : <>性质不限</>} | |||||
| {item.industry_text ? <><Divider type='vertical' /> {item.industry_text} </> : <><Divider type='vertical' />行业不限</>} | |||||
| {item.scale_text ? <><Divider type='vertical' /> {item.scale_text} </> : <><Divider type='vertical' />规模不限</>} | |||||
| </Flex> | |||||
| </Space> | |||||
| </Link> | |||||
| </Col> | </Col> | ||||
| </> | </> | ||||
| )) | )) |
| {/* <Flex justify='center' align='center'> | {/* <Flex justify='center' align='center'> | ||||
| <Typography.Title level={2}>急招职位</Typography.Title> | <Typography.Title level={2}>急招职位</Typography.Title> | ||||
| </Flex> */} | </Flex> */} | ||||
| <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>急招职位</Typography.Title></Divider> | |||||
| {/* <Divider orientation="left" orientationMargin="0"><Typography.Title level={2}>急招职位</Typography.Title></Divider> */} | |||||
| <Row gutter={[10, 10]}> | <Row gutter={[10, 10]}> | ||||
| { | { |
| import { useState, useEffect, useRef } from 'react'; | import { useState, useEffect, useRef } from 'react'; | ||||
| import { ProList, PageContainer } from '@ant-design/pro-components'; | import { ProList, PageContainer } from '@ant-design/pro-components'; | ||||
| import type { BadgeProps, CalendarProps } from 'antd'; | import type { BadgeProps, CalendarProps } from 'antd'; | ||||
| import { ConfigProvider, Button, Flex, Card, Space, Tabs, Calendar, Row, Col, Descriptions, Statistic, Divider, Avatar, Anchor } from 'antd'; | |||||
| import { ConfigProvider, Button, Flex, Card, Space, Tabs, Calendar, Row, Col, Descriptions, Statistic, Divider, Modal, Anchor } from 'antd'; | |||||
| import { SearchOutlined, LikeOutlined, ArrowDownOutlined, CameraOutlined } from '@ant-design/icons'; | import { SearchOutlined, LikeOutlined, ArrowDownOutlined, CameraOutlined } from '@ant-design/icons'; | ||||
| import { useModel, connect, history, Link } from 'umi'; | import { useModel, connect, history, Link } from 'umi'; | ||||
| import { findItemById } from '@/utils/dataHelper' | |||||
| import { GetCompanyDetailInfo, GetCompanyProfile, GetCompanyResumeList, GetCompanyInterviewList, GetCompanyTalentPoolList } from '@/services/apis/company' | import { GetCompanyDetailInfo, GetCompanyProfile, GetCompanyResumeList, GetCompanyInterviewList, GetCompanyTalentPoolList } from '@/services/apis/company' | ||||
| import { GetCompanyJobList } from '@/services/apis/post'; | import { GetCompanyJobList } from '@/services/apis/post'; | ||||
| import ManageCompanyResumeRecomment from '@/components/Manage/Company/Resume/Recomment' | import ManageCompanyResumeRecomment from '@/components/Manage/Company/Resume/Recomment' | ||||
| const HomePage: React.FC = () => { | |||||
| const HomePage: React.FC = ({ dispatch, dictModel }: any) => { | |||||
| const [detail, setDetail] = useState({}) | const [detail, setDetail] = useState({}) | ||||
| const [detail1, setDetail1] = useState({}) | const [detail1, setDetail1] = useState({}) | ||||
| const [companyJobTotal, setCompanyJobTotal] = useState<number>(0); | const [companyJobTotal, setCompanyJobTotal] = useState<number>(0); | ||||
| }) | }) | ||||
| }, []) | }, []) | ||||
| useEffect(() => { | |||||
| dispatch({ type: 'dictModel/getList', payload: { code: 2027, type: 'setIndustryPostList' } }) | |||||
| }, [dispatch]) | |||||
| useEffect(() => { | |||||
| if (dictModel.industryPostList.length > 0 && detail) { | |||||
| if (detail) { | |||||
| let allFound = true; // 假设所有 id 都找到了 | |||||
| let result = findItemById(dictModel.industryPostList, detail.industry); | |||||
| if(result) { | |||||
| result = findItemById(dictModel.industryPostList, 11133); | |||||
| } | |||||
| if (!result) { | |||||
| allFound = false; // 找到一个未匹配的 id | |||||
| } | |||||
| console.log(allFound) | |||||
| if (!allFound) { | |||||
| Modal.confirm({ | |||||
| title: '更新提示', | |||||
| content: '行业职位类目已更新,请前往使用到行业职位类目的地方更新资料', | |||||
| onOk() { | |||||
| }, | |||||
| onCancel() { | |||||
| console.log('Cancel'); | |||||
| }, | |||||
| okText: '我知道了', | |||||
| cancelText: '取消', | |||||
| centered: true | |||||
| }); | |||||
| } | |||||
| } | |||||
| } | |||||
| }, [dictModel.industryPostList, detail]) | |||||
| return ( | return ( | ||||
| <> | <> | ||||
| ); | ); | ||||
| }; | }; | ||||
| export default HomePage; | |||||
| export default connect(({ dictModel }: any) => ({ | |||||
| dictModel | |||||
| }))(HomePage); | |||||
| import { useState, useEffect, useRef } from 'react'; | import { useState, useEffect, useRef } from 'react'; | ||||
| import { Link } from '@umijs/max'; | |||||
| import { Link, history, connect } from '@umijs/max'; | |||||
| import { HomeOutlined, FormOutlined, CameraOutlined } from '@ant-design/icons' | import { HomeOutlined, FormOutlined, CameraOutlined } from '@ant-design/icons' | ||||
| import { Space, Tabs, Button, Avatar, Row, Col, Progress, Flex, Card, Switch, Statistic, ConfigProvider } from 'antd'; | |||||
| import { Space, Tabs, Button, Avatar, Row, Col, Modal, Flex, Card, Switch, Statistic, ConfigProvider } from 'antd'; | |||||
| import { Imageprefix } from '@/constants/index' | import { Imageprefix } from '@/constants/index' | ||||
| import { findItemById } from '@/utils/dataHelper' | |||||
| import { GetJobseekerDetail, PostJobapplicantUpdate } from '@/services/apis/resume' | import { GetJobseekerDetail, PostJobapplicantUpdate } from '@/services/apis/resume' | ||||
| import EmptyResult from '@/components/Common/EmptyResult' | import EmptyResult from '@/components/Common/EmptyResult' | ||||
| const ManegeJobseekerHome: React.FC = () => { | |||||
| const ManegeJobseekerHome: React.FC = ({ dispatch, dictModel }: any) => { | |||||
| const [detail, setDetail] = useState<object | null>(null); | const [detail, setDetail] = useState<object | null>(null); | ||||
| const [favoriteTotal, setFavoriteTotal] = useState<number>(0); | const [favoriteTotal, setFavoriteTotal] = useState<number>(0); | ||||
| const [applicationTotal, setApplicationTotal] = useState<number>(0); | const [applicationTotal, setApplicationTotal] = useState<number>(0); | ||||
| const [interviewTotal, setInterviewTotal] = useState<number>(0); | const [interviewTotal, setInterviewTotal] = useState<number>(0); | ||||
| const [viewhistoryTotal, setViewhistoryTotal] = useState<number>(0); | const [viewhistoryTotal, setViewhistoryTotal] = useState<number>(0); | ||||
| useEffect(() => { | useEffect(() => { | ||||
| GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | ||||
| setDetail(res.data) | |||||
| }) | |||||
| setDetail(res.data); | |||||
| }); | |||||
| }, []) | }, []) | ||||
| useEffect(() => { | |||||
| dispatch({ type: 'dictModel/getList', payload: { code: 2027, type: 'setIndustryPostList' } }) | |||||
| }, [dispatch]) | |||||
| useEffect(() => { | |||||
| if (dictModel.industryPostList.length > 0 && detail) { | |||||
| if (detail.desire_industrys && detail.desire_industrys.length > 0) { | |||||
| let allFound = true; // 假设所有 id 都找到了 | |||||
| for (const item of detail.desire_industrys) { | |||||
| console.log('industryPostList:', dictModel.industryPostList); | |||||
| console.log('industry:', item.industry); | |||||
| const result = findItemById(dictModel.industryPostList, item.industry); | |||||
| console.log('result:', result); | |||||
| console.log('typeof result:', typeof result); | |||||
| if (!result) { | |||||
| allFound = false; // 找到一个未匹配的 id | |||||
| break; // 找到第一个不匹配的 id 后退出循环 | |||||
| } | |||||
| } | |||||
| console.log(allFound) | |||||
| if (!allFound) { | |||||
| Modal.confirm({ | |||||
| title: '更新提示', | |||||
| content: '行业职位类目已更新,请前往使用到行业职位类目的地方更新资料,提升求职率', | |||||
| onOk() { | |||||
| history.push('/manage/jobseeker/resume'); | |||||
| }, | |||||
| onCancel() { | |||||
| console.log('Cancel'); | |||||
| }, | |||||
| okText: '更新', | |||||
| cancelText: '取消', | |||||
| centered: true | |||||
| }); | |||||
| } | |||||
| } | |||||
| } | |||||
| }, [dictModel.industryPostList, detail]) | |||||
| useEffect(() => { | useEffect(() => { | ||||
| GetJobseekListapplication({ page: 1, pagesize: 10 }).then((res: any) => { | GetJobseekListapplication({ page: 1, pagesize: 10 }).then((res: any) => { | ||||
| getApplicationTotal(res.data.total ? res.data.total : 0) | getApplicationTotal(res.data.total ? res.data.total : 0) | ||||
| <Space direction='vertical' size={30} style={{ minHeight: 800 }}> | <Space direction='vertical' size={30} style={{ minHeight: 800 }}> | ||||
| {/* 头部 */} | {/* 头部 */} | ||||
| <Space direction='vertical' size={20} style={{ width: '100%', backgroundColor: '#ffffff', borderRadius: 8, padding: 20 }}> | <Space direction='vertical' size={20} style={{ width: '100%', backgroundColor: '#ffffff', borderRadius: 8, padding: 20 }}> | ||||
| {!detail && <EmptyResult description={<Link to="/manage/jobseeker/resume" style={{color: '#19be6e'}}>前往完善简历</Link>}></EmptyResult>} | |||||
| {!detail && <EmptyResult description={<Link to="/manage/jobseeker/resume" style={{ color: '#19be6e' }}>前往完善简历</Link>}></EmptyResult>} | |||||
| { | { | ||||
| detail && <> | detail && <> | ||||
| <Flex justify="center" align='flex-end'> | <Flex justify="center" align='flex-end'> | ||||
| </Flex> | </Flex> | ||||
| <Flex justify="center" align="center"> | <Flex justify="center" align="center"> | ||||
| <Space size={20}> | <Space size={20}> | ||||
| <Space><HomeOutlined />{detail.age}岁</Space> | |||||
| <Space><HomeOutlined />{detail.work_experience_txt}</Space> | |||||
| <Space><HomeOutlined />{detail.desire_positions && detail.desire_positions.length > 0 && detail.desire_positions[0].level2_txt}</Space> | |||||
| { | |||||
| detail.age && <><Space><HomeOutlined />{detail.age}岁</Space></> | |||||
| } | |||||
| { | |||||
| detail.work_experience_txt && <> <Space><HomeOutlined />{detail.work_experience_txt}</Space></> | |||||
| } | |||||
| { | |||||
| detail.desire_positions && detail.desire_positions.length > 0 && <> | |||||
| <Space><HomeOutlined />{detail.desire_positions && detail.desire_positions.length > 0 && detail.desire_positions[0].level2_txt} | |||||
| </Space></> | |||||
| } | |||||
| </Space> | </Space> | ||||
| </Flex> | </Flex> | ||||
| </> | </> | ||||
| <h3>简历是否隐藏</h3> | <h3>简历是否隐藏</h3> | ||||
| <Switch checkedChildren="开启" unCheckedChildren="关闭" onChange={async (checked: boolean) => { | <Switch checkedChildren="开启" unCheckedChildren="关闭" onChange={async (checked: boolean) => { | ||||
| if (checked) { | if (checked) { | ||||
| let res = await PostJobapplicantUpdate({ id: detail.id, customer_id: Number(localStorage.getItem('customerid')), hide_resume: 1 }) | |||||
| let res = await PostJobapplicantUpdate({ id: detail.id, customer_id: Number(localStorage.getItem('customerid')), hide_resume: 1 }) | |||||
| GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | ||||
| setDetail(res.data) | setDetail(res.data) | ||||
| }) | }) | ||||
| } else { | } else { | ||||
| let res = await PostJobapplicantUpdate({ id: detail.id, customer_id: Number(localStorage.getItem('customerid')), hide_resume: 2}) | |||||
| let res = await PostJobapplicantUpdate({ id: detail.id, customer_id: Number(localStorage.getItem('customerid')), hide_resume: 2 }) | |||||
| GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | ||||
| setDetail(res.data) | setDetail(res.data) | ||||
| }) | }) | ||||
| <h3>简历在家政可见</h3> | <h3>简历在家政可见</h3> | ||||
| <Switch checkedChildren="开启" unCheckedChildren="关闭" onChange={async (checked: boolean) => { | <Switch checkedChildren="开启" unCheckedChildren="关闭" onChange={async (checked: boolean) => { | ||||
| if (checked) { | if (checked) { | ||||
| let res = await PostJobapplicantUpdate({ id: detail.id, customer_id: Number(localStorage.getItem('customerid')), house_keeping_status: 1 }) | |||||
| let res = await PostJobapplicantUpdate({ id: detail.id, customer_id: Number(localStorage.getItem('customerid')), house_keeping_status: 1 }) | |||||
| GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | ||||
| setDetail(res.data) | setDetail(res.data) | ||||
| }) | }) | ||||
| </Flex> | </Flex> | ||||
| <Flex justify='space-between' align="center"> | <Flex justify='space-between' align="center"> | ||||
| <h3>接收面试邀请通知</h3> | <h3>接收面试邀请通知</h3> | ||||
| <Switch checkedChildren="开启" unCheckedChildren="关闭" onChange={async (checked: boolean) => { | |||||
| <Switch checkedChildren="开启" unCheckedChildren="关闭" onChange={async (checked: boolean) => { | |||||
| if (checked) { | if (checked) { | ||||
| let res = await PostJobapplicantUpdate({ id: detail.id, customer_id: Number(localStorage.getItem('customerid')), remind_interview: 1 }) | |||||
| let res = await PostJobapplicantUpdate({ id: detail.id, customer_id: Number(localStorage.getItem('customerid')), remind_interview: 1 }) | |||||
| GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | GetJobseekerDetail({ customer_id: localStorage.getItem('customerid') }).then((res: any) => { | ||||
| setDetail(res.data) | setDetail(res.data) | ||||
| }) | }) | ||||
| ); | ); | ||||
| }; | }; | ||||
| export default ManegeJobseekerHome; | |||||
| export default connect(({ dictModel }: any) => ({ | |||||
| dictModel | |||||
| }))(ManegeJobseekerHome); |
| const HomePage: React.FC = () => { | const HomePage: React.FC = () => { | ||||
| const [advertscheduleList, setAdvertscheduleList] = useState<object[]>([]) | const [advertscheduleList, setAdvertscheduleList] = useState<object[]>([]) | ||||
| const [keyModel, setKeyModel] = useState<object[]>([ | const [keyModel, setKeyModel] = useState<object[]>([ | ||||
| { title1: '企业', title2: '服务', content: '提供包括政策咨询、资金对接、技术转移和市场拓展在内的全方位企业服务。', icon: <> <HomeOutlined style={{ fontSize: 48, color: '#ffffff' }} /> </> }, | |||||
| { title: '产业', title2: '孵化', content: '重点支持电子信息、人工智能、新能源等高新技术产业的发展,推动产业升级。', icon: <> <SyncOutlined style={{ fontSize: 48, color: '#ffffff' }} /> </> }, | |||||
| { title: '技术', title2: '支持', content: '为企业提供研发支持和技术解决方案,帮助企业解决技术难题,实现快速发展。', icon: <> <ReadOutlined style={{ fontSize: 48, color: '#ffffff' }} /> </> }, | |||||
| { title: '产学研', title2: '合作', content: '构建开放共享的创新平台,促进产学研之间的深度合作,加速科技成果的转化。', icon: <> <TeamOutlined style={{ fontSize: 48, color: '#ffffff' }} /> </> } | |||||
| { title1: '企业', title2: '服务', content: '提供包括政策咨询、资金对接、技术转移和市场拓展在内的全方位企业服务。', icon: <> <HomeOutlined style={{ fontSize: 36, color: '#ffffff' }} /> </> }, | |||||
| { title: '产业', title2: '孵化', content: '重点支持电子信息、人工智能、新能源等高新技术产业的发展,推动产业升级。', icon: <> <SyncOutlined style={{ fontSize: 36, color: '#ffffff' }} /> </> }, | |||||
| { title: '技术', title2: '支持', content: '为企业提供研发支持和技术解决方案,帮助企业解决技术难题,实现快速发展。', icon: <> <ReadOutlined style={{ fontSize: 36, color: '#ffffff' }} /> </> }, | |||||
| { title: '产学研', title2: '合作', content: '构建开放共享的创新平台,促进产学研之间的深度合作,加速科技成果的转化。', icon: <> <TeamOutlined style={{ fontSize: 36, color: '#ffffff' }} /> </> } | |||||
| ]) | ]) | ||||
| useEffect(() => { | useEffect(() => { | ||||
| <div style={{ | <div style={{ | ||||
| width: '100%', | width: '100%', | ||||
| position: 'relative', | position: 'relative', | ||||
| paddingTop: '56.25%', | |||||
| paddingTop: '33.33%', | |||||
| overflow: 'hidden' | overflow: 'hidden' | ||||
| }}> | }}> | ||||
| <video src={`${Imageprefix}park/661_1740982607.mp4`} controls style={{ | <video src={`${Imageprefix}park/661_1740982607.mp4`} controls style={{ | ||||
| left: 0, | left: 0, | ||||
| width: '100%', | width: '100%', | ||||
| height: '100%', | height: '100%', | ||||
| objectFit: 'cover', | |||||
| overflowClipMargin: 'content-box', | |||||
| overflow: 'clip' | |||||
| }} ></video> | }} ></video> | ||||
| </div> | </div> | ||||
| <div style={{ | <div style={{ | ||||
| width: '100%', | width: '100%', | ||||
| position: 'relative', | position: 'relative', | ||||
| paddingTop: '56.25%', /* 16:9 的比例 */ | |||||
| paddingTop: '33.33%', | |||||
| overflow: 'hidden' | overflow: 'hidden' | ||||
| }}> | }}> | ||||
| <Link to={{ pathname: item.target_url }} target='_blank'> | <Link to={{ pathname: item.target_url }} target='_blank'> |
| import { ConfigProvider, Button, Flex, Input, Space, Image, Row, Col, Carousel, Tag, Card, Avatar, Typography, Anchor, List, Result, Divider, Descriptions } from 'antd'; | import { ConfigProvider, Button, Flex, Input, Space, Image, Row, Col, Carousel, Tag, Card, Avatar, Typography, Anchor, List, Result, Divider, Descriptions } from 'antd'; | ||||
| import { PhoneOutlined, MailOutlined, EnvironmentOutlined, ArrowRightOutlined, FireOutlined, StarOutlined, PayCircleOutlined } from '@ant-design/icons'; | import { PhoneOutlined, MailOutlined, EnvironmentOutlined, ArrowRightOutlined, FireOutlined, StarOutlined, PayCircleOutlined } from '@ant-design/icons'; | ||||
| import { useSearchParams, connect, history, Link } from 'umi'; | import { useSearchParams, connect, history, Link } from 'umi'; | ||||
| import { Imageprefix } from '@/constants/index' | |||||
| import { GetCompanyInfo } from '@/services/apis/company'; | import { GetCompanyInfo } from '@/services/apis/company'; | ||||
| <Flex justify='space-between' align='center' style={{ padding: 20, borderRadius: 8, background: '#ffffff' }}> | <Flex justify='space-between' align='center' style={{ padding: 20, borderRadius: 8, background: '#ffffff' }}> | ||||
| <Space direction='vertical' size={30}> | <Space direction='vertical' size={30}> | ||||
| <Space size={20}> | <Space size={20}> | ||||
| <Image src={detail.photo ? detail.photo : '/images/onlylogo.jpg'} width={48} height={48}></Image> | |||||
| <Image src={detail.photo ? `${Imageprefix}${detail.photo}` : '/images/onlylogo.jpg'} width={48} height={48}></Image> | |||||
| <Space direction='vertical'> | <Space direction='vertical'> | ||||
| <Typography.Title level={4}>{detail.full_name}</Typography.Title> | <Typography.Title level={4}>{detail.full_name}</Typography.Title> | ||||
| <div> 成立日期:{detail.situation.establishment_date}</div> | <div> 成立日期:{detail.situation.establishment_date}</div> | ||||
| <Row gutter={[10, 10]} style={{ width: '100%' }}> | <Row gutter={[10, 10]} style={{ width: '100%' }}> | ||||
| <Col span={24}> | <Col span={24}> | ||||
| { | { | ||||
| list.length > 0 && list.map((item: any, index: number) => ( | |||||
| list && list.length > 0 && list.map((item: any, index: number) => ( | |||||
| <> | <> | ||||
| <CommonJob item={item}></CommonJob> | <CommonJob item={item}></CommonJob> | ||||
| </> | </> |
| import { useState, useEffect, useRef } from 'react'; | import { useState, useEffect, useRef } from 'react'; | ||||
| import { ProList, PageContainer } from '@ant-design/pro-components'; | import { ProList, PageContainer } from '@ant-design/pro-components'; | ||||
| import { ConfigProvider, Button, Flex, Input, Space, Image, Select, Row, Col, Carousel, Card, List, Tag, Cascader, Tabs, Typography, Anchor, Modal } from 'antd'; | |||||
| import { ConfigProvider, Button, Flex, Input, Space, Image, Select, Row, Col, Carousel, Card, List, Tag, Typography, Tabs, Segmented, Anchor, Modal } from 'antd'; | |||||
| import { SearchOutlined, EllipsisOutlined, ArrowRightOutlined, EnvironmentOutlined, CaretUpOutlined, RightOutlined } from '@ant-design/icons'; | import { SearchOutlined, EllipsisOutlined, ArrowRightOutlined, EnvironmentOutlined, CaretUpOutlined, RightOutlined } from '@ant-design/icons'; | ||||
| import { useModel, connect, history, Link } from 'umi'; | import { useModel, connect, history, Link } from 'umi'; | ||||
| const [positionList, setPositionList] = useState<any[]>([]); | const [positionList, setPositionList] = useState<any[]>([]); | ||||
| const [loginHeight, setLoginHeight] = useState<number>(432) // 获取登录的高度 | const [loginHeight, setLoginHeight] = useState<number>(432) // 获取登录的高度 | ||||
| const [keywordName, setKeywordName] = useState<string>(''); | const [keywordName, setKeywordName] = useState<string>(''); | ||||
| const [positionType, setPositionType] = useState<string>('热门职位') | |||||
| // 切换登录 | // 切换登录 | ||||
| const [type, setType] = useState<string>('jobseeker') | const [type, setType] = useState<string>('jobseeker') | ||||
| components: { | components: { | ||||
| Button: { | Button: { | ||||
| colorText: '#19be6e' | colorText: '#19be6e' | ||||
| }, | |||||
| Segmented: { | |||||
| trackBg: '#f0f0f0', | |||||
| itemSelectedColor: '#19be6e' | |||||
| } | } | ||||
| } | } | ||||
| }} | }} | ||||
| {/* 固定 */} | {/* 固定 */} | ||||
| <Anchor | <Anchor | ||||
| offsetTop={87} | offsetTop={87} | ||||
| style={{ position: 'fixed', bottom: 87, background: '#f5f5f5', paddingRight: 20, borderRadius: 10 }} | |||||
| style={{ position: 'fixed', bottom: 87, background: '#f5f5f5', paddingRight: 20, borderRadius: 10 , zIndex: 99 }} | |||||
| items={[ | items={[ | ||||
| { title: '热门职位', key: 1, href: '#newjob' }, | |||||
| { title: '急招职位', key: 2, href: '#urgentjob' }, | |||||
| // { title: '热门企业', key: 3, href: '#company' }, | |||||
| { title: '高新职位', key: 4, href: '#highjob' }, | |||||
| { title: '知名企业', key: 5, href: '#fomaus' }, | |||||
| { title: '校园招聘', key: 6, href: '#campusjob' }, | |||||
| { title: '见习基地', key: 7, href: '#probation' }, | |||||
| { title: '关于我们', key: 8, href: '#about' }, | |||||
| { title: (<><h3>热门职位</h3></>), key: 1, href: '#newjob' }, | |||||
| { title:(<><h3>热门企业</h3></>), key: 2, href: '#company' }, | |||||
| { title:(<><h3>招聘会</h3></>), key: 3, href: '#fair' }, | |||||
| { title:(<><h3>知名企业</h3></>), key: 4, href: '#fomaus' }, | |||||
| { title:(<><h3>校园招聘</h3></>), key: 5, href: '#campusjob' }, | |||||
| { title:(<><h3>见习基地</h3></>), key: 6, href: '#probation' }, | |||||
| { title:(<><h3>关于我们</h3></>), key: 7, href: '#about' }, | |||||
| ]} | ]} | ||||
| /> | /> | ||||
| <PageContainer header={{ title: ' ' }} style={{ background: '#ffffff' }} | <PageContainer header={{ title: ' ' }} style={{ background: '#ffffff' }} | ||||
| > | > | ||||
| <Row gutter={[16, 16]}> | <Row gutter={[16, 16]}> | ||||
| <Col span={18}> | |||||
| <Col span={localStorage.getItem('token') ? 24 : 18}> | |||||
| <Space direction='vertical' size={20} style={{ width: '100%' }}> | <Space direction='vertical' size={20} style={{ width: '100%' }}> | ||||
| <Space.Compact style={{ width: '100%' }}> | |||||
| <Input | |||||
| size='large' | |||||
| prefix={<SearchOutlined style={{ color: '#19be6e' }} />} | |||||
| placeholder="请输入关键词" | |||||
| allowClear | |||||
| value={keywordName} | |||||
| onChange={(e) => { | |||||
| setKeywordName(e.target.value) | |||||
| }} | |||||
| /> | |||||
| <Link to={{ pathname: `/talent/search?keyword=${keywordName}` }}> | |||||
| <Button size='large' type='primary' style={{ width: 200 }}>搜索</Button> | |||||
| </Link> | |||||
| </Space.Compact> | |||||
| <Flex justify='center' align='center'> | |||||
| <Space.Compact style={{ width: '100%' }}> | |||||
| <Input | |||||
| size='large' | |||||
| prefix={<SearchOutlined style={{ color: '#19be6e' }} />} | |||||
| placeholder="请输入关键词" | |||||
| allowClear | |||||
| value={keywordName} | |||||
| onChange={(e) => { | |||||
| setKeywordName(e.target.value) | |||||
| }} | |||||
| /> | |||||
| <Link to={{ pathname: `/talent/search?keyword=${keywordName}` }}> | |||||
| <Button size='large' type='primary' style={{ width: 200 }}>搜索</Button> | |||||
| </Link> | |||||
| </Space.Compact> | |||||
| </Flex> | |||||
| <Flex justify='center' align='center'> | <Flex justify='center' align='center'> | ||||
| <Space size={30} style={{ width: '70%' }}> | <Space size={30} style={{ width: '70%' }}> | ||||
| <Link to={{ pathname: `/talent/search?keyword=客服` }} style={{ color: 'gray' }}> | <Link to={{ pathname: `/talent/search?keyword=客服` }} style={{ color: 'gray' }}> | ||||
| </Flex> | </Flex> | ||||
| </Space> | </Space> | ||||
| </Col> | </Col> | ||||
| <Col span={2}> | |||||
| <Button size='large' type='primary' style={{ width: '100%' }} onClick={() => { | |||||
| setType('jobseeker') | |||||
| setOpenPreview(true) | |||||
| }}>登录</Button> | |||||
| </Col> | |||||
| <Col span={4}> | |||||
| <Button size='large' type='primary' style={{ width: '100%' }} onClick={() => { | |||||
| setType('company') | |||||
| setOpenPreview(true) | |||||
| }}>发布一个职位</Button> | |||||
| </Col> | |||||
| { | |||||
| !localStorage.getItem('token') && <> | |||||
| <Col span={2}> | |||||
| <Button size='large' type='primary' style={{ width: '100%' }} onClick={() => { | |||||
| setType('jobseeker') | |||||
| setOpenPreview(true) | |||||
| }}>登录</Button> | |||||
| </Col> | |||||
| <Col span={4}> | |||||
| <Button size='large' type='primary' style={{ width: '100%' }} onClick={() => { | |||||
| setType('company') | |||||
| setOpenPreview(true) | |||||
| }}>发布一个职位</Button> | |||||
| </Col> | |||||
| </> | |||||
| } | |||||
| </Row> | </Row> | ||||
| </PageContainer> | </PageContainer> | ||||
| </Flex> | </Flex> | ||||
| </div> */} | </div> */} | ||||
| </Flex> | </Flex> | ||||
| <Space direction='vertical' size={30} style={{ minHeight: 800}}> | |||||
| <Flex justify='center' align='center' id="newjob"> | |||||
| <HomeNewJob></HomeNewJob> | |||||
| <Space direction='vertical' size={30} style={{ minHeight: 800 }}> | |||||
| <Flex justify='center' align='center' style={{ padding: '40px 0', width: '100%' }} id='newjob'> | |||||
| <Flex justify='space-between' align='center' style={{ width: '1152px' }}> | |||||
| <Space direction='vertical' size='small' style={{ width: '100%' }} > | |||||
| <Segmented | |||||
| size='large' | |||||
| block | |||||
| value={positionType} | |||||
| options={['热门职位', '急招职位', '高薪职位']} | |||||
| onChange={(value) => { | |||||
| setPositionType(value) | |||||
| }} | |||||
| /> | |||||
| <div style={{ paddingTop: 20 }}> | |||||
| {positionType == '热门职位' && <><HomeNewJob></HomeNewJob></>} | |||||
| {positionType == '急招职位' && <><HomeUrgentJob></HomeUrgentJob></>} | |||||
| {positionType == '高薪职位' && <><HomeHighJob></HomeHighJob></>} | |||||
| </div> | |||||
| </Space> | |||||
| </Flex> | |||||
| </Flex> | </Flex> | ||||
| <Flex justify='center' align='center' id='urgentjob'> | |||||
| <HomeUrgentJob></HomeUrgentJob> | |||||
| <Flex justify='center' align='center' id='company'> | |||||
| <HomeCompany></HomeCompany> | |||||
| </Flex> | </Flex> | ||||
| <Flex justify='center' align='center' id='highjob'> | |||||
| <Flex justify='center' align='center' id='fair'> | |||||
| <TalentHomeFair></TalentHomeFair> | <TalentHomeFair></TalentHomeFair> | ||||
| </Flex> | </Flex> | ||||
| </Space> | </Space> | ||||
| {/* <Flex justify='center' align='center' style={{ background: '#364d79', marginTop: 40, padding: '40px 0', width: '100%' }}> | |||||
| <Flex justify='space-between' align='center' style={{ width: '1152px' }}> | |||||
| <Space direction='vertical' size='small' style={{ width: '100%' }} id='fomaus'> | |||||
| <Flex justify='center' align='center'> | |||||
| <Typography.Title level={1} style={{ color: '#ffffff' }}>热门企业</Typography.Title> | |||||
| </Flex> | |||||
| <HomeCompany></HomeCompany> | |||||
| </Space> | |||||
| </Flex> | |||||
| </Flex> */} | |||||
| {/* <Flex justify='center' align='center' style={{ background: '#f5f5f5', padding: '40px 0', width: '100%' }}> | |||||
| <Flex justify='space-between' align='center' style={{ width: '1152px' }}> | |||||
| <Space direction='vertical' size='small' style={{ width: '100%' }} id='fomaus'> | |||||
| <Flex justify='space-between' align='center'> | |||||
| <Typography.Title level={2}>知名企业</Typography.Title> | |||||
| <EllipsisOutlined style={{ color: '#19be6e', fontSize: '24px' }} /> | |||||
| </Flex> | |||||
| <HomeFamous></HomeFamous> | |||||
| </Space> | |||||
| </Flex> | |||||
| </Flex> */} | |||||
| <PageContainer | <PageContainer | ||||
| header={{ title: ' ' }} | header={{ title: ' ' }} | ||||
| > | > | ||||
| {/* <Space direction='vertical' size={60} style={{ marginTop: 40 }}> | {/* <Space direction='vertical' size={60} style={{ marginTop: 40 }}> | ||||
| <div style={{ position: 'relative', width: '100%', height: 480, borderRadius: 8, background: '#00574B', zIndex: '99', }}> | <div style={{ position: 'relative', width: '100%', height: 480, borderRadius: 8, background: '#00574B', zIndex: '99', }}> | ||||
| <div style={{ position: 'absolute', top: 0, right: 0, bottom: 0, left: 0, clipPath: 'circle(50% at right bottom)', backgroundImage: `url(${require('../../../../public/images/kcy.png')})`, backgroundSize: '100% 480px' }}> | <div style={{ position: 'absolute', top: 0, right: 0, bottom: 0, left: 0, clipPath: 'circle(50% at right bottom)', backgroundImage: `url(${require('../../../../public/images/kcy.png')})`, backgroundSize: '100% 480px' }}> |
| const ancestors = findAncestors(data, nativePlaceTxt); | const ancestors = findAncestors(data, nativePlaceTxt); | ||||
| return ancestors; | return ancestors; | ||||
| }; | |||||
| }; | |||||
| export function findItemById(arr: any[], id: number): any | false { | |||||
| for (const item of arr) { | |||||
| if (item.id === id) { | |||||
| return true; | |||||
| } | |||||
| if (item.children && Array.isArray(item.children)) { | |||||
| const result = findItemById(item.children, id); | |||||
| if (result) { | |||||
| return true; | |||||
| } | |||||
| } | |||||
| } | |||||
| return false; | |||||
| } |