From b46b35cd4bee548d576461bf7882f8438a163f81 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AD=99=E6=99=AF=E5=AD=A6?= <5412262+sun_jing_xue@user.noreply.gitee.com> Date: Wed, 9 Jul 2025 14:01:45 +0800 Subject: [PATCH] =?UTF-8?q?=E7=99=BB=E5=BD=95=20=E4=B8=AA=E4=BA=BA=20?= =?UTF-8?q?=E4=B8=8E=20=E9=9B=B6=E6=98=9F=E9=87=87=E8=B4=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config/proxy.ts | 5 +- package.json | 2 + src/app.ts | 10 ++ .../CompanyInfo/component/BankFormModal.tsx | 9 +- .../CompanyInfo/component/ForeignForm.tsx | 29 +-- .../component/PeBaseInfoFormModal.tsx | 109 +++++++++++ .../CompanyInfo/component/PeBaseInfoTab.tsx | 107 +++++++++++ .../CompanyInfo/component/Person.tsx | 99 ++++++++++ src/components/CompanyInfo/index.tsx | 67 ++++--- src/components/CompanyInfo/services.ts | 2 +- .../components/SupplierRegisterInfo.tsx | 4 +- src/components/GlobalModal/index.tsx | 75 +++++--- src/locales/zh-CN/login.ts | 3 +- src/pages/login/login.tsx | 77 ++++++-- src/pages/register/supplier.tsx | 97 ++++++---- .../register/supplier/CommonFormSections.tsx | 18 +- src/pages/register/supplier/Person.tsx | 106 +++++++++++ .../admission/SupplierCategoryEntry/index.tsx | 1 + .../SupplierCategoryEntryReview/index.tsx | 1 + .../admission/SupplierEntryReview/index.tsx | 1 + .../components/CreateModal.tsx | 8 +- .../components/ResultModal.tsx | 94 ++++++---- .../admission/admissionManagement/index.tsx | 1 + .../admission/admissionManagement/services.ts | 7 + .../components/GroupLeaderModal.less | 10 ++ .../components/GroupLeaderModal.tsx | 130 +++++++------- .../components/ResultModal.tsx | 170 +++++++++--------- .../admissionReviewManagement/services.ts | 7 + .../SupplierRegisterAgent/index.tsx | 5 +- .../mySupplierInquiry/index.tsx | 26 ++- .../registrationQuery/index.tsx | 22 ++- src/servers/api/login.ts | 22 +++ src/servers/api/typings.d.ts | 7 + src/utils/encryptWithRsa.ts | 21 +++ src/utils/request.ts | 45 ++--- 35 files changed, 1054 insertions(+), 343 deletions(-) create mode 100644 src/app.ts create mode 100644 src/components/CompanyInfo/component/PeBaseInfoFormModal.tsx create mode 100644 src/components/CompanyInfo/component/PeBaseInfoTab.tsx create mode 100644 src/components/CompanyInfo/component/Person.tsx create mode 100644 src/pages/register/supplier/Person.tsx create mode 100644 src/pages/supplier/admission/admissionReviewManagement/components/GroupLeaderModal.less create mode 100644 src/servers/api/login.ts create mode 100644 src/utils/encryptWithRsa.ts diff --git a/config/proxy.ts b/config/proxy.ts index 9e663ac..20a8009 100644 --- a/config/proxy.ts +++ b/config/proxy.ts @@ -2,7 +2,10 @@ export default { dev: { '/api': { // target: 'http://10.242.37.148:18022',// - target: 'http://10.0.0.10:18012',// + // target: 'http://10.0.0.10:18012',// 茂 + target: 'http://10.0.0.125:18012',// 测试 + // target: 'http://10.0.0.14:18012',// 李 + // target: 'http://10.0.0.46:18030',// 袁 changeOrigin: true, pathRewrite: { '^/api': '' }, }, diff --git a/package.json b/package.json index 9fb89b3..8b4f0b1 100644 --- a/package.json +++ b/package.json @@ -70,10 +70,12 @@ "array-move": "3.0.1", "axios": "0.21.1", "classnames": "2.3.1", + "dayjs": "^1.11.13", "dva": "2.4.1", "echarts": "^5.2.2", "echarts-for-react": "^3.0.2", "file-saver": "^2.0.5", + "jsencrypt": "^3.3.2", "lodash": "4.17.21", "moment": "^2.29.4", "omit.js": "2.0.2", diff --git a/src/app.ts b/src/app.ts new file mode 100644 index 0000000..2727fc2 --- /dev/null +++ b/src/app.ts @@ -0,0 +1,10 @@ +import { history } from 'umi'; + +export function onRouteChange({ location }: any) { +// const token = localStorage.getItem('token'); +// const whiteList = ['/login', '/user/register', '/403', '/404']; +// if (!token && !whiteList.includes(location.pathname)) { +// history.replace('/login'); +// } + +} diff --git a/src/components/CompanyInfo/component/BankFormModal.tsx b/src/components/CompanyInfo/component/BankFormModal.tsx index 9d21db3..5fa7032 100644 --- a/src/components/CompanyInfo/component/BankFormModal.tsx +++ b/src/components/CompanyInfo/component/BankFormModal.tsx @@ -2,7 +2,9 @@ import React, { useEffect, useState } from 'react'; import { Modal, Form, Input, Button, Upload, message, Row, Col, Descriptions } from 'antd'; import type { UploadProps } from 'antd'; import { UploadOutlined } from '@ant-design/icons'; -import { uploadFile, bankView, bankAdd, bankEdit } from '../services'; +import { uploadFile, bankView, bankAdd, bankEdit, coscoSupplierBase } from '../services'; +import { getRegionTree, getregionInternational } from '@/servers/api/register'; + interface props { visible: boolean; onOk: () => void; @@ -56,6 +58,11 @@ const InvoiceFormModal: React.FC = ({ setViewData(fields); } }); + + + + + } else { form.resetFields(); // ✅ 只有无 initialValues 才重置 } diff --git a/src/components/CompanyInfo/component/ForeignForm.tsx b/src/components/CompanyInfo/component/ForeignForm.tsx index 1d2dcc2..2c6d4f0 100644 --- a/src/components/CompanyInfo/component/ForeignForm.tsx +++ b/src/components/CompanyInfo/component/ForeignForm.tsx @@ -1,5 +1,5 @@ /* 境外企业 表单项 */ -import React from 'react'; +import React, { useState, useEffect } from 'react'; import { Form, Input, Select, Row, Col } from 'antd'; import { MailOutlined, @@ -8,7 +8,7 @@ import { /** * 引入通用表单组件 */ - +import { getregionInternational } from '@/servers/api/register'; const { Option } = Select; interface ForeignFormProps { @@ -23,7 +23,15 @@ interface ForeignFormProps { * 其他部分使用通用表单组件 */ const ForeignForm: React.FC = ({ form, countdown, handleGetCaptcha }) => { - + // 全球 + const [regionOptions, setRegionOptions] = useState([]); + useEffect(() => { + getregionInternational().then(res => { + if (res.code === 200) { + setRegionOptions(res.data); + } + }); + }, []); return ( <> {/* 境外企业特有的基本信息部分 */} @@ -56,16 +64,11 @@ const ForeignForm: React.FC = ({ form, countdown, handleGetCap rules={[{ required: true, message: '请选择国家/地区' }]} > diff --git a/src/components/CompanyInfo/component/PeBaseInfoFormModal.tsx b/src/components/CompanyInfo/component/PeBaseInfoFormModal.tsx new file mode 100644 index 0000000..ea625d0 --- /dev/null +++ b/src/components/CompanyInfo/component/PeBaseInfoFormModal.tsx @@ -0,0 +1,109 @@ +import React, { useEffect, useState } from 'react'; +import { Modal, Form, message, Input, Upload, Button } from 'antd'; + + +import Person from './Person'; +import { updateSupplierBase } from '../services' + +interface Props { + visible: boolean; + onOk: () => void; + onCancel: () => void; + initialValues?: coscoSupplierBases; + +} + +// 基础信息 +interface coscoSupplierBases { + id?: string; + supplierType?: string; + name?: string; + nameEn?: string; + range?: string; + workAddress?: string; + parentCompanyInvestor?: string; + legalPerson?: string; + capital?: string; + contactsName?: string; + contactsPhone?: string; + contactsEmail?: string; + nation?: string; + vat?: string; + currency?: string; + licenceAccessory?: string; + licenceDate?: string; + enterpriseType?: string; + socialCreditCode?: string; + regAddress?: string; + idCard?: string; + contactsType?: string; + telephone?: string; + coscoSupplierSurveyAttachments?: coscoSupplierSurveyAttachments[]; +} + +interface coscoSupplierSurveyAttachments { + attachmentsType: string; + fileName: string; + fileType: string; + fileSize: string; + filePath: string; + fileUrl: string; +} + +const BaseInfoFormModal: React.FC = ({ + visible, + onOk, + onCancel, + initialValues, +}) => { + const [form] = Form.useForm(); + + //数据初始化 + useEffect(() => { + if (visible && initialValues) { + form.setFieldsValue({ + coscoSupplierBase: { + ...initialValues, + }, + }); + + } else { + form.resetFields(); + } + }, [visible, initialValues]); + + + //确认提交 + const handleFinish = async () => { + const values = await form.validateFields(); + const payload = { + ...values, + }; + + payload.coscoSupplierBase.name = payload.coscoSupplierBase.personName; + payload.coscoSupplierBase.contactPhone = payload.coscoSupplierBase.personPhone; + payload.coscoSupplierBase.id = initialValues?.id; + const res = await updateSupplierBase(payload); + if (res.code === 200) { + message.success('修改成功'); + onOk(); + } + }; + + return ( + +
+ + +
+ ); +}; + +export default BaseInfoFormModal; diff --git a/src/components/CompanyInfo/component/PeBaseInfoTab.tsx b/src/components/CompanyInfo/component/PeBaseInfoTab.tsx new file mode 100644 index 0000000..2e15c28 --- /dev/null +++ b/src/components/CompanyInfo/component/PeBaseInfoTab.tsx @@ -0,0 +1,107 @@ +import React, { useEffect, useState } from 'react'; +import { Descriptions, Button } from 'antd'; +import { coscoSupplierBase } from '../services'; +import { useIntl } from 'umi'; +import PeBaseInfoFormModal from './PeBaseInfoFormModal' + + +export interface Request { + capital: string; + contactsEmail: string; + contactsName: string; + contactsPhone: string; + contactsType: string; + enterpriseType: string; + id: string; + idCard: string; + legalPerson: string; + licenceAccessory: string; + licenceDate: string; + name: string; + nameEn: string; + parentCompanyInvestor: string; + range: string; + regAddress: string; + socialCreditCode: string; + telephone: string; + workAddress: string; + [property: string]: any; +} + +interface BaseInfoTabProps { + viewType?:boolean; + record?:string; +} + +const BaseInfoTab: React.FC = (props) => { + const { viewType = false, record = '' } = props; + const intl = useIntl(); + const [registerInfo, setRegisterInfo] = useState(); + const fetchData = async () => { + const res = await coscoSupplierBase(record); + if (res.code === 200) { + setRegisterInfo(res.data); + + } + }; + //增改查 + const [formVisible, setFormVisible] = useState(false); + const handleAdd = () => { + setFormVisible(true); + }; + const handleFormSubmit = () => { + setFormVisible(false); + fetchData(); + }; + + + useEffect(() => { + //供应商信息 + fetchData() + }, []); + + if (!registerInfo?.coscoSupplierBase) return
{intl.formatMessage({ id: 'component.globalModal.loading' })}...
; + + return ( +
+ + { !viewType && ( + + )} + + + {registerInfo.coscoSupplierBase.personName} + + + {registerInfo.coscoSupplierBase.idCard} + + + {registerInfo.coscoSupplierBase.personPhone} + + + {registerInfo.coscoSupplierBase.personBank} + + + {registerInfo.coscoSupplierBase.personAccount} + + {/* + {registerInfo.coscoSupplierBase.socialCreditCode} + */} + + + setFormVisible(false)} + initialValues={registerInfo.coscoSupplierBase || undefined} + /> +
+ ); +}; + +export default BaseInfoTab; diff --git a/src/components/CompanyInfo/component/Person.tsx b/src/components/CompanyInfo/component/Person.tsx new file mode 100644 index 0000000..d3a225d --- /dev/null +++ b/src/components/CompanyInfo/component/Person.tsx @@ -0,0 +1,99 @@ +/* 境外企业 表单项 */ +import React from 'react'; +import { Form, Input, Row, Col } from 'antd'; +import { + MobileOutlined, +} from '@ant-design/icons'; + +interface ForeignFormProps { + form: any; +} + +/** + * 个人注册表单 + * 基本信息部分为个人 + */ +const ForeignForm: React.FC = ({ form }) => { + + return ( + <> + {/* 境外企业特有的基本信息部分 */} +
基本信息
+ + + + + + + + + + + + + + + + } + /> + + + + + + + + + + + + + {/* + + validateFileSize(file, 10, ['pdf', 'jpg', 'jpeg', 'png'])} + > + + + + */} + + + ); +}; + +export default ForeignForm; diff --git a/src/components/CompanyInfo/index.tsx b/src/components/CompanyInfo/index.tsx index b29c38e..192a531 100644 --- a/src/components/CompanyInfo/index.tsx +++ b/src/components/CompanyInfo/index.tsx @@ -1,4 +1,4 @@ -import React, { useState } from 'react'; +import React, { useState, useEffect } from 'react'; import { Tabs } from 'antd'; import { useIntl } from 'umi'; import BaseInfoTab from './component/BaseInfoTab'; @@ -7,6 +7,9 @@ import InvoiceTab from './component/InvoiceTab'; import AttachmentsTab from './component/AttachmentsTab'; import ContactsInfoTab from './component/ContactsInfoTab'; import BankInfoTab from './component/BankInfoTab'; +import PeBaseInfoTab from './component/PeBaseInfoTab'; + +import { coscoSupplierBase } from './services' interface CompanyInfoProps { viewType?: boolean; @@ -16,31 +19,53 @@ interface CompanyInfoProps { const { TabPane } = Tabs; const CompanyInfo: React.FC = (props) => { - const { viewType = false, record = '999698' } = props; + const { viewType = false, record = '' } = props; const intl = useIntl(); // 切换tab - const [subTab, setSubTab] = useState('base'); + const [subTab, setSubTab] = useState(''); + + useEffect(() => { + coscoSupplierBase(record).then((res) => { + if (res.code === 200) { + if (res.data.coscoSupplierBase.supplierType === 'pe') { + setSubTab('pe') + } else { + setSubTab('base') + } + } + }) + + }, [record]) return ( - - - - - - - - - - - - - - - - - - + {subTab === 'pe' ? ( + + + + ) : ( + <> + + + + + + + + + + + + + + + + + + + + )} + ); }; diff --git a/src/components/CompanyInfo/services.ts b/src/components/CompanyInfo/services.ts index fa5873a..8e524ab 100644 --- a/src/components/CompanyInfo/services.ts +++ b/src/components/CompanyInfo/services.ts @@ -5,7 +5,7 @@ import request from '@/utils/request'; /** * 供应商基本信息 */ -export const coscoSupplierBase = (id: string) => request.get(`/coscoSupplierBase/${id? id: '999698'}`); +export const coscoSupplierBase = (id: string) => request.get(`/coscoSupplierBase/${id? id: '1942784565717565440'}`); /** * 资质分页列表 diff --git a/src/components/GlobalModal/components/SupplierRegisterInfo.tsx b/src/components/GlobalModal/components/SupplierRegisterInfo.tsx index 835d5fd..1f8bc68 100644 --- a/src/components/GlobalModal/components/SupplierRegisterInfo.tsx +++ b/src/components/GlobalModal/components/SupplierRegisterInfo.tsx @@ -254,7 +254,9 @@ const bankColumns:ColumnsType = [ label={intl.formatMessage({ id: 'component.globalModal.otherAttachmentLabel' })} labelStyle={{ width: '200px' }} > - {intl.formatMessage({id: 'component.globalModal.viewAttachment'})} + { registerInfo.coscoSupplierSurveyAttachments[0].fileUrl && ( + {intl.formatMessage({id: 'component.globalModal.viewAttachment'})} + )} diff --git a/src/components/GlobalModal/index.tsx b/src/components/GlobalModal/index.tsx index a185d30..d63920c 100644 --- a/src/components/GlobalModal/index.tsx +++ b/src/components/GlobalModal/index.tsx @@ -1,11 +1,12 @@ import React, { useEffect, useState } from 'react'; import { connect, useIntl } from 'umi'; -import { Modal, Button, Space, Tag } from 'antd'; -import { coscoSupplierBase } from './services' +import { Modal, Button, Space, Descriptions } from 'antd'; +import { coscoSupplierBase } from './services' import SupplierRegisterInfo from './components/SupplierRegisterInfo'; import AccessCategoryTable from './components/AccessCategoryTable'; import TianyanchaInfo from './components/TianyanchaInfo'; import RiskList from './components/RiskList'; + // 弹出主体 const GlobalModal = ({ visible, id, dispatch }: any) => { const intl = useIntl(); @@ -14,14 +15,10 @@ const GlobalModal = ({ visible, id, dispatch }: any) => { const [modalType, setModalType] = useState<'register' | 'category' | 'tianyancha' | 'risk'>('register'); //供应商信息数据 const [registerInfo, setRegisterInfo] = useState(null); - //黑名单显示状态 - const isBlacklisted = true; - //灰名单显示状态 - const isGreylisted = true; //获取供应商信息 const fetchRegisterInfo = () => { //供应商信息 - + coscoSupplierBase(id).then((res) => { let { code, data } = res; if (code == 200) { @@ -35,7 +32,7 @@ const GlobalModal = ({ visible, id, dispatch }: any) => { }; // 渲染页面 供应商信息 准入品类/品类库 天眼查工商信息 合规风险列表 页面标签 const renderContent = () => { - if (modalType === 'register') { + if (modalType === 'register' && registerInfo?.coscoSupplierBase) { //供应商页面 return ; } @@ -55,11 +52,9 @@ const GlobalModal = ({ visible, id, dispatch }: any) => { }; // 初始化 useEffect(() => { - if (visible) { setModalType('register'); fetchRegisterInfo(); - coscoSupplierBase(id) } }, [visible, id]); return ( @@ -67,29 +62,55 @@ const GlobalModal = ({ visible, id, dispatch }: any) => { visible={visible} zIndex={1100} width="90%" - onCancel={() => dispatch({ type: 'globalModal/hide' })} + onCancel={() => { + setRegisterInfo(null); // ← 清空数据 + dispatch({ type: 'globalModal/hide' }); + }} footer={null} title={
- {intl.formatMessage({id: 'component.globalModal.title' })} - {/* - {isBlacklisted && {intl.formatMessage({id: 'component.globalModal.blacklist' })}} - {isGreylisted && {intl.formatMessage({id: 'component.globalModal.GreyList' })}} - */} + {intl.formatMessage({ id: 'component.globalModal.title' })}
} > -
- - - - - - -
- {renderContent()} -
-
+ {(registerInfo?.coscoSupplierBase.supplierType !== 'pe' && registerInfo ) ? + ( +
+ + + + + + +
+ {renderContent()} +
+
+ ) : ( + + + {registerInfo?.coscoSupplierBase.personName} + + + {registerInfo?.coscoSupplierBase.idCard} + + + {registerInfo?.coscoSupplierBase.personPhone} + + + {registerInfo?.coscoSupplierBase.personBank} + + + {registerInfo?.coscoSupplierBase.personAccount} + + {/* + {registerInfo?.coscoSupplierBase.accessory} + */} + + ) + } + + ); }; diff --git a/src/locales/zh-CN/login.ts b/src/locales/zh-CN/login.ts index 1ae8c33..6521f8a 100644 --- a/src/locales/zh-CN/login.ts +++ b/src/locales/zh-CN/login.ts @@ -1,6 +1,6 @@ export default { // 登录页文案 - "login.title": "电子招投标平台", + "login.title": "中远海运", "login.tab.supplier": "供应商", "login.tab.expert": "专家", "login.tab.agent": "招标代理", @@ -12,4 +12,5 @@ export default { "login.register.tip": "还没有账号?", "login.register.action": "立即注册", "login.back.home": "返回首页", + "login.captcha.placeholder": "请输入验证码", }; diff --git a/src/pages/login/login.tsx b/src/pages/login/login.tsx index 993a82f..2978070 100644 --- a/src/pages/login/login.tsx +++ b/src/pages/login/login.tsx @@ -1,8 +1,12 @@ -import React, { useState } from 'react'; +import React, { useState, useEffect } from 'react'; import { Form, Input, Button, Checkbox, Tabs, message } from 'antd'; import { UserOutlined, LockOutlined, EyeInvisibleOutlined, EyeTwoTone, HomeOutlined } from '@ant-design/icons'; import { history, useIntl } from 'umi'; import './login.less'; +import { getCaptcha, supplierLogin } from '@/servers/api/login'; + +import { encryptWithRsa } from '@/utils/encryptWithRsa' +import Password from 'antd/lib/input/Password'; const { TabPane } = Tabs; @@ -10,17 +14,44 @@ const LoginPage: React.FC = () => { const [activeKey, setActiveKey] = useState('supplier'); const [form] = Form.useForm(); const [loading, setLoading] = useState(false); + const [captchaImg, setCaptchaImg] = useState(''); + const [captchaKey, setCaptchaKey] = useState(''); + const intl = useIntl(); - const onFinish = (values: any) => { + useEffect(() => { + fetchCaptcha(); + }, [activeKey]); + + const onFinish = async (values: any) => { setLoading(true); - console.log('登录信息:', values); - // 这里添加登录逻辑 - setTimeout(() => { + try { + const params = { + ...values, + password: encryptWithRsa(values.password, false), + encryptValue: encryptWithRsa(values.identifying) + }; + const loginRes = await supplierLogin(params); + if (loginRes.code === 200) { + sessionStorage.setItem('token', loginRes.data.token); + sessionStorage.setItem('currentUser', JSON.stringify(loginRes.data)); + message.success('登录成功'); + history.push('/index'); + } else { + message.error(loginRes.message || '登录失败'); + } + } finally { setLoading(false); - message.success('登录成功'); - history.push('/index'); - }, 1000); + } + }; + + + const fetchCaptcha = async () => { + const res = await getCaptcha(); + if (res.code === 200) { + setCaptchaImg(res.data.base64Image); + setCaptchaKey(res.data.code); + } }; const handleTabChange = (key: string) => { @@ -62,21 +93,21 @@ const LoginPage: React.FC = () => { return (
- */}
{intl.formatMessage({ id: 'login.title' })}
-
+ {/*
-
+
*/}
{ onFinish={onFinish} > { size="large" /> + + + } + /> +
diff --git a/src/pages/register/supplier.tsx b/src/pages/register/supplier.tsx index 1d03ac2..243a985 100644 --- a/src/pages/register/supplier.tsx +++ b/src/pages/register/supplier.tsx @@ -5,6 +5,7 @@ import { Form, Button, message, Radio, Checkbox, Modal, Spin } from 'antd'; import { HomeOutlined } from '@ant-design/icons'; import DomesticForm from './supplier/DomesticForm'; import ForeignForm from './supplier/ForeignForm'; +import Person from './supplier/Person'; import { addAgent, coscoSupplierBaseAdd, fetchSurveyQuestions } from '@/servers/api/register'; import './register.less'; @@ -80,18 +81,30 @@ const SupplierRegister: React.FC = (props) => { values.coscoSupplierBase = values.coscoSupplierBase || {}; values.coscoSupplierBase.supplierType = supplierType; + if(supplierType === 'pe') { + values.coscoSupplierBase.personName = values.coscoSupplierBase.name; + values.coscoSupplierBase.personPhone = values.coscoSupplierBase.contactPhone; + values.coscoSupplierSurveyAttachments = [{ + attachmentsType: "accessory", + fileName: values.attachments.file.response.fileName, + fileType: values.attachments.file.response.fileType, + fileSize: values.attachments.file.response.fileSize, + filePath: values.attachments.file.response.filePath, + fileUrl: values.attachments.file.response.filePath, + }] + } console.log('供应商注册信息:', values); + // 直接调用API supplierWithInput === true 供应商注册代录 否则 注册 accessory - // 直接调用API supplierWithInput === true 供应商注册代录 否则 注册 - const response = await (supplierWithInput? addAgent(values) : coscoSupplierBaseAdd(values)); + const response = await (supplierWithInput ? addAgent(values) : coscoSupplierBaseAdd(values)); if (response.success) { - if(!supplierWithInput) { + if (!supplierWithInput) { message.success('注册成功,请登录'); history.push('/login'); } else { - message.success(`${exitId? '修改成功': '注册成功'}`); - onOk; + message.success(`${exitId ? '修改成功' : '注册成功'}`); + onOk?.(); } } else { message.error(response.message || '注册失败,请重试'); @@ -143,9 +156,13 @@ const SupplierRegister: React.FC = (props) => { 境内企业/机构 境外企业 + {supplierWithInput && ( + 个人 + )} + {supplierType === 'dvs' ? ( = (props) => { surveyQuestions={surveyQuestions} handleGetCaptcha={handleGetCaptcha} /> - ) : ( + ) : supplierType === 'ovs' ? ( + ) : ( + )} - - value - ? Promise.resolve() - : Promise.reject(new Error('请阅读并同意注册信息承诺书')), - }, - ]} - > - - 我已阅读并同意 - - - + {supplierType !== 'pe' && ( + + value + ? Promise.resolve() + : Promise.reject(new Error('请阅读并同意注册信息承诺书')), + }, + ]} + > + + 我已阅读并同意 + + + + )} + + +
+ + + + + + ); +}; + +export default ForeignForm; diff --git a/src/pages/supplier/admission/SupplierCategoryEntry/index.tsx b/src/pages/supplier/admission/SupplierCategoryEntry/index.tsx index 9f659ae..60b00ea 100644 --- a/src/pages/supplier/admission/SupplierCategoryEntry/index.tsx +++ b/src/pages/supplier/admission/SupplierCategoryEntry/index.tsx @@ -107,6 +107,7 @@ const SupplierCategoryEntry: React.FC = () => { diff --git a/src/pages/supplier/admission/SupplierCategoryEntryReview/index.tsx b/src/pages/supplier/admission/SupplierCategoryEntryReview/index.tsx index cd0b13f..14de895 100644 --- a/src/pages/supplier/admission/SupplierCategoryEntryReview/index.tsx +++ b/src/pages/supplier/admission/SupplierCategoryEntryReview/index.tsx @@ -87,6 +87,7 @@ const SupplierCategoryEntryReview: React.FC = () => { diff --git a/src/pages/supplier/admission/SupplierEntryReview/index.tsx b/src/pages/supplier/admission/SupplierEntryReview/index.tsx index 18b5a1e..588dd4d 100644 --- a/src/pages/supplier/admission/SupplierEntryReview/index.tsx +++ b/src/pages/supplier/admission/SupplierEntryReview/index.tsx @@ -195,6 +195,7 @@ const SupplierEntryReview: React.FC = () => { diff --git a/src/pages/supplier/admission/admissionManagement/components/CreateModal.tsx b/src/pages/supplier/admission/admissionManagement/components/CreateModal.tsx index 907bb09..8c861ae 100644 --- a/src/pages/supplier/admission/admissionManagement/components/CreateModal.tsx +++ b/src/pages/supplier/admission/admissionManagement/components/CreateModal.tsx @@ -278,6 +278,7 @@ const CreateModal: React.FC<{ visible: boolean; onCancel: () => void; }> = ({ vi 线上准入 线下准入 + 零星采购/应急采购 @@ -313,7 +314,7 @@ const CreateModal: React.FC<{ visible: boolean; onCancel: () => void; }> = ({ vi - {admissionMethod !== 'online' && ( + {admissionMethod === 'offline' && ( <> void; }> = ({ vi rules={[ { validator: (_, value) => { - if (admissionMethod === 'online') { + if (admissionMethod === 'offline') { if (!value || value.length === 0) { return Promise.reject(new Error('请上传供应商符合性审查文件')); } @@ -426,7 +427,8 @@ const CreateModal: React.FC<{ visible: boolean; onCancel: () => void; }> = ({ vi