@burdenoff/microfe-movethewheels 2026.930.2 → 2026.930.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/StockActionDialogs.js +385 -0
- package/dist/hooks/useFleet.js +112 -109
- package/dist/hooks/useInventory.js +248 -124
- package/dist/index.js +34 -34
- package/dist/movethewheels/components/StockActionDialogs.d.ts +24 -0
- package/dist/movethewheels/hooks/index.d.ts +1 -1
- package/dist/movethewheels/hooks/useFleet.d.ts +1 -0
- package/dist/movethewheels/hooks/useInventory.d.ts +30 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/package-plus.js +33 -0
- package/dist/node_modules/lucide-react/dist/esm/icons/sliders-horizontal.js +69 -0
- package/dist/pages/DriverDetailsPage.js +401 -347
- package/dist/pages/InventoryPage.js +279 -200
- package/dist/pages/RouteDetailsPage.js +4 -4
- package/package.json +1 -1
- package/src/movethewheels/components/StockActionDialogs.tsx +512 -0
- package/src/movethewheels/hooks/index.ts +3 -0
- package/src/movethewheels/hooks/useFleet.ts +18 -0
- package/src/movethewheels/hooks/useInventory.ts +294 -35
- package/src/movethewheels/pages/DriverDetailsPage.tsx +72 -1
- package/src/movethewheels/pages/InventoryPage.tsx +98 -1
- package/src/movethewheels/pages/RouteDetailsPage.tsx +5 -4
package/dist/index.js
CHANGED
|
@@ -3,39 +3,39 @@ import { useTr as n } from "./shared/hooks/useTr.js";
|
|
|
3
3
|
import { useRoute as r, useRouteStats as i, useRoutes as a } from "./hooks/useRoutes.js";
|
|
4
4
|
import { useOrder as o, useOrderStats as s, useOrders as c } from "./hooks/useOrders.js";
|
|
5
5
|
import { useDriver as l, useDriverStatusCounts as u, useDrivers as d, useFleet as f, useFleetStats as p, useVehicle as m, useVehicleDrivers as h, useVehicles as g } from "./hooks/useFleet.js";
|
|
6
|
-
import { useInventory as _, useInventoryStats as v, useInventoryTransactions as y, useProduct as b, useProductStockLevels as x, useProducts as S,
|
|
7
|
-
import { useCustomer as
|
|
8
|
-
import { useAnalytics as
|
|
9
|
-
import { useDriverTracking as
|
|
10
|
-
import { useReports as
|
|
11
|
-
import { useImportExport as
|
|
12
|
-
import { useModuleSettings as
|
|
13
|
-
import { useEntityDocuments as
|
|
14
|
-
import { useCaptureEpod as
|
|
6
|
+
import { useInventory as _, useInventoryStats as v, useInventoryTransactions as y, useProduct as b, useProductStockLevels as x, useProducts as S, useStockActions as C, useWarehouse as w, useWarehouses as T } from "./hooks/useInventory.js";
|
|
7
|
+
import { useCustomer as E, useCustomerStats as D, useCustomers as O } from "./hooks/useCustomers.js";
|
|
8
|
+
import { useAnalytics as k, useDashboardMetrics as A, useEmissionsSummary as j, useFinanceMetrics as M, useFleetAnalytics as N, useOrderAnalytics as P, usePerformanceAnalytics as F, useRevenueAnalytics as I } from "./hooks/useAnalytics.js";
|
|
9
|
+
import { useDriverTracking as L, useGeofence as R, useLiveTracking as z, useOrderTracking as B, useTracking as V, useTrackingAlerts as H, useVehicleTracking as U } from "./hooks/useTracking.js";
|
|
10
|
+
import { useReports as W } from "./hooks/useReports.js";
|
|
11
|
+
import { useImportExport as G } from "./hooks/useImportExport.js";
|
|
12
|
+
import { useModuleSettings as K } from "./hooks/useSettings.js";
|
|
13
|
+
import { useEntityDocuments as q } from "./hooks/useEntityDocuments.js";
|
|
14
|
+
import { useCaptureEpod as J, useEpod as Y, useEpodPhotoUpload as X, useEpodPhotoUrl as Z, useMyPendingEpodDeliveryJobs as Q } from "./hooks/useEpod.js";
|
|
15
15
|
import "./hooks/index.js";
|
|
16
|
-
import { MoveTheWheelsRoot as
|
|
17
|
-
import { useMoveTheWheelsStore as
|
|
18
|
-
import { useSandboxAssistantTransport as
|
|
19
|
-
import { Avatar as
|
|
20
|
-
import { EmptyState as
|
|
21
|
-
import { chartTokens as
|
|
22
|
-
import { Sparkline as
|
|
23
|
-
import { MetricCard as
|
|
24
|
-
import { GlassPanel as
|
|
25
|
-
import { ChartEmpty as
|
|
26
|
-
import { TrendChart as
|
|
27
|
-
import { VolumeBar as
|
|
28
|
-
import { StatusDonut as
|
|
29
|
-
import { createCurrentIcon as
|
|
30
|
-
import { MapCanvas as
|
|
31
|
-
import { LogisticsMap as
|
|
32
|
-
import { RouteMap as
|
|
33
|
-
import { TrackingMap as
|
|
34
|
-
import { PaymentStatusBadge as
|
|
35
|
-
import { DataTable as
|
|
36
|
-
import { FormError as
|
|
37
|
-
import { Notice as
|
|
38
|
-
import { DocumentsCard as
|
|
39
|
-
import { CarbonFootprintPanel as
|
|
16
|
+
import { MoveTheWheelsRoot as $ } from "./MoveTheWheelsRoot.js";
|
|
17
|
+
import { useMoveTheWheelsStore as ee } from "./store/movethewheelsStore.js";
|
|
18
|
+
import { useSandboxAssistantTransport as te } from "./services/createSandboxAssistantTransport.js";
|
|
19
|
+
import { Avatar as ne, AvatarFallback as re, AvatarImage as ie, Badge as ae, Button as oe, Card as se, CardContent as ce, CardDescription as le, CardFooter as ue, CardHeader as de, CardTitle as fe, Checkbox as pe, Command as me, CommandEmpty as he, CommandGroup as ge, CommandInput as _e, CommandItem as ve, CommandList as ye, Dialog as be, DialogContent as xe, DialogDescription as Se, DialogFooter as Ce, DialogHeader as we, DialogTitle as Te, DialogTrigger as Ee, DropdownMenu as De, DropdownMenuContent as Oe, DropdownMenuItem as ke, DropdownMenuSeparator as Ae, DropdownMenuTrigger as je, Input as Me, Label as Ne, Popover as Pe, PopoverContent as Fe, PopoverTrigger as Ie, Progress as Le, ScrollArea as Re, Select as ze, SelectContent as Be, SelectItem as Ve, SelectTrigger as He, SelectValue as Ue, Separator as We, Skeleton as Ge, Switch as Ke, Table as qe, TableBody as Je, TableCell as Ye, TableHead as Xe, TableHeader as Ze, TableRow as Qe, Tabs as $e, TabsContent as et, TabsList as tt, TabsTrigger as nt, Textarea as rt, Tooltip as it, TooltipContent as at, TooltipProvider as ot, TooltipTrigger as st } from "./components/ui.js";
|
|
20
|
+
import { EmptyState as ct, ErrorState as lt, LoadingState as ut, PageLayout as dt, PageSection as ft } from "./components/PageLayout.js";
|
|
21
|
+
import { chartTokens as pt, seriesColor as mt } from "./components/charts/chartTokens.js";
|
|
22
|
+
import { Sparkline as ht } from "./components/charts/Sparkline.js";
|
|
23
|
+
import { MetricCard as gt, MetricCardSkeleton as _t, MetricGrid as vt } from "./components/MetricCard.js";
|
|
24
|
+
import { GlassPanel as yt } from "./components/GlassPanel.js";
|
|
25
|
+
import { ChartEmpty as bt, ChartTooltip as xt } from "./components/charts/ChartShell.js";
|
|
26
|
+
import { TrendChart as St } from "./components/charts/TrendChart.js";
|
|
27
|
+
import { VolumeBar as Ct } from "./components/charts/VolumeBar.js";
|
|
28
|
+
import { StatusDonut as wt } from "./components/charts/StatusDonut.js";
|
|
29
|
+
import { createCurrentIcon as Tt, createPinIcon as Et, createStopIcon as Dt, isRealCoord as Ot } from "./components/maps/leaflet-setup.js";
|
|
30
|
+
import { MapCanvas as kt } from "./components/maps/MapCanvas.js";
|
|
31
|
+
import { LogisticsMap as At } from "./components/maps/LogisticsMap.js";
|
|
32
|
+
import { RouteMap as jt } from "./components/maps/RouteMap.js";
|
|
33
|
+
import { TrackingMap as Mt } from "./components/maps/TrackingMap.js";
|
|
34
|
+
import { PaymentStatusBadge as Nt, PriorityBadge as Pt, StatusBadge as Ft, TypeBadge as It, VehicleTypeBadge as Lt } from "./components/StatusBadge.js";
|
|
35
|
+
import { DataTable as Rt } from "./components/DataTable.js";
|
|
36
|
+
import { FormError as zt } from "./components/FormError.js";
|
|
37
|
+
import { Notice as Bt, useNotice as Vt } from "./components/Notice.js";
|
|
38
|
+
import { DocumentsCard as Ht } from "./components/DocumentsCard.js";
|
|
39
|
+
import { CarbonFootprintPanel as Ut } from "./components/CarbonFootprintPanel.js";
|
|
40
40
|
import "./components/index.js";
|
|
41
|
-
export {
|
|
41
|
+
export { ne as Avatar, re as AvatarFallback, ie as AvatarImage, ae as Badge, oe as Button, Ut as CarbonFootprintPanel, se as Card, ce as CardContent, le as CardDescription, ue as CardFooter, de as CardHeader, fe as CardTitle, bt as ChartEmpty, xt as ChartTooltip, pe as Checkbox, me as Command, he as CommandEmpty, ge as CommandGroup, _e as CommandInput, ve as CommandItem, ye as CommandList, Rt as DataTable, be as Dialog, xe as DialogContent, Se as DialogDescription, Ce as DialogFooter, we as DialogHeader, Te as DialogTitle, Ee as DialogTrigger, Ht as DocumentsCard, De as DropdownMenu, Oe as DropdownMenuContent, ke as DropdownMenuItem, Ae as DropdownMenuSeparator, je as DropdownMenuTrigger, ct as EmptyState, lt as ErrorState, zt as FormError, yt as GlassPanel, Me as Input, Ne as Label, ut as LoadingState, At as LogisticsMap, kt as MapCanvas, gt as MetricCard, _t as MetricCardSkeleton, vt as MetricGrid, $ as MoveTheWheelsRoot, Bt as Notice, dt as PageLayout, ft as PageSection, Nt as PaymentStatusBadge, Pe as Popover, Fe as PopoverContent, Ie as PopoverTrigger, Pt as PriorityBadge, Le as Progress, jt as RouteMap, Re as ScrollArea, ze as Select, Be as SelectContent, Ve as SelectItem, He as SelectTrigger, Ue as SelectValue, We as Separator, Ge as Skeleton, ht as Sparkline, Ft as StatusBadge, wt as StatusDonut, Ke as Switch, qe as Table, Je as TableBody, Ye as TableCell, Xe as TableHead, Ze as TableHeader, Qe as TableRow, $e as Tabs, et as TabsContent, tt as TabsList, nt as TabsTrigger, rt as Textarea, it as Tooltip, at as TooltipContent, ot as TooltipProvider, st as TooltipTrigger, Mt as TrackingMap, St as TrendChart, It as TypeBadge, Lt as VehicleTypeBadge, Ct as VolumeBar, pt as chartTokens, Tt as createCurrentIcon, Et as createPinIcon, Dt as createStopIcon, Ot as isRealCoord, mt as seriesColor, k as useAnalytics, J as useCaptureEpod, E as useCustomer, D as useCustomerStats, O as useCustomers, A as useDashboardMetrics, l as useDriver, u as useDriverStatusCounts, L as useDriverTracking, d as useDrivers, j as useEmissionsSummary, q as useEntityDocuments, Y as useEpod, X as useEpodPhotoUpload, Z as useEpodPhotoUrl, M as useFinanceMetrics, f as useFleet, N as useFleetAnalytics, p as useFleetStats, R as useGeofence, G as useImportExport, _ as useInventory, v as useInventoryStats, y as useInventoryTransactions, z as useLiveTracking, K as useModuleSettings, e as useMoveTheWheels, t as useMoveTheWheelsNavigate, ee as useMoveTheWheelsStore, Q as useMyPendingEpodDeliveryJobs, Vt as useNotice, o as useOrder, P as useOrderAnalytics, s as useOrderStats, B as useOrderTracking, c as useOrders, F as usePerformanceAnalytics, b as useProduct, x as useProductStockLevels, S as useProducts, W as useReports, I as useRevenueAnalytics, r as useRoute, i as useRouteStats, a as useRoutes, te as useSandboxAssistantTransport, C as useStockActions, n as useTr, V as useTracking, H as useTrackingAlerts, m as useVehicle, h as useVehicleDrivers, U as useVehicleTracking, g as useVehicles, w as useWarehouse, T as useWarehouses };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/** The stock line an adjust/transfer acts on (a row of the stock position table). */
|
|
2
|
+
export interface StockLineTarget {
|
|
3
|
+
id: string;
|
|
4
|
+
productName: string;
|
|
5
|
+
sku: string;
|
|
6
|
+
warehouseId: string;
|
|
7
|
+
warehouseName: string;
|
|
8
|
+
onHand: number;
|
|
9
|
+
available: number;
|
|
10
|
+
}
|
|
11
|
+
interface DialogBaseProps {
|
|
12
|
+
open: boolean;
|
|
13
|
+
onOpenChange: (open: boolean) => void;
|
|
14
|
+
/** Called after a successful write with a short human-readable summary. */
|
|
15
|
+
onDone: (message: string) => void;
|
|
16
|
+
}
|
|
17
|
+
export declare function ReceiveStockDialog({ open, onOpenChange, onDone }: DialogBaseProps): import("react").JSX.Element;
|
|
18
|
+
export declare function AdjustStockDialog({ line, open, onOpenChange, onDone, }: DialogBaseProps & {
|
|
19
|
+
line: StockLineTarget | null;
|
|
20
|
+
}): import("react").JSX.Element;
|
|
21
|
+
export declare function TransferStockDialog({ line, open, onOpenChange, onDone, }: DialogBaseProps & {
|
|
22
|
+
line: StockLineTarget | null;
|
|
23
|
+
}): import("react").JSX.Element;
|
|
24
|
+
export {};
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
export { useTr } from '../shared/hooks/useTr';
|
|
7
7
|
export { useOrders, useOrder, useOrderStats } from './useOrders';
|
|
8
8
|
export { useFleet, useVehicles, useVehicle, useVehicleDrivers, useDrivers, useDriver, useDriverStatusCounts, useFleetStats, type DriverStatusCounts, } from './useFleet';
|
|
9
|
-
export { useInventory, useProducts, useProduct, useProductStockLevels, useWarehouses, useWarehouse, useInventoryStats, useInventoryTransactions, type InventoryStats, type InventoryTransaction, type InventoryTransactionType, type ProductStockLevel, } from './useInventory';
|
|
9
|
+
export { useInventory, useProducts, useProduct, useProductStockLevels, useWarehouses, useWarehouse, useInventoryStats, useInventoryTransactions, useStockActions, type InventoryStats, type InventoryTransaction, type InventoryTransactionType, type ProductStockLevel, type ReceiveStockInput, type TransferStockInput, } from './useInventory';
|
|
10
10
|
export { useCustomers, useCustomer, useCustomerStats } from './useCustomers';
|
|
11
11
|
export { useRoutes, useRoute, useRouteStats } from './useRoutes';
|
|
12
12
|
export { useAnalytics, useDashboardMetrics, useRevenueAnalytics, useOrderAnalytics, useFleetAnalytics, usePerformanceAnalytics, useFinanceMetrics, type FinanceMetrics, useEmissionsSummary, type EmissionsSummary, } from './useAnalytics';
|
|
@@ -64,6 +64,7 @@ interface UseFleetResult {
|
|
|
64
64
|
updateVehicle: (id: string, input: CreateVehicleInput) => Promise<Vehicle>;
|
|
65
65
|
updateDriver: (id: string, input: UpdateDriverInput) => Promise<Driver>;
|
|
66
66
|
deleteVehicle: (id: string) => Promise<void>;
|
|
67
|
+
deleteDriver: (id: string) => Promise<void>;
|
|
67
68
|
}
|
|
68
69
|
export interface ApiVehicle {
|
|
69
70
|
id: string;
|
|
@@ -97,8 +97,10 @@ export declare function useWarehouses(options?: UseWarehousesOptions): {
|
|
|
97
97
|
totalWarehouses: number;
|
|
98
98
|
hasMore: boolean;
|
|
99
99
|
isLoading: boolean;
|
|
100
|
+
isLoadingMore: boolean;
|
|
100
101
|
error: Error | null;
|
|
101
102
|
refetch: () => undefined;
|
|
103
|
+
loadMore: () => Promise<void>;
|
|
102
104
|
};
|
|
103
105
|
export declare function useWarehouseStats(): {
|
|
104
106
|
stats: {
|
|
@@ -142,6 +144,7 @@ export declare function useInventoryStats(): {
|
|
|
142
144
|
stats: InventoryStats;
|
|
143
145
|
isLoading: boolean;
|
|
144
146
|
error: Error | null;
|
|
147
|
+
refetch: () => void;
|
|
145
148
|
};
|
|
146
149
|
export interface ProductStockLevel {
|
|
147
150
|
inventoryItemId: string;
|
|
@@ -194,4 +197,31 @@ export declare function useInventoryTransactions(options?: UseInventoryTransacti
|
|
|
194
197
|
error: Error | null;
|
|
195
198
|
refetch: () => void;
|
|
196
199
|
};
|
|
200
|
+
export interface ReceiveStockInput {
|
|
201
|
+
productId: string;
|
|
202
|
+
warehouseId: string;
|
|
203
|
+
/** Whole units received; must be > 0. */
|
|
204
|
+
quantity: number;
|
|
205
|
+
/** Only applied when the receipt creates a new stock line. */
|
|
206
|
+
reorderPoint?: number | null;
|
|
207
|
+
}
|
|
208
|
+
export interface TransferStockInput {
|
|
209
|
+
sourceInventoryId: string;
|
|
210
|
+
destinationWarehouseId: string;
|
|
211
|
+
/** Whole units to move out of the source line's available stock; must be > 0. */
|
|
212
|
+
quantity: number;
|
|
213
|
+
}
|
|
214
|
+
/**
|
|
215
|
+
* Stock movements that do not depend on the list currently on screen: every
|
|
216
|
+
* write re-reads the line first, so a stale table row can never overwrite
|
|
217
|
+
* someone else's change (the service also rejects a mid-flight change).
|
|
218
|
+
*/
|
|
219
|
+
export declare function useStockActions(): {
|
|
220
|
+
receiveStock: (input: ReceiveStockInput) => Promise<Inventory>;
|
|
221
|
+
adjustStock: (inventoryId: string, change: number) => Promise<Inventory>;
|
|
222
|
+
transferStock: (input: TransferStockInput) => Promise<{
|
|
223
|
+
source: Inventory;
|
|
224
|
+
destination: Inventory;
|
|
225
|
+
}>;
|
|
226
|
+
};
|
|
197
227
|
export {};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { createLucideIcon as e } from "../createLucideIcon.js";
|
|
2
|
+
//#region node_modules/lucide-react/dist/esm/icons/package-plus.js
|
|
3
|
+
var t = e("PackagePlus", [
|
|
4
|
+
["path", {
|
|
5
|
+
d: "M16 16h6",
|
|
6
|
+
key: "100bgy"
|
|
7
|
+
}],
|
|
8
|
+
["path", {
|
|
9
|
+
d: "M19 13v6",
|
|
10
|
+
key: "85cyf1"
|
|
11
|
+
}],
|
|
12
|
+
["path", {
|
|
13
|
+
d: "M21 10V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l2-1.14",
|
|
14
|
+
key: "e7tb2h"
|
|
15
|
+
}],
|
|
16
|
+
["path", {
|
|
17
|
+
d: "m7.5 4.27 9 5.15",
|
|
18
|
+
key: "1c824w"
|
|
19
|
+
}],
|
|
20
|
+
["polyline", {
|
|
21
|
+
points: "3.29 7 12 12 20.71 7",
|
|
22
|
+
key: "ousv84"
|
|
23
|
+
}],
|
|
24
|
+
["line", {
|
|
25
|
+
x1: "12",
|
|
26
|
+
x2: "12",
|
|
27
|
+
y1: "22",
|
|
28
|
+
y2: "12",
|
|
29
|
+
key: "a4e8g8"
|
|
30
|
+
}]
|
|
31
|
+
]);
|
|
32
|
+
//#endregion
|
|
33
|
+
export { t as PackagePlus };
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { createLucideIcon as e } from "../createLucideIcon.js";
|
|
2
|
+
//#region node_modules/lucide-react/dist/esm/icons/sliders-horizontal.js
|
|
3
|
+
var t = e("SlidersHorizontal", [
|
|
4
|
+
["line", {
|
|
5
|
+
x1: "21",
|
|
6
|
+
x2: "14",
|
|
7
|
+
y1: "4",
|
|
8
|
+
y2: "4",
|
|
9
|
+
key: "obuewd"
|
|
10
|
+
}],
|
|
11
|
+
["line", {
|
|
12
|
+
x1: "10",
|
|
13
|
+
x2: "3",
|
|
14
|
+
y1: "4",
|
|
15
|
+
y2: "4",
|
|
16
|
+
key: "1q6298"
|
|
17
|
+
}],
|
|
18
|
+
["line", {
|
|
19
|
+
x1: "21",
|
|
20
|
+
x2: "12",
|
|
21
|
+
y1: "12",
|
|
22
|
+
y2: "12",
|
|
23
|
+
key: "1iu8h1"
|
|
24
|
+
}],
|
|
25
|
+
["line", {
|
|
26
|
+
x1: "8",
|
|
27
|
+
x2: "3",
|
|
28
|
+
y1: "12",
|
|
29
|
+
y2: "12",
|
|
30
|
+
key: "ntss68"
|
|
31
|
+
}],
|
|
32
|
+
["line", {
|
|
33
|
+
x1: "21",
|
|
34
|
+
x2: "16",
|
|
35
|
+
y1: "20",
|
|
36
|
+
y2: "20",
|
|
37
|
+
key: "14d8ph"
|
|
38
|
+
}],
|
|
39
|
+
["line", {
|
|
40
|
+
x1: "12",
|
|
41
|
+
x2: "3",
|
|
42
|
+
y1: "20",
|
|
43
|
+
y2: "20",
|
|
44
|
+
key: "m0wm8r"
|
|
45
|
+
}],
|
|
46
|
+
["line", {
|
|
47
|
+
x1: "14",
|
|
48
|
+
x2: "14",
|
|
49
|
+
y1: "2",
|
|
50
|
+
y2: "6",
|
|
51
|
+
key: "14e1ph"
|
|
52
|
+
}],
|
|
53
|
+
["line", {
|
|
54
|
+
x1: "8",
|
|
55
|
+
x2: "8",
|
|
56
|
+
y1: "10",
|
|
57
|
+
y2: "14",
|
|
58
|
+
key: "1i6ji0"
|
|
59
|
+
}],
|
|
60
|
+
["line", {
|
|
61
|
+
x1: "16",
|
|
62
|
+
x2: "16",
|
|
63
|
+
y1: "18",
|
|
64
|
+
y2: "22",
|
|
65
|
+
key: "1lctlv"
|
|
66
|
+
}]
|
|
67
|
+
]);
|
|
68
|
+
//#endregion
|
|
69
|
+
export { t as SlidersHorizontal };
|