diff --git a/jjb.config.js b/jjb.config.js index 8de27c5..4d10538 100644 --- a/jjb.config.js +++ b/jjb.config.js @@ -10,10 +10,14 @@ module.exports = { javaGitBranch: "dev", // 本地联调 safetyEval-service(context-path: /safetyEval,默认端口 8095) // 可通过环境变量覆盖: SAFETY_EVAL_API_HOST=http://192.168.x.x:8095 - // API_HOST: "https://gbs-gateway.qhdsafety.com", + API_HOST: "https://gbs-gateway.qhdsafety.com", // API_HOST: "http://192.168.0.134", +<<<<<<< HEAD // API_HOST: "http://192.168.0.150", //太浅 +======= + //API_HOST: "http://192.168.0.150", //太浅 +>>>>>>> origin/dev // API_HOST: "http://192.168.0.152", API_HOST: "http://192.168.0.103", //huwei }, diff --git a/src/components/StaffViewModal/index.js b/src/components/StaffViewModal/index.js index 5eb3290..3b20254 100644 --- a/src/components/StaffViewModal/index.js +++ b/src/components/StaffViewModal/index.js @@ -185,13 +185,27 @@ export default function StaffViewModal({ {info.account} {info.deptName} {info.postName} - + + {info.idCardNo} + + + {info.currentAddress} + + + {info.officeAddress} + {info.educationTypeName || "-"} + + {info.graduateSchool} + {info.educationLevelName || "-"} + + {info.basicDisciplineMajorName || "-"} + {REGISTER_ENGINEER_MAP[info.registerEngineerFlag] ?? "-"} @@ -210,19 +224,7 @@ export default function StaffViewModal({ ? "否" : "-"} - - {info.idCardNo} - - - - {info.currentAddress} - - - {info.officeAddress} - - - {info.graduateSchool} - + + + form.setFieldValue("cert_level", undefined)} - /> - + {QUALIFICATION_INDUSTRY_OPTIONS_MAP[info.businessScope] } {info.professionalCapabilityName } - {info.certName} {CERT_TYPE_MAP[info.certTypeCode] || info.certTypeCode} + {info.certName} + {CERT_LEVEL_LABEL_BY_TYPE[info.certTypeCode]?.[info.cert_level] || info.cert_level} diff --git a/src/pages/Container/EnterpriseInfo/PersonnelInfo/List/index.js b/src/pages/Container/EnterpriseInfo/PersonnelInfo/List/index.js index 9ee559b..e585489 100644 --- a/src/pages/Container/EnterpriseInfo/PersonnelInfo/List/index.js +++ b/src/pages/Container/EnterpriseInfo/PersonnelInfo/List/index.js @@ -394,7 +394,7 @@ function StaffFormModal({ }; const loadBasicDisciplineMajors = async () => { - + await queryBasicDisciplineMajor({ pageSize: 999 }); }; @@ -450,7 +450,7 @@ function StaffFormModal({ } form.setFieldsValue(setFields); - + }) .finally(() => { if (!cancelled) setDetailLoading(false); @@ -645,7 +645,66 @@ function StaffFormModal({ - + + + + + + + + + + + + + + + + + + + - - - { - form.setFieldValue( - "educationLevelName", - option?.label || undefined, - ); - }} - /> - - - - - - - - - - - - - - - - - - - @@ -925,7 +924,7 @@ function StaffImportModal({ open, onCancel, onSuccess }) { const handleDownloadTemplate = async () => { try { const res = await Get("/safetyEval/org-personnel/import/template"); - const url = res?.data ; + const url = res?.data; if (!url) { message.warning("未获取到模板下载地址"); return; @@ -961,10 +960,11 @@ function StaffImportModal({ open, onCancel, onSuccess }) { const headers = { token: sessionStorage.getItem("token") || "" }; const orgInfoId = sessionStorage.getItem("orgInfoId"); if (orgInfoId) headers.orgInfoId = String(orgInfoId); - const resp = await fetch( - `${API_HOST}/safetyEval/org-personnel/import`, - { method: "POST", headers, body: formData }, - ); + const resp = await fetch(`${API_HOST}/safetyEval/org-personnel/import`, { + method: "POST", + headers, + body: formData, + }); const json = await resp.json(); if (json && json.success !== false) { onDone(json.data, file); @@ -1004,8 +1004,7 @@ function StaffImportModal({ open, onCancel, onSuccess }) { customRequest={customRequest} disabled={uploading} beforeUpload={(file) => { - const ext = - "." + (file.name.split(".").pop() || "").toLowerCase(); + const ext = "." + (file.name.split(".").pop() || "").toLowerCase(); if (![".xlsx", ".xls"].includes(ext)) { message.error("仅支持 .xlsx / .xls 格式文件"); return Upload.LIST_IGNORE; diff --git a/src/pages/Container/QualApplication/FilingForm/components/BasicInfoStep.jsx b/src/pages/Container/QualApplication/FilingForm/components/BasicInfoStep.jsx index 8193ee7..c34529e 100644 --- a/src/pages/Container/QualApplication/FilingForm/components/BasicInfoStep.jsx +++ b/src/pages/Container/QualApplication/FilingForm/components/BasicInfoStep.jsx @@ -6,14 +6,14 @@ import { import { FILING_UNIT_TYPE_OPTIONS } from "~/enumerate/qualFilingOptions"; import AttachmentUpload from "~/components/AttachmentUpload"; -export default function BasicInfoStep({ form, disabled }) { +export default function BasicInfoStep({ form, disabled, mode }) { return (
- + - + - + - + @@ -72,6 +72,7 @@ export default function BasicInfoStep({ form, disabled }) { name="infoDisclosureUrl" label="信息公开网址" rules={[ + { required: !disabled, message: "请输入信息公开网址" }, { pattern: /^https?:\/\/[^\s]+$/, message: "请输入正确的网址,需以 http:// 或 https:// 开头", @@ -85,8 +86,8 @@ export default function BasicInfoStep({ form, disabled }) { @@ -175,19 +176,20 @@ export default function BasicInfoStep({ form, disabled }) { - + index + 1 }, - { title: "内容", dataIndex: "materialContent", width: 200, ellipsis: true }, + { title: "内容", dataIndex: "materialContent", width: 400, ellipsis: true }, { title: "上传附件", dataIndex: "attachmentDesc", width: 100 }, { title: "格式", diff --git a/src/pages/Container/QualApplication/FilingForm/index.js b/src/pages/Container/QualApplication/FilingForm/index.js index cec96ee..83d830d 100644 --- a/src/pages/Container/QualApplication/FilingForm/index.js +++ b/src/pages/Container/QualApplication/FilingForm/index.js @@ -36,7 +36,7 @@ const MODE_TITLE = { function FilingFormPage(props) { const query = router.query; const mode = query.mode; - const [loading, setLoading] = useState(false); + const [submitting, setSubmitting] = useState(false); const [activeStep, setActiveStep] = useState("basic"); const [detail, setDetail] = useState(null); @@ -338,8 +338,8 @@ function FilingFormPage(props) { const STEP_ITEMS = [ { key: "basic", - label: "1. 备案基本信息", - children: , + label: "1. 基本信息备案", + children: , forceRender: true, }, { @@ -367,7 +367,7 @@ function FilingFormPage(props) { }, { key: "personnel", - label: "4. 备案人员管理", + label: "4. 专职人员备案", children: ( - + { } }; + const handleDownload = async (record) => { + const raw = record.project_doc_url || ""; + if (!raw) { + message.warning("文件地址不存在"); + return; + } + const fileUrl = /^https?:\/\//.test(raw) ? raw : (window.fileUrl || "") + raw; + const fileName = record.materialName || raw.split("/").pop() || "文件"; + const hide = message.loading("正在下载...", 0); + try { + const response = await fetch(fileUrl, { + headers: { token: sessionStorage.getItem("token") || "" }, + }); + if (!response.ok) throw new Error(`HTTP ${response.status}`); + const blob = await response.blob(); + const blobUrl = window.URL.createObjectURL(blob); + const link = document.createElement("a"); + link.href = blobUrl; + link.download = fileName; + link.style.display = "none"; + document.body.appendChild(link); + link.click(); + document.body.removeChild(link); + window.URL.revokeObjectURL(blobUrl); + message.success("下载已开始"); + } catch { + message.error("下载失败,请稍后重试"); + } finally { + hide(); + } + }; + const columns = [ { title: "项目编号", dataIndex: "projectNo", width: 130 }, { @@ -264,9 +296,18 @@ const ProjectDocLibrary = (props) => { { title: "文件名称", dataIndex: "materialName", ellipsis: true }, { title: "操作", - width: 100, + width: 130, render: (_, record) => ( - + + + + ), }, ]}