flat:合并
This commit is contained in:
303
src/pages/Application/ModelManagement/index.tsx
Normal file
303
src/pages/Application/ModelManagement/index.tsx
Normal file
@@ -0,0 +1,303 @@
|
||||
import React, { Fragment } from 'react';
|
||||
import { Collapse, InputNumber, Select } from 'antd';
|
||||
import style from './modelStyle.less';
|
||||
|
||||
export default function ModelManagement() {
|
||||
const text = `
|
||||
A dog is a type of domesticated animal.
|
||||
Known for its loyalty and faithfulness,
|
||||
it can be found as a welcome guest in many households across the world.
|
||||
`;
|
||||
|
||||
return (
|
||||
<Fragment>
|
||||
<Collapse defaultActiveKey={['1']}>
|
||||
<Collapse.Panel header="人岗精准匹配模型" key="1">
|
||||
<div className={style.cards}>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>年龄匹配范围</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
controls={false}
|
||||
style={{ width: 150 }}
|
||||
addonAfter="岁"
|
||||
min={0}
|
||||
max={100}
|
||||
maxLength={3}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>工作经验范围</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
controls={false}
|
||||
style={{ width: 150 }}
|
||||
addonAfter="年"
|
||||
min={0}
|
||||
max={100}
|
||||
maxLength={3}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</Collapse.Panel>
|
||||
<Collapse.Panel header="人岗匹配度计算模型" key="2">
|
||||
<div className={style.cards}>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>学历权重</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
min={0}
|
||||
max={1}
|
||||
style={{ width: 150 }}
|
||||
controls={false}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>期望薪资权重</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
min={0}
|
||||
max={1}
|
||||
controls={false}
|
||||
style={{ width: 150 }}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>工作经验权重</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
min={0}
|
||||
style={{ width: 150 }}
|
||||
max={1}
|
||||
controls={false}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>工作地区权重</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
min={0}
|
||||
max={1}
|
||||
controls={false}
|
||||
style={{ width: 150 }}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</Collapse.Panel>
|
||||
<Collapse.Panel header="基于求职者行为推荐模型" key="3">
|
||||
<div className={style.cards}>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>浏览记录</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
min={0}
|
||||
max={1}
|
||||
controls={false}
|
||||
style={{ width: 150 }}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>申请记录</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
min={0}
|
||||
style={{ width: 150 }}
|
||||
max={1}
|
||||
controls={false}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>收藏记录</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
min={0}
|
||||
style={{ width: 150 }}
|
||||
max={1}
|
||||
controls={false}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</Collapse.Panel>
|
||||
<Collapse.Panel header="竞争力计算模型" key="4">
|
||||
<div className={style.cards}>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>学历权重</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
style={{ width: 150 }}
|
||||
min={0}
|
||||
max={1}
|
||||
controls={false}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>期望薪资权重</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
style={{ width: 150 }}
|
||||
stringMode
|
||||
min={0}
|
||||
max={1}
|
||||
controls={false}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>工作经验权重</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
stringMode
|
||||
style={{ width: 150 }}
|
||||
min={0}
|
||||
max={1}
|
||||
controls={false}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>工作地区权重</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
style={{ width: 150 }}
|
||||
stringMode
|
||||
min={0}
|
||||
max={1}
|
||||
controls={false}
|
||||
precision={1}
|
||||
step="0.1"
|
||||
placeholder="例如:0.7"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>相似度计算方式</div>
|
||||
<div className={style.input}>
|
||||
<Select
|
||||
defaultValue="lucy"
|
||||
style={{ width: 150 }}
|
||||
options={[
|
||||
{ value: 'jack', label: '余弦相似度' },
|
||||
{ value: 'lucy', label: '欧式距离' },
|
||||
{ value: 'Yiminghe', label: 'embedding' },
|
||||
]}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</Collapse.Panel>
|
||||
<Collapse.Panel header="位置匹配模型" key="5">
|
||||
<div className={style.cards}>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>坐标系与投影</div>
|
||||
<div className={style.input}>
|
||||
<Select
|
||||
defaultValue="lucy"
|
||||
style={{ width: 150 }}
|
||||
options={[
|
||||
{ value: 'jack', label: 'wgs84' },
|
||||
{ value: 'lucy', label: 'gcj02' },
|
||||
]}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>索引粒度</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
style={{ width: 150 }}
|
||||
stringMode
|
||||
min={1}
|
||||
max={12}
|
||||
controls={false}
|
||||
precision={0}
|
||||
step="1"
|
||||
placeholder="1-12"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>地铁口附近</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
style={{ width: 150 }}
|
||||
stringMode
|
||||
min={0}
|
||||
max={10}
|
||||
controls={false}
|
||||
precision={0}
|
||||
step="0"
|
||||
placeholder="10公里附近"
|
||||
addonAfter="公里"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={style.card}>
|
||||
<div className={style.label}>商圈附近</div>
|
||||
<div className={style.input}>
|
||||
<InputNumber
|
||||
style={{ width: 150 }}
|
||||
stringMode
|
||||
min={0}
|
||||
max={10}
|
||||
controls={false}
|
||||
precision={0}
|
||||
step="0"
|
||||
placeholder="10公里附近"
|
||||
addonAfter="公里"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</Collapse.Panel>
|
||||
</Collapse>
|
||||
</Fragment>
|
||||
);
|
||||
}
|
||||
19
src/pages/Application/ModelManagement/modelStyle.less
Normal file
19
src/pages/Application/ModelManagement/modelStyle.less
Normal file
@@ -0,0 +1,19 @@
|
||||
.cards {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
grid-row-gap: 30px;
|
||||
|
||||
.card {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-right: 80px;
|
||||
|
||||
.label {
|
||||
margin-right: 10px;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.input {
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,47 +1,52 @@
|
||||
import { request } from '@umijs/max';
|
||||
// 行业
|
||||
export async function getIndustryTrend(params?: API.Analysis.IndustryParams) {
|
||||
return request<API.Analysis.IndustryResult>('/api/cms/statics/industry', {
|
||||
method: 'GET',
|
||||
params
|
||||
});
|
||||
}
|
||||
// 区域热力图
|
||||
export async function getIndustryAreaTrend(params: any) {
|
||||
try {
|
||||
const response = await request('/api/cms/statics/industryArea', {
|
||||
method: 'GET',
|
||||
params,
|
||||
headers: {
|
||||
'Content-Type': 'application/json'
|
||||
}
|
||||
});
|
||||
|
||||
console.log('接口原始响应:', response); // 调试日志
|
||||
return response; // 兼容不同后端响应格式
|
||||
} catch (error) {
|
||||
console.error('接口请求异常:', error);
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
// 薪资
|
||||
export async function getSalaryTrend(params?: API.Analysis.IndustryParams) {
|
||||
return request<API.Analysis.IndustryResult>('/api/cms/statics/salary', {
|
||||
method: 'GET',
|
||||
params
|
||||
});
|
||||
}
|
||||
// 工作年限
|
||||
export async function getWorkYearTrend(params?: API.Analysis.IndustryParams) {
|
||||
return request<API.Analysis.IndustryResult>('/api/cms/statics/workYear', {
|
||||
method: 'GET',
|
||||
params
|
||||
});
|
||||
}
|
||||
// 学历趋势
|
||||
export async function getEducationTrend(params?: API.Analysis.IndustryParams) {
|
||||
return request<API.Analysis.IndustryResult>('/api/cms/statics/education', {
|
||||
method: 'GET',
|
||||
params
|
||||
});
|
||||
}
|
||||
import { request } from '@umijs/max';
|
||||
|
||||
// 行业
|
||||
export async function getIndustryTrend(params?: API.Analysis.IndustryParams) {
|
||||
return request<API.Analysis.IndustryResult>('/api/cms/statics/industry', {
|
||||
method: 'GET',
|
||||
params,
|
||||
});
|
||||
}
|
||||
|
||||
// 区域热力图
|
||||
export async function getIndustryAreaTrend(params: any) {
|
||||
try {
|
||||
const response = await request('/api/cms/statics/industryArea', {
|
||||
method: 'GET',
|
||||
params,
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
});
|
||||
|
||||
console.log('接口原始响应:', response); // 调试日志
|
||||
return response; // 兼容不同后端响应格式
|
||||
} catch (error) {
|
||||
console.error('接口请求异常:', error);
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
|
||||
// 薪资
|
||||
export async function getSalaryTrend(params?: API.Analysis.IndustryParams) {
|
||||
return request<API.Analysis.IndustryResult>('/api/cms/statics/salary', {
|
||||
method: 'GET',
|
||||
params,
|
||||
});
|
||||
}
|
||||
|
||||
// 工作年限
|
||||
export async function getWorkYearTrend(params?: API.Analysis.IndustryParams) {
|
||||
return request<API.Analysis.IndustryResult>('/api/cms/statics/workYear', {
|
||||
method: 'GET',
|
||||
params,
|
||||
});
|
||||
}
|
||||
|
||||
// 学历趋势
|
||||
export async function getEducationTrend(params?: API.Analysis.IndustryParams) {
|
||||
return request<API.Analysis.IndustryResult>('/api/cms/statics/education', {
|
||||
method: 'GET',
|
||||
params,
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user