add
This commit is contained in:
parent
58fc9d8895
commit
209530842d
|
@ -11,7 +11,6 @@ interface DeviceTypeSelectProps {
|
||||||
style?: React.CSSProperties;
|
style?: React.CSSProperties;
|
||||||
systemTypeId?: string; // 添加网系类别ID作为过滤条件
|
systemTypeId?: string; // 添加网系类别ID作为过滤条件
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function DeviceTypeSelect({
|
export default function DeviceTypeSelect({
|
||||||
value,
|
value,
|
||||||
onChange,
|
onChange,
|
||||||
|
@ -25,7 +24,6 @@ export default function DeviceTypeSelect({
|
||||||
[]
|
[]
|
||||||
);
|
);
|
||||||
const [loading, setLoading] = useState(false);
|
const [loading, setLoading] = useState(false);
|
||||||
|
|
||||||
// 获取所有故障类型数据(包括子项)
|
// 获取所有故障类型数据(包括子项)
|
||||||
const { data: allDeviceTypes, isLoading, refetch: refetchDeviceType } = api.term.findMany.useQuery({
|
const { data: allDeviceTypes, isLoading, refetch: refetchDeviceType } = api.term.findMany.useQuery({
|
||||||
where: {
|
where: {
|
||||||
|
@ -44,7 +42,6 @@ export default function DeviceTypeSelect({
|
||||||
},
|
},
|
||||||
orderBy: { order: "asc" },
|
orderBy: { order: "asc" },
|
||||||
});
|
});
|
||||||
|
|
||||||
// 获取网系类别下的所有故障
|
// 获取网系类别下的所有故障
|
||||||
const { data: systemTypeTerms, refetch: refetchSystemType } = api.term.findMany.useQuery(
|
const { data: systemTypeTerms, refetch: refetchSystemType } = api.term.findMany.useQuery(
|
||||||
{
|
{
|
||||||
|
@ -61,10 +58,8 @@ export default function DeviceTypeSelect({
|
||||||
enabled: !!systemTypeId,
|
enabled: !!systemTypeId,
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
// 处理数据显示
|
// 处理数据显示
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
|
||||||
setLoading(isLoading);
|
setLoading(isLoading);
|
||||||
if (allDeviceTypes) {
|
if (allDeviceTypes) {
|
||||||
// 有选中的网系类别
|
// 有选中的网系类别
|
||||||
|
|
|
@ -19,7 +19,6 @@ export default function FixTypeSelect({ value,onChange,placeholder = "选择故
|
||||||
{ label: "维修中", value: "maintenance" },
|
{ label: "维修中", value: "maintenance" },
|
||||||
{ label: "未修复", value: "broken" },
|
{ label: "未修复", value: "broken" },
|
||||||
];
|
];
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Select
|
<Select
|
||||||
value={value}
|
value={value}
|
||||||
|
|
|
@ -2,7 +2,7 @@ server {
|
||||||
# 监听80端口
|
# 监听80端口
|
||||||
listen 80;
|
listen 80;
|
||||||
# 服务器域名/IP地址,使用环境变量
|
# 服务器域名/IP地址,使用环境变量
|
||||||
server_name 192.168.21.194;
|
server_name 192.168.28.194;
|
||||||
|
|
||||||
# 基础性能优化配置
|
# 基础性能优化配置
|
||||||
# 启用tcp_nopush以优化数据发送
|
# 启用tcp_nopush以优化数据发送
|
||||||
|
@ -100,7 +100,7 @@ server {
|
||||||
# 仅供内部使用
|
# 仅供内部使用
|
||||||
internal;
|
internal;
|
||||||
# 代理到认证服务
|
# 代理到认证服务
|
||||||
proxy_pass http://192.168.21.194:3000/auth/file;
|
proxy_pass http://192.168.28.194:3000/auth/file;
|
||||||
|
|
||||||
# 请求优化:不传递请求体
|
# 请求优化:不传递请求体
|
||||||
proxy_pass_request_body off;
|
proxy_pass_request_body off;
|
||||||
|
|
Loading…
Reference in New Issue