feat
parent
f70bd6afc3
commit
d0396a0b01
|
|
@ -54,16 +54,18 @@ function PersonnelChangePage(props) {
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
const handleLogSearch = () => {
|
const handleLogSearch = () => {
|
||||||
if (selectedStaff?.staffId) {
|
if (selectedStaff?.id) {
|
||||||
props.staffChangeLogList({ eqStaffId: selectedStaff.staffId });
|
props.staffChangeLogList({ personnelId: selectedStaff.id });
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (viewMode === "log" && selectedStaff?.staffId) {
|
|
||||||
|
if (viewMode === "log" && selectedStaff?.id) {
|
||||||
|
|
||||||
handleLogSearch();
|
handleLogSearch();
|
||||||
}
|
}
|
||||||
}, [viewMode, selectedStaff?.staffId]);
|
}, [viewMode, selectedStaff?.id]);
|
||||||
|
|
||||||
const onDelete = (record) => {
|
const onDelete = (record) => {
|
||||||
Modal.confirm({
|
Modal.confirm({
|
||||||
|
|
@ -210,7 +212,7 @@ function PersonnelChangePage(props) {
|
||||||
const logColumns = [
|
const logColumns = [
|
||||||
{ title: "变更事项", dataIndex: "changeItem", width: 200 },
|
{ title: "变更事项", dataIndex: "changeItem", width: 200 },
|
||||||
{ title: "变更时间", dataIndex: "changeTime", width: 160 },
|
{ title: "变更时间", dataIndex: "changeTime", width: 160 },
|
||||||
{ title: "操作人", dataIndex: "createBy", width: 100 },
|
{ title: "操作人", dataIndex: "operatorName", width: 100 },
|
||||||
];
|
];
|
||||||
|
|
||||||
if (viewMode === "log") {
|
if (viewMode === "log") {
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@ function FiledManageListPage(props) {
|
||||||
...router.query,
|
...router.query,
|
||||||
current: pagination?.current || router.query.current || 1,
|
current: pagination?.current || router.query.current || 1,
|
||||||
size: pagination?.size || router.query.size || 10,
|
size: pagination?.size || router.query.size || 10,
|
||||||
applyTypeCode: 2,
|
applyTypeCode: 3,
|
||||||
};
|
};
|
||||||
const res = await props.qualFilingPage(params);
|
const res = await props.qualFilingPage(params);
|
||||||
if (res?.success !== false) {
|
if (res?.success !== false) {
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ export default function PersonnelStep({
|
||||||
const [selectOpen, setSelectOpen] = useState(false);
|
const [selectOpen, setSelectOpen] = useState(false);
|
||||||
const [viewId, setViewId] = useState("");
|
const [viewId, setViewId] = useState("");
|
||||||
|
|
||||||
const existingIds = personnelList.map((item) => String(item.sourcePersonnelId || ""));
|
const existingIds = personnelList.map((item) => String(item.id || ""));
|
||||||
console.log(personnelList);
|
console.log(personnelList);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
||||||
|
|
@ -47,19 +47,23 @@ export function verifyFilingPrerequisites(detail = {}) {
|
||||||
const personnel = detail.personnelList || [];
|
const personnel = detail.personnelList || [];
|
||||||
const total = personnel.length;
|
const total = personnel.length;
|
||||||
const regEngineerCount = personnel.filter(isRegisterEngineer).length;
|
const regEngineerCount = personnel.filter(isRegisterEngineer).length;
|
||||||
const midTitleCount = personnel.filter((p) => includesMidTitle(p.titleName)).length;
|
const midTitleCount = personnel.filter((p) =>
|
||||||
const seniorTitleCount = personnel.filter((p) => includesSeniorTitle(p.titleName)).length;
|
includesMidTitle(p.titleName),
|
||||||
|
).length;
|
||||||
|
const seniorTitleCount = personnel.filter((p) =>
|
||||||
|
includesSeniorTitle(p.titleName),
|
||||||
|
).length;
|
||||||
|
|
||||||
items.push({
|
items.push({
|
||||||
key: "personnelStructure",
|
key: "personnelStructure",
|
||||||
label: "人员数量与结构",
|
label: "人员数量与结构",
|
||||||
desc: "专职技术人员≥25人,中级注安师≥30%,中级职称≥50%,高级职称≥30%",
|
desc: "专职技术人员≥25人,中级注安师≥30%,中级职称≥50%,高级职称≥30%",
|
||||||
passed: SKIP_PERSONNEL_VERIFY || (
|
passed:
|
||||||
total >= 25
|
SKIP_PERSONNEL_VERIFY ||
|
||||||
&& ratio(regEngineerCount, total) >= 0.3
|
(total >= 25 &&
|
||||||
&& ratio(midTitleCount, total) >= 0.5
|
ratio(regEngineerCount, total) >= 0.3 &&
|
||||||
&& ratio(seniorTitleCount, total) >= 0.3
|
ratio(midTitleCount, total) >= 0.5 &&
|
||||||
),
|
ratio(seniorTitleCount, total) >= 0.3),
|
||||||
});
|
});
|
||||||
|
|
||||||
const withExperience = personnel.filter((p) => {
|
const withExperience = personnel.filter((p) => {
|
||||||
|
|
@ -71,12 +75,18 @@ export function verifyFilingPrerequisites(detail = {}) {
|
||||||
key: "personnelExp",
|
key: "personnelExp",
|
||||||
label: "人员资历",
|
label: "人员资历",
|
||||||
desc: "专职技术人员在本行业领域工作二年以上",
|
desc: "专职技术人员在本行业领域工作二年以上",
|
||||||
passed: SKIP_PERSONNEL_VERIFY || (total >= 25 && ratio(withExperience, total) >= 0.8),
|
passed:
|
||||||
|
SKIP_PERSONNEL_VERIFY ||
|
||||||
|
(total >= 25 && ratio(withExperience, total) >= 0.8),
|
||||||
});
|
});
|
||||||
|
|
||||||
const keyOk = KEY_POSITIONS.every((pos) => personnel.some(
|
const keyOk = KEY_POSITIONS.every((pos) =>
|
||||||
(p) => String(p.positionName || "").includes(pos) && includesSeniorTitle(p.titleName),
|
personnel.some(
|
||||||
));
|
(p) =>
|
||||||
|
String(p.positionName || "").includes(pos) &&
|
||||||
|
includesSeniorTitle(p.titleName),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
|
||||||
items.push({
|
items.push({
|
||||||
key: "keyPosition",
|
key: "keyPosition",
|
||||||
|
|
@ -84,16 +94,17 @@ export function verifyFilingPrerequisites(detail = {}) {
|
||||||
desc: "负责人、技术负责人、质量负责人具有高级职称,工作八年以上",
|
desc: "负责人、技术负责人、质量负责人具有高级职称,工作八年以上",
|
||||||
passed: SKIP_PERSONNEL_VERIFY || keyOk,
|
passed: SKIP_PERSONNEL_VERIFY || keyOk,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
// const mgmtUploaded=detail.materials.every((m) => m.attachmentUrl);
|
|
||||||
|
|
||||||
// items.push({
|
const mgmtUploaded = detail.materials.every((m) => m.attachmentUrl);
|
||||||
// key: "mgmtSystem",
|
|
||||||
// label: "管理体系",
|
if (SKIP_PERSONNEL_VERIFY) {
|
||||||
// desc: mgmtUploaded? "管理体系文件已上传" : "尚未上传管理体系文件",
|
items.push({
|
||||||
// passed: mgmtUploaded,
|
key: "mgmtSystem",
|
||||||
// });
|
label: "管理体系",
|
||||||
|
desc: mgmtUploaded ? "管理体系文件已上传" : "尚未上传管理体系文件",
|
||||||
|
passed: mgmtUploaded,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
passed: items.every((item) => item.passed),
|
passed: items.every((item) => item.passed),
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue