修改身份证加密后判重问题

dev
853931625@qq.com 2025-12-25 13:35:50 +08:00
parent c61b34df0d
commit a4a9488978
17 changed files with 61 additions and 44 deletions

View File

@ -11,6 +11,7 @@ module.exports = {
// 接口服务地址 // 接口服务地址
API_HOST: "http://192.168.20.100:30140", API_HOST: "http://192.168.20.100:30140",
// API_HOST: "https://gbs-gateway.qhdsafety.com",
}, },
production: { production: {
// 应用后端分支名称,部署上线需要 // 应用后端分支名称,部署上线需要
@ -26,8 +27,8 @@ module.exports = {
contextInject: { contextInject: {
// 应用Key // 应用Key
appKey: "", appKey: "",
fileUrl: "http://192.168.20.240:9787/mnt/", // fileUrl: "http://192.168.20.240:9787/mnt/",
// fileUrl: "https://jpfz.qhdsafety.com/gbsFileTest/", fileUrl: "https://jpfz.qhdsafety.com/gbsFileTest/",
}, },
// public/index.html注入全局变量 // public/index.html注入全局变量
windowInject: { windowInject: {
@ -42,9 +43,7 @@ module.exports = {
}, },
}, },
// 注入js链接集合 // 注入js链接集合
scripts: [ scripts: [],
"https://api.map.baidu.com/api?v=1.0&type=webgl&ak=OElqFYoKiAH8KFtph8ftLKF5NlNrbCUr",
],
}, },
// 开发服务 // 开发服务
server: { server: {

View File

@ -16,7 +16,6 @@ function ChangeView(props) {
if (res.data) { if (res.data) {
setInfo(res.data); setInfo(res.data);
} }
}); });
}, []); }, []);
@ -140,6 +139,7 @@ function ChangeView(props) {
/> />
<Divider orientation="left">{queryParams["type"] === "disposal" ? "未完成工作" : "工作交接"}</Divider> <Divider orientation="left">{queryParams["type"] === "disposal" ? "未完成工作" : "工作交接"}</Divider>
<Table <Table
pagination={false}
columns={[ columns={[
{ {
title: "工作项目", title: "工作项目",

View File

@ -42,6 +42,8 @@ function List(props) {
const key = selectedKeys[0] || null; const key = selectedKeys[0] || null;
setSelectedNodeId(key); setSelectedNodeId(key);
getData(); getData();
}; };
return ( return (
<div> <div>
@ -57,7 +59,7 @@ function List(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree onSelect={onTreeChange} /> <LeftTree onSelect={onTreeChange} />

View File

@ -108,7 +108,7 @@ function OrganizationStructure(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree key={treeKey} onGetNodePaths={onGetNodePaths} /> <LeftTree key={treeKey} onGetNodePaths={onGetNodePaths} />

View File

@ -69,7 +69,7 @@ function Post(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree onSelect={onTreeChange} /> <LeftTree onSelect={onTreeChange} />

View File

@ -179,7 +179,7 @@ function Add(props) {
return; return;
} }
props["verifyUser"]({ props["verifyUser"]({
userIdCard: debouncedUserIdCard, userIdCard: btoa(debouncedUserIdCard),
id: queryParams["id"] ?? "", id: queryParams["id"] ?? "",
}).then((res) => { }).then((res) => {
if (!res.success) { if (!res.success) {

View File

@ -40,6 +40,7 @@ function List(props) {
const { downloadBlob } = useDownloadBlob(); const { downloadBlob } = useDownloadBlob();
const [selectedRowKeys, setSelectedRowKeys] = useState([]); const [selectedRowKeys, setSelectedRowKeys] = useState([]);
const { importFile } = useImportFile(); const { importFile } = useImportFile();
const [treeKey, setTreeKey] = useState(0);
const { tableProps, getData } = useTable(props["userList"], { const { tableProps, getData } = useTable(props["userList"], {
form, form,
transform: (formData) => { transform: (formData) => {
@ -105,6 +106,7 @@ function List(props) {
if (res.success) { if (res.success) {
message.success("导入成功"); message.success("导入成功");
getData(); getData();
setTreeKey(prev => prev + 1);
} }
}); });
}; };
@ -125,10 +127,10 @@ function List(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree onSelect={onTreeChange} /> <LeftTree onSelect={onTreeChange} key={treeKey} />
</div> </div>
<div style={{ flex: 1, display: "flex", flexDirection: "column", minHeight: 0, padding: "20px 0" }}> <div style={{ flex: 1, display: "flex", flexDirection: "column", minHeight: 0, padding: "20px 0" }}>
@ -211,11 +213,11 @@ function List(props) {
dataIndex: "name", dataIndex: "name",
}, },
{ {
title: "部门", title: "所属部门",
dataIndex: "departmentName", dataIndex: "departmentName",
}, },
{ {
title: "岗位", title: "所属岗位",
dataIndex: "postName", dataIndex: "postName",
}, },
// { // {

View File

@ -123,7 +123,7 @@ function Department(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree key={treeKey} onGetNodePaths={onGetNodePaths} /> <LeftTree key={treeKey} onGetNodePaths={onGetNodePaths} />

View File

@ -190,7 +190,7 @@ function Add(props) {
return; return;
} }
props["verifyUser"]({ props["verifyUser"]({
userIdCard: debouncedUserIdCard, userIdCard: btoa(debouncedUserIdCard),
id: queryParams["id"] ?? "", id: queryParams["id"] ?? "",
}).then((res) => { }).then((res) => {
if (!res.success) { if (!res.success) {

View File

@ -91,7 +91,7 @@ function List(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree onSelect={onTreeChange} /> <LeftTree onSelect={onTreeChange} />
@ -105,10 +105,10 @@ function List(props) {
name: "likeName", name: "likeName",
label: "姓名", label: "姓名",
}, },
{ // {
name: "likeUserIdCard", // name: "likeUserIdCard",
label: "身份证号", // label: "身份证号",
}, // },
]} ]}
onFinish={getData} onFinish={getData}
@ -165,6 +165,7 @@ function List(props) {
&& ( && (
<Button <Button
type="link" type="link"
onClick={() => { onClick={() => {
setAddModalOpen(true); setAddModalOpen(true);
setCurrentId(record.id); setCurrentId(record.id);
@ -180,6 +181,7 @@ function List(props) {
&& ( && (
<Button <Button
type="link" type="link"
hidden={record.employmentFlag === 0}
onClick={() => onResetPassword(record.id)} onClick={() => onResetPassword(record.id)}
> >
重置密码 重置密码
@ -191,6 +193,7 @@ function List(props) {
&& ( && (
<Button <Button
type="link" type="link"
hidden={record.employmentFlag === 0}
onClick={() => { onClick={() => {
props.history.push(`./add?id=${record.id}`); props.history.push(`./add?id=${record.id}`);
}} }}

View File

@ -113,6 +113,7 @@ function ResignationReview(props) {
<Divider orientation="left"> 未完成工作</Divider> <Divider orientation="left"> 未完成工作</Divider>
<Table <Table
pagination={false}
columns={[ columns={[
{ {
title: "工作项目", title: "工作项目",

View File

@ -121,11 +121,16 @@ function AddModalComponent(props) {
const res = await props.requestDetails({ const res = await props.requestDetails({
id: props.currentId, id: props.currentId,
}); });
if (res.data && res.data.userAvatarUrl) {
res.data.userAvatarUrl = [ res.data.userAvatarUrl = [
{ {
filePath: res.data.userAvatarUrl, filePath: res.data.userAvatarUrl,
}, },
]; ];
}
else {
res.data.userAvatarUrl = [];
}
setInfo(res.data); setInfo(res.data);
}; };

View File

@ -139,6 +139,7 @@ function ChangeView(props) {
/> />
<Divider orientation="left">{queryParams["type"] === "disposal" ? "未完成工作" : "工作交接"}</Divider> <Divider orientation="left">{queryParams["type"] === "disposal" ? "未完成工作" : "工作交接"}</Divider>
<Table <Table
pagination={false}
columns={[ columns={[
{ {
title: "工作项目", title: "工作项目",

View File

@ -136,7 +136,7 @@ function Department(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree key={treeKey} onSelect={onTreeChange} onGetNodePaths={onGetNodePaths} onGetData={data => setDepartmentData(data)} /> <LeftTree key={treeKey} onSelect={onTreeChange} onGetNodePaths={onGetNodePaths} onGetData={data => setDepartmentData(data)} />

View File

@ -65,7 +65,7 @@ function Post(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree onSelect={onTreeChange} /> <LeftTree onSelect={onTreeChange} />

View File

@ -55,6 +55,18 @@ function Add(props) {
const debouncedUsernameValue = useDebounce(usernameValue, 600); const debouncedUsernameValue = useDebounce(usernameValue, 600);
const debouncedPhoneValueValue = useDebounce(phoneValue, 600); const debouncedPhoneValueValue = useDebounce(phoneValue, 600);
const fnChoiceDepartment = async (event) => {
form.setFieldsValue({
postId: undefined,
});
// setDepartmentName(event[0].name)
props["postAll"]({
corpFlag: 1,
departmentId: event[event.length - 1].id,
}).then((res) => {
setPostData(res.data);
});
};
// const { loading: getFileLoading, getFile } = useGetFile(); // const { loading: getFileLoading, getFile } = useGetFile();
const { loading: uploadFileLoading, uploadFile } = useUploadFile(); const { loading: uploadFileLoading, uploadFile } = useUploadFile();
useEffect(() => { useEffect(() => {
@ -152,18 +164,7 @@ function Add(props) {
}); });
} }
}; };
const fnChoiceDepartment = async (event) => {
form.setFieldsValue({
postId: undefined,
});
// setDepartmentName(event[0].name)
props["postAll"]({
corpFlag: 1,
departmentId: event[event.length - 1].id,
}).then((res) => {
setPostData(res.data);
});
};
// 校验身份证重复 // 校验身份证重复
useEffect(() => { useEffect(() => {
if (!debouncedUserIdCard) { if (!debouncedUserIdCard) {
@ -175,8 +176,9 @@ function Add(props) {
]); ]);
return; return;
} }
props["verifyUser"]({ props["verifyUser"]({
userIdCard: debouncedUserIdCard, userIdCard: btoa(debouncedUserIdCard),
id: queryParams["id"] ?? "", id: queryParams["id"] ?? "",
}).then((res) => { }).then((res) => {
if (!res.success) { if (!res.success) {

View File

@ -32,6 +32,7 @@ function List(props) {
const [rolesData, setRolesData] = useState([]); const [rolesData, setRolesData] = useState([]);
const { downloadBlob } = useDownloadBlob(); const { downloadBlob } = useDownloadBlob();
const { importFile } = useImportFile(); const { importFile } = useImportFile();
const [treeKey, setTreeKey] = useState(0);
const [form] = Form.useForm(); const [form] = Form.useForm();
const { tableProps, getData } = useTable(props["userList"], { const { tableProps, getData } = useTable(props["userList"], {
form, form,
@ -104,6 +105,7 @@ function List(props) {
if (res.success) { if (res.success) {
message.success("导入成功"); message.success("导入成功");
getData(); getData();
setTreeKey(prev => prev + 1);
} }
}); });
// message.success("导入成功"); // message.success("导入成功");
@ -124,10 +126,10 @@ function List(props) {
borderRight: "10px solid #f1f1f2", borderRight: "10px solid #f1f1f2",
paddingRight: "10px", paddingRight: "10px",
marginRight: "10px", marginRight: "10px",
height: "100vh", height: "calc(100dvh - 112px)",
}} }}
> >
<LeftTree onSelect={onTreeChange} /> <LeftTree onSelect={onTreeChange} key={treeKey} />
</div> </div>
<div style={{ flex: 1, display: "flex", flexDirection: "column", minHeight: 0, padding: "20px 0" }}> <div style={{ flex: 1, display: "flex", flexDirection: "column", minHeight: 0, padding: "20px 0" }}>
<Search <Search