mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-28 11:21:18 +00:00
fix issue
This commit is contained in:
@@ -42,8 +42,8 @@ export function ContainerAllocationTable({
|
||||
);
|
||||
|
||||
const { data: vehicles = [], isLoading: vehiclesLoading } = useQuery({
|
||||
queryKey: ["vehicles", "active"],
|
||||
queryFn: () => vehiclesService.getAll({ status: "ACTIVE" }),
|
||||
queryKey: ["vehicles", "free"],
|
||||
queryFn: () => vehiclesService.getAll({ status: "FREE" }),
|
||||
});
|
||||
|
||||
const vehicleOptions = useMemo(
|
||||
@@ -99,7 +99,7 @@ export function ContainerAllocationTable({
|
||||
<Stack gap="md">
|
||||
{vehicles.length === 0 && (
|
||||
<Alert icon={<AlertCircle size={16} />} color="yellow">
|
||||
No active vehicles available. Add vehicles before allocating containers.
|
||||
No free vehicles available. Free up or add vehicles before allocating containers.
|
||||
</Alert>
|
||||
)}
|
||||
|
||||
|
||||
@@ -42,8 +42,8 @@ export function FirstMileContainerAllocationTable({
|
||||
);
|
||||
|
||||
const { data: vehicles = [], isLoading: vehiclesLoading } = useQuery({
|
||||
queryKey: ["vehicles", "active"],
|
||||
queryFn: () => vehiclesService.getAll({ status: "ACTIVE" }),
|
||||
queryKey: ["vehicles", "free"],
|
||||
queryFn: () => vehiclesService.getAll({ status: "FREE" }),
|
||||
});
|
||||
|
||||
const vehicleOptions = useMemo(
|
||||
@@ -99,7 +99,7 @@ export function FirstMileContainerAllocationTable({
|
||||
<Stack gap="md">
|
||||
{vehicles.length === 0 && (
|
||||
<Alert icon={<AlertCircle size={16} />} color="yellow">
|
||||
No active vehicles available. Add vehicles before allocating containers.
|
||||
No free vehicles available. Free up or add vehicles before allocating containers.
|
||||
</Alert>
|
||||
)}
|
||||
|
||||
|
||||
@@ -42,8 +42,8 @@ export function LastMileContainerAllocationTable({
|
||||
);
|
||||
|
||||
const { data: vehicles = [], isLoading: vehiclesLoading } = useQuery({
|
||||
queryKey: ["vehicles", "active"],
|
||||
queryFn: () => vehiclesService.getAll({ status: "ACTIVE" }),
|
||||
queryKey: ["vehicles", "free"],
|
||||
queryFn: () => vehiclesService.getAll({ status: "FREE" }),
|
||||
});
|
||||
|
||||
const vehicleOptions = useMemo(
|
||||
@@ -99,7 +99,7 @@ export function LastMileContainerAllocationTable({
|
||||
<Stack gap="md">
|
||||
{vehicles.length === 0 && (
|
||||
<Alert icon={<AlertCircle size={16} />} color="yellow">
|
||||
No active vehicles available. Add vehicles before allocating containers.
|
||||
No free vehicles available. Free up or add vehicles before allocating containers.
|
||||
</Alert>
|
||||
)}
|
||||
|
||||
|
||||
@@ -355,9 +355,9 @@ const FirstMilePage = () => {
|
||||
});
|
||||
|
||||
const { data: vehiclesData } = useQuery({
|
||||
queryKey: ["vehicles", "list"],
|
||||
queryKey: ["vehicles", "free"],
|
||||
queryFn: async () => {
|
||||
const res = await vehiclesService.getAll({ status: "ACTIVE" });
|
||||
const res = await vehiclesService.getAll({ status: "FREE" });
|
||||
return res.data;
|
||||
},
|
||||
});
|
||||
|
||||
@@ -339,9 +339,9 @@ const LastMilePage = () => {
|
||||
});
|
||||
|
||||
const { data: vehiclesData } = useQuery({
|
||||
queryKey: ["vehicles", "list"],
|
||||
queryKey: ["vehicles", "free"],
|
||||
queryFn: async () => {
|
||||
const res = await vehiclesService.getAll({ status: "ACTIVE" });
|
||||
const res = await vehiclesService.getAll({ status: "FREE" });
|
||||
return res.data;
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user