@burdenoff/microfe-movethewheels 2026.625.1 → 2026.626.2

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.
Files changed (80) hide show
  1. package/dist/{AIAssistantPage-CNyoKtID.js → AIAssistantPage-AvsMbunM.js} +35 -29
  2. package/dist/{AnalyticsPage-Ck615ox7.js → AnalyticsPage-CCLfHgQZ.js} +36 -25
  3. package/dist/CreateOrderPage-CjlnEtk3.js +510 -0
  4. package/dist/CustomerDetailsPage-I6cdDHUi.js +265 -0
  5. package/dist/CustomersPage-CGGfD4ki.js +163 -0
  6. package/dist/{DashboardPage-DTmyuC11.js → DashboardPage-D2HRqwg9.js} +93 -89
  7. package/dist/DataTable-CD9ZhpLB.js +249 -0
  8. package/dist/DriverDetailsPage-rg_pGNuP.js +330 -0
  9. package/dist/DriversPage-DKiynISH.js +167 -0
  10. package/dist/FinancePage-Vg8WPs38.js +158 -0
  11. package/dist/{FleetPage-DCfOmBa2.js → FleetPage-DddXt8r8.js} +109 -71
  12. package/dist/ImportExportPage-BW6qO3kc.js +248 -0
  13. package/dist/{InventoryPage-BW0QXWuf.js → InventoryPage-rMGuaJN-.js} +74 -70
  14. package/dist/LiveTrackingPage-DQ1q4Id3.js +375 -0
  15. package/dist/MarketplacePage-DKrXAv62.js +219 -0
  16. package/dist/OrderDetailsPage-CFASgsYX.js +431 -0
  17. package/dist/OrdersListPage-BHeT8S5o.js +309 -0
  18. package/dist/ProductDetailsPage-CFGcbaHo.js +195 -0
  19. package/dist/ProductsPage--xEpbQ8A.js +171 -0
  20. package/dist/{ReportsPage-Df3hciPy.js → ReportsPage-Bb7_90rK.js} +53 -45
  21. package/dist/RouteDetailsPage-CVtDVb1N.js +282 -0
  22. package/dist/RoutesPage-s57PtgcQ.js +163 -0
  23. package/dist/SettingsPage-BYNCBOpN.js +298 -0
  24. package/dist/{TrackingPage-CU0Vk4mx.js → TrackingPage-CcRc_dva.js} +77 -72
  25. package/dist/VehicleDetailsPage-3YDMPsPs.js +220 -0
  26. package/dist/VehiclesPage-UlxPWP9K.js +167 -0
  27. package/dist/WarehouseDetailsPage-Db7KeN-d.js +238 -0
  28. package/dist/WarehousesPage-CuTO-OPp.js +164 -0
  29. package/dist/index.js +2 -2
  30. package/package.json +2 -2
  31. package/src/movethewheels/components/DataTable.tsx +37 -2
  32. package/src/movethewheels/components/MetricCard.tsx +3 -1
  33. package/src/movethewheels/pages/AIAssistantPage.tsx +11 -3
  34. package/src/movethewheels/pages/AnalyticsPage.tsx +31 -25
  35. package/src/movethewheels/pages/CreateOrderPage.tsx +56 -17
  36. package/src/movethewheels/pages/CustomerDetailsPage.tsx +63 -38
  37. package/src/movethewheels/pages/CustomersPage.tsx +40 -2
  38. package/src/movethewheels/pages/DashboardPage.tsx +8 -1
  39. package/src/movethewheels/pages/DriverDetailsPage.tsx +57 -26
  40. package/src/movethewheels/pages/DriversPage.tsx +37 -1
  41. package/src/movethewheels/pages/FinancePage.tsx +45 -41
  42. package/src/movethewheels/pages/FleetPage.tsx +68 -25
  43. package/src/movethewheels/pages/ImportExportPage.tsx +46 -29
  44. package/src/movethewheels/pages/InventoryPage.tsx +20 -23
  45. package/src/movethewheels/pages/LiveTrackingPage.tsx +58 -20
  46. package/src/movethewheels/pages/MarketplacePage.tsx +37 -3
  47. package/src/movethewheels/pages/OrderDetailsPage.tsx +74 -46
  48. package/src/movethewheels/pages/OrdersListPage.tsx +62 -1
  49. package/src/movethewheels/pages/ProductDetailsPage.tsx +36 -11
  50. package/src/movethewheels/pages/ProductsPage.tsx +33 -1
  51. package/src/movethewheels/pages/ReportsPage.tsx +23 -19
  52. package/src/movethewheels/pages/RouteDetailsPage.tsx +71 -31
  53. package/src/movethewheels/pages/RoutesPage.tsx +41 -5
  54. package/src/movethewheels/pages/SettingsPage.tsx +68 -26
  55. package/src/movethewheels/pages/TrackingPage.tsx +50 -47
  56. package/src/movethewheels/pages/VehicleDetailsPage.tsx +49 -24
  57. package/src/movethewheels/pages/VehiclesPage.tsx +33 -1
  58. package/src/movethewheels/pages/WarehouseDetailsPage.tsx +55 -30
  59. package/src/movethewheels/pages/WarehousesPage.tsx +42 -4
  60. package/dist/CreateOrderPage-C9Vb57Yn.js +0 -471
  61. package/dist/CustomerDetailsPage-BVkHRZvi.js +0 -239
  62. package/dist/CustomersPage-DhQg-6h_.js +0 -118
  63. package/dist/DataTable-CfWvFw5B.js +0 -239
  64. package/dist/DriverDetailsPage-DaaCQ-2O.js +0 -297
  65. package/dist/DriversPage-D0RMBB_t.js +0 -129
  66. package/dist/FinancePage-BUXqW1IM.js +0 -154
  67. package/dist/ImportExportPage-BM1BoRcE.js +0 -232
  68. package/dist/LiveTrackingPage-DqcGXdkw.js +0 -332
  69. package/dist/MarketplacePage-DFqsxNYU.js +0 -192
  70. package/dist/OrderDetailsPage-Dx1m3cVA.js +0 -398
  71. package/dist/OrdersListPage-DHYBGrWf.js +0 -256
  72. package/dist/ProductDetailsPage-DOXO90kb.js +0 -168
  73. package/dist/ProductsPage-RLMTwWN0.js +0 -133
  74. package/dist/RouteDetailsPage-xzFDeR-X.js +0 -240
  75. package/dist/RoutesPage-DDFy1QVi.js +0 -118
  76. package/dist/SettingsPage-JH_-UPbf.js +0 -247
  77. package/dist/VehicleDetailsPage-P4xDttKw.js +0 -194
  78. package/dist/VehiclesPage-tJZ64QKV.js +0 -129
  79. package/dist/WarehouseDetailsPage-Bt_w2Yf7.js +0 -215
  80. package/dist/WarehousesPage-HsPpEFeG.js +0 -126
@@ -1,194 +0,0 @@
1
- import { M as e, d as t, f as n, g as r, h as i, i as a, l as o, n as s, r as c, u as l } from "./PageLayout-D3N8MCTm.js";
2
- import { t as u } from "./arrow-left-CBpZKkpq.js";
3
- import { t as d } from "./file-text-C8Uioy11.js";
4
- import { n as f, t as p } from "./wrench-CmxY1n4I.js";
5
- import { t as m } from "./map-pin-BSaf5IDL.js";
6
- import { t as h } from "./square-pen-hLIbFQFV.js";
7
- import { t as g } from "./truck-CtDjNFbi.js";
8
- import { r as _ } from "./graphqlClient-CdJyR_ed.js";
9
- import { a as v } from "./useFleet-BdETplNE.js";
10
- import { a as y, r as b } from "./StatusBadge-CijYQXtb.js";
11
- import { r as x } from "./formatters-_vJlC-47.js";
12
- import { t as S } from "./navigation-BgnOfsVd.js";
13
- import { useParams as C } from "react-router-dom";
14
- import { jsx as w, jsxs as T } from "react/jsx-runtime";
15
- //#region src/movethewheels/pages/VehicleDetailsPage.tsx
16
- function E() {
17
- let { vehicleId: E } = C(), { basePath: D, navigate: O } = _(), { vehicle: k, isLoading: A, error: j, refetch: M } = v(E);
18
- return A ? /* @__PURE__ */ w(c, { message: "Loading vehicle details..." }) : j || !k ? /* @__PURE__ */ w(s, {
19
- title: "Vehicle not found",
20
- onRetry: M
21
- }) : /* @__PURE__ */ w(a, {
22
- title: k.vehicleNumber,
23
- subtitle: `${k.make} ${k.model} (${k.year})`,
24
- icon: /* @__PURE__ */ w(g, { size: 24 }),
25
- headerActions: /* @__PURE__ */ T("div", {
26
- className: "flex gap-2",
27
- children: [/* @__PURE__ */ T(l, {
28
- variant: "outline",
29
- onClick: () => O?.(S(D, "fleet/vehicles")),
30
- children: [/* @__PURE__ */ w(u, { size: 16 }), " Back"]
31
- }), /* @__PURE__ */ T(l, { children: [/* @__PURE__ */ w(h, { size: 16 }), " Edit"] })]
32
- }),
33
- headerContent: /* @__PURE__ */ T("div", {
34
- className: "flex gap-2",
35
- children: [/* @__PURE__ */ w(b, {
36
- status: k.status,
37
- type: "vehicle"
38
- }), /* @__PURE__ */ w(y, { type: k.type })]
39
- }),
40
- children: /* @__PURE__ */ T("div", {
41
- className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
42
- children: [/* @__PURE__ */ T("div", {
43
- className: "lg:col-span-2 space-y-6",
44
- children: [
45
- /* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ w(r, { children: "Vehicle Information" }) }), /* @__PURE__ */ w(n, { children: /* @__PURE__ */ T("div", {
46
- className: "grid grid-cols-2 md:grid-cols-4 gap-6",
47
- children: [
48
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
49
- className: "text-sm text-text-secondary",
50
- children: "Type"
51
- }), /* @__PURE__ */ w("p", {
52
- className: "font-medium capitalize",
53
- children: k.type
54
- })] }),
55
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
56
- className: "text-sm text-text-secondary",
57
- children: "Make"
58
- }), /* @__PURE__ */ w("p", {
59
- className: "font-medium",
60
- children: k.make
61
- })] }),
62
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
63
- className: "text-sm text-text-secondary",
64
- children: "Model"
65
- }), /* @__PURE__ */ w("p", {
66
- className: "font-medium",
67
- children: k.model
68
- })] }),
69
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
70
- className: "text-sm text-text-secondary",
71
- children: "Year"
72
- }), /* @__PURE__ */ w("p", {
73
- className: "font-medium",
74
- children: k.year
75
- })] })
76
- ]
77
- }) })] }),
78
- /* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ w(r, { children: "Capacity" }) }), /* @__PURE__ */ w(n, { children: /* @__PURE__ */ T("div", {
79
- className: "grid grid-cols-3 gap-6",
80
- children: [
81
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
82
- className: "text-sm text-text-secondary",
83
- children: "Weight"
84
- }), /* @__PURE__ */ T("p", {
85
- className: "text-2xl font-bold",
86
- children: [k.capacity.weight, /* @__PURE__ */ w("span", {
87
- className: "text-sm font-normal",
88
- children: " kg"
89
- })]
90
- })] }),
91
- /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
92
- className: "text-sm text-text-secondary",
93
- children: "Volume"
94
- }), /* @__PURE__ */ T("p", {
95
- className: "text-2xl font-bold",
96
- children: [k.capacity.volume, /* @__PURE__ */ w("span", {
97
- className: "text-sm font-normal",
98
- children: " m³"
99
- })]
100
- })] }),
101
- k.capacity.pallets && /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
102
- className: "text-sm text-text-secondary",
103
- children: "Pallets"
104
- }), /* @__PURE__ */ w("p", {
105
- className: "text-2xl font-bold",
106
- children: k.capacity.pallets
107
- })] })
108
- ]
109
- }) })] }),
110
- /* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ T(r, {
111
- className: "flex items-center gap-2",
112
- children: [/* @__PURE__ */ w(d, { size: 18 }), " Documents"]
113
- }) }), /* @__PURE__ */ w(n, { children: k.documents.length > 0 ? /* @__PURE__ */ w("div", {
114
- className: "space-y-3",
115
- children: k.documents.map((e) => /* @__PURE__ */ T("div", {
116
- className: "flex items-center justify-between p-3 border rounded-lg",
117
- children: [/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
118
- className: "font-medium capitalize",
119
- children: e.type.replace("_", " ")
120
- }), /* @__PURE__ */ T("p", {
121
- className: "text-sm text-text-secondary",
122
- children: ["Expires: ", x(e.expiryDate)]
123
- })] }), /* @__PURE__ */ w(o, {
124
- variant: e.verified ? "default" : "secondary",
125
- children: e.verified ? "Verified" : "Pending"
126
- })]
127
- }, e.id))
128
- }) : /* @__PURE__ */ w("p", {
129
- className: "text-text-secondary text-center py-4",
130
- children: "No documents uploaded"
131
- }) })] })
132
- ]
133
- }), /* @__PURE__ */ T("div", {
134
- className: "space-y-6",
135
- children: [
136
- /* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ T(r, {
137
- className: "flex items-center gap-2",
138
- children: [/* @__PURE__ */ w(f, { size: 18 }), " Fuel & Mileage"]
139
- }) }), /* @__PURE__ */ T(n, {
140
- className: "space-y-4",
141
- children: [k.fuelLevel !== void 0 && /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ T("div", {
142
- className: "flex justify-between text-sm mb-2",
143
- children: [/* @__PURE__ */ w("span", { children: "Fuel Level" }), /* @__PURE__ */ T("span", { children: [k.fuelLevel, "%"] })]
144
- }), /* @__PURE__ */ w(e, { value: k.fuelLevel })] }), k.mileage !== void 0 && /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
145
- className: "text-sm text-text-secondary",
146
- children: "Total Mileage"
147
- }), /* @__PURE__ */ T("p", {
148
- className: "text-2xl font-bold",
149
- children: [
150
- k.mileage.toLocaleString(),
151
- " ",
152
- /* @__PURE__ */ w("span", {
153
- className: "text-sm font-normal",
154
- children: "miles"
155
- })
156
- ]
157
- })] })]
158
- })] }),
159
- /* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ T(r, {
160
- className: "flex items-center gap-2",
161
- children: [/* @__PURE__ */ w(p, { size: 18 }), " Maintenance"]
162
- }) }), /* @__PURE__ */ T(n, {
163
- className: "space-y-3",
164
- children: [/* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
165
- className: "text-sm text-text-secondary",
166
- children: "Last Maintenance"
167
- }), /* @__PURE__ */ w("p", {
168
- className: "font-medium",
169
- children: k.lastMaintenance ? x(k.lastMaintenance) : "N/A"
170
- })] }), /* @__PURE__ */ T("div", { children: [/* @__PURE__ */ w("p", {
171
- className: "text-sm text-text-secondary",
172
- children: "Next Scheduled"
173
- }), /* @__PURE__ */ w("p", {
174
- className: "font-medium",
175
- children: k.nextMaintenance ? x(k.nextMaintenance) : "N/A"
176
- })] })]
177
- })] }),
178
- k.currentLocation && /* @__PURE__ */ T(t, { children: [/* @__PURE__ */ w(i, { children: /* @__PURE__ */ T(r, {
179
- className: "flex items-center gap-2",
180
- children: [/* @__PURE__ */ w(m, { size: 18 }), " Current Location"]
181
- }) }), /* @__PURE__ */ T(n, { children: [/* @__PURE__ */ w("p", {
182
- className: "text-sm",
183
- children: k.currentLocation.address || "Location updating..."
184
- }), /* @__PURE__ */ T("p", {
185
- className: "text-xs text-text-secondary mt-1",
186
- children: ["Updated ", x(k.currentLocation.timestamp || /* @__PURE__ */ new Date(), "relative")]
187
- })] })] })
188
- ]
189
- })]
190
- })
191
- });
192
- }
193
- //#endregion
194
- export { E as default };
@@ -1,129 +0,0 @@
1
- import { M as e, i as t } from "./PageLayout-D3N8MCTm.js";
2
- import { t as n } from "./DataTable-CfWvFw5B.js";
3
- import { t as r } from "./download-Dpa9vqoG.js";
4
- import { t as i } from "./plus-Dl1rLeJR.js";
5
- import { t as a } from "./refresh-cw-CWfERAit.js";
6
- import { t as o } from "./truck-CtDjNFbi.js";
7
- import { r as s } from "./graphqlClient-CdJyR_ed.js";
8
- import { o as c } from "./useFleet-BdETplNE.js";
9
- import { a as l, r as u } from "./StatusBadge-CijYQXtb.js";
10
- import { t as d } from "./navigation-BgnOfsVd.js";
11
- import { jsx as f, jsxs as p } from "react/jsx-runtime";
12
- import { CTAOverflowMenu as m } from "@burdenoff/fe-libs/ui";
13
- //#region src/movethewheels/pages/VehiclesPage.tsx
14
- function h() {
15
- let { basePath: h, navigate: g } = s(), { vehicles: _, totalVehicles: v, isLoading: y, refetch: b } = c(), x = (e) => {
16
- g && g(d(h, e));
17
- };
18
- return /* @__PURE__ */ f(t, {
19
- title: "Vehicles",
20
- subtitle: `${v} vehicles in fleet`,
21
- icon: /* @__PURE__ */ f(o, { size: 24 }),
22
- headerActions: /* @__PURE__ */ f(m, {
23
- primary: {
24
- label: "Add Vehicle",
25
- icon: /* @__PURE__ */ f(i, { size: 16 }),
26
- onSelect: () => {}
27
- },
28
- actions: [{
29
- label: "Refresh",
30
- icon: /* @__PURE__ */ f(a, { size: 16 }),
31
- onSelect: () => b()
32
- }, {
33
- label: "Export",
34
- icon: /* @__PURE__ */ f(r, { size: 16 }),
35
- onSelect: () => {}
36
- }]
37
- }),
38
- children: /* @__PURE__ */ f(n, {
39
- columns: [
40
- {
41
- id: "vehicleNumber",
42
- header: "Vehicle #",
43
- accessorKey: "vehicleNumber",
44
- sortable: !0,
45
- cell: (e) => /* @__PURE__ */ f("span", {
46
- className: "font-medium",
47
- children: e.vehicleNumber
48
- })
49
- },
50
- {
51
- id: "type",
52
- header: "Type",
53
- accessorKey: "type",
54
- cell: (e) => /* @__PURE__ */ f(l, { type: e.type })
55
- },
56
- {
57
- id: "details",
58
- header: "Vehicle",
59
- cell: (e) => /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("p", {
60
- className: "font-medium",
61
- children: [
62
- e.make,
63
- " ",
64
- e.model
65
- ]
66
- }), /* @__PURE__ */ f("p", {
67
- className: "text-sm text-text-secondary",
68
- children: e.year
69
- })] })
70
- },
71
- {
72
- id: "status",
73
- header: "Status",
74
- accessorKey: "status",
75
- sortable: !0,
76
- cell: (e) => /* @__PURE__ */ f(u, {
77
- status: e.status,
78
- type: "vehicle"
79
- })
80
- },
81
- {
82
- id: "capacity",
83
- header: "Capacity",
84
- cell: (e) => /* @__PURE__ */ p("div", {
85
- className: "text-sm",
86
- children: [/* @__PURE__ */ p("p", { children: [e.capacity.weight, " kg"] }), /* @__PURE__ */ p("p", {
87
- className: "text-text-secondary",
88
- children: [e.capacity.volume, " m³"]
89
- })]
90
- })
91
- },
92
- {
93
- id: "fuel",
94
- header: "Fuel Level",
95
- cell: (t) => t.fuelLevel === void 0 ? "-" : /* @__PURE__ */ p("div", {
96
- className: "flex items-center gap-2",
97
- children: [/* @__PURE__ */ f(e, {
98
- value: t.fuelLevel,
99
- className: "w-16 h-2"
100
- }), /* @__PURE__ */ p("span", {
101
- className: "text-sm",
102
- children: [t.fuelLevel, "%"]
103
- })]
104
- })
105
- },
106
- {
107
- id: "mileage",
108
- header: "Mileage",
109
- accessorKey: "mileage",
110
- sortable: !0,
111
- cell: (e) => e.mileage ? `${e.mileage.toLocaleString()} mi` : "-"
112
- }
113
- ],
114
- data: _,
115
- isLoading: y,
116
- searchable: !0,
117
- searchPlaceholder: "Search vehicles...",
118
- searchFields: [
119
- "vehicleNumber",
120
- "make",
121
- "model"
122
- ],
123
- onRowClick: (e) => x(`fleet/vehicles/${e.id}`),
124
- getRowId: (e) => e.id
125
- })
126
- });
127
- }
128
- //#endregion
129
- export { h as default };
@@ -1,215 +0,0 @@
1
- import { M as e, d as t, f as n, g as r, h as i, i as a, l as o, n as s, r as c, u as l } from "./PageLayout-D3N8MCTm.js";
2
- import { t as u } from "./arrow-left-CBpZKkpq.js";
3
- import { t as d } from "./box-CAaiElsb.js";
4
- import { t as f } from "./clock-BjkdnddD.js";
5
- import { t as p } from "./map-pin-BSaf5IDL.js";
6
- import { t as m } from "./square-pen-hLIbFQFV.js";
7
- import { t as h } from "./users-g2N0eL-Z.js";
8
- import { t as g } from "./warehouse-D3WWDeTX.js";
9
- import { r as _ } from "./graphqlClient-CdJyR_ed.js";
10
- import { a as v } from "./useInventory-Dwn18FPz.js";
11
- import { t as y } from "./formatters-_vJlC-47.js";
12
- import { t as b } from "./navigation-BgnOfsVd.js";
13
- import { useParams as x } from "react-router-dom";
14
- import { jsx as S, jsxs as C } from "react/jsx-runtime";
15
- //#region src/movethewheels/pages/WarehouseDetailsPage.tsx
16
- function w() {
17
- let { warehouseId: w } = x(), { basePath: T, navigate: E } = _(), { warehouse: D, isLoading: O, error: k, refetch: A } = v(w), j = () => E?.(b(T, "inventory/warehouses"));
18
- if (O) return /* @__PURE__ */ S(c, { message: "Loading warehouse details..." });
19
- if (k || !D) return /* @__PURE__ */ S(s, {
20
- title: "Warehouse not found",
21
- onRetry: A
22
- });
23
- let M = D.capacity.usedSpace / D.capacity.totalSpace * 100;
24
- return /* @__PURE__ */ S(a, {
25
- title: D.name,
26
- subtitle: `Code: ${D.code}`,
27
- icon: /* @__PURE__ */ S(g, { size: 24 }),
28
- headerActions: /* @__PURE__ */ C("div", {
29
- className: "flex gap-2",
30
- children: [/* @__PURE__ */ C(l, {
31
- variant: "outline",
32
- onClick: j,
33
- children: [/* @__PURE__ */ S(u, { size: 16 }), " Back"]
34
- }), /* @__PURE__ */ C(l, { children: [/* @__PURE__ */ S(m, { size: 16 }), " Edit"] })]
35
- }),
36
- headerContent: /* @__PURE__ */ C("div", {
37
- className: "flex gap-2",
38
- children: [/* @__PURE__ */ S(o, {
39
- variant: D.isActive ? "default" : "secondary",
40
- children: D.isActive ? "Active" : "Inactive"
41
- }), /* @__PURE__ */ S(o, {
42
- variant: "outline",
43
- className: "capitalize",
44
- children: D.type.replace("_", " ")
45
- })]
46
- }),
47
- children: /* @__PURE__ */ C("div", {
48
- className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
49
- children: [/* @__PURE__ */ C("div", {
50
- className: "lg:col-span-2 space-y-6",
51
- children: [
52
- /* @__PURE__ */ C(t, { children: [/* @__PURE__ */ S(i, { children: /* @__PURE__ */ C(r, {
53
- className: "flex items-center gap-2",
54
- children: [/* @__PURE__ */ S(d, { size: 18 }), " Capacity"]
55
- }) }), /* @__PURE__ */ S(n, { children: /* @__PURE__ */ C("div", {
56
- className: "space-y-4",
57
- children: [/* @__PURE__ */ C("div", { children: [
58
- /* @__PURE__ */ C("div", {
59
- className: "flex justify-between text-sm mb-2",
60
- children: [/* @__PURE__ */ S("span", { children: "Space Utilization" }), /* @__PURE__ */ C("span", { children: [M.toFixed(0), "%"] })]
61
- }),
62
- /* @__PURE__ */ S(e, { value: M }),
63
- /* @__PURE__ */ C("p", {
64
- className: "text-sm text-text-secondary mt-1",
65
- children: [
66
- D.capacity.usedSpace.toLocaleString(),
67
- " /",
68
- " ",
69
- D.capacity.totalSpace.toLocaleString(),
70
- " sq ft"
71
- ]
72
- })
73
- ] }), /* @__PURE__ */ S("div", {
74
- className: "grid grid-cols-2 gap-4",
75
- children: /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("p", {
76
- className: "text-sm text-text-secondary",
77
- children: "Pallets Used"
78
- }), /* @__PURE__ */ C("p", {
79
- className: "text-2xl font-bold",
80
- children: [D.capacity.usedPallets, /* @__PURE__ */ C("span", {
81
- className: "text-sm font-normal text-text-secondary",
82
- children: [
83
- " ",
84
- "/ ",
85
- D.capacity.totalPallets
86
- ]
87
- })]
88
- })] })
89
- })]
90
- }) })] }),
91
- /* @__PURE__ */ C(t, { children: [/* @__PURE__ */ S(i, { children: /* @__PURE__ */ C(r, { children: [
92
- "Zones (",
93
- D.zones.length,
94
- ")"
95
- ] }) }), /* @__PURE__ */ S(n, { children: /* @__PURE__ */ S("div", {
96
- className: "space-y-3",
97
- children: D.zones.map((t) => /* @__PURE__ */ C("div", {
98
- className: "flex items-center justify-between p-3 border rounded-lg",
99
- children: [/* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("p", {
100
- className: "font-medium",
101
- children: t.name
102
- }), /* @__PURE__ */ C("p", {
103
- className: "text-sm text-text-secondary capitalize",
104
- children: [
105
- t.type,
106
- " - ",
107
- t.location
108
- ]
109
- })] }), /* @__PURE__ */ C("div", {
110
- className: "text-right",
111
- children: [/* @__PURE__ */ S(e, {
112
- value: t.currentOccupancy / t.capacity * 100,
113
- className: "w-24 h-2"
114
- }), /* @__PURE__ */ C("p", {
115
- className: "text-sm text-text-secondary",
116
- children: [
117
- t.currentOccupancy,
118
- " / ",
119
- t.capacity
120
- ]
121
- })]
122
- })]
123
- }, t.id))
124
- }) })] }),
125
- /* @__PURE__ */ C(t, { children: [/* @__PURE__ */ S(i, { children: /* @__PURE__ */ C(r, {
126
- className: "flex items-center gap-2",
127
- children: [/* @__PURE__ */ S(f, { size: 18 }), " Operating Hours"]
128
- }) }), /* @__PURE__ */ S(n, { children: /* @__PURE__ */ S("div", {
129
- className: "grid grid-cols-2 md:grid-cols-4 gap-4",
130
- children: Object.entries(D.operatingHours).map(([e, t]) => /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("p", {
131
- className: "text-sm font-medium",
132
- children: e
133
- }), /* @__PURE__ */ S("p", {
134
- className: "text-sm text-text-secondary",
135
- children: t ? `${t.open} - ${t.close}` : "Closed"
136
- })] }, e))
137
- }) })] })
138
- ]
139
- }), /* @__PURE__ */ C("div", {
140
- className: "space-y-6",
141
- children: [
142
- /* @__PURE__ */ C(t, { children: [/* @__PURE__ */ S(i, { children: /* @__PURE__ */ C(r, {
143
- className: "flex items-center gap-2",
144
- children: [/* @__PURE__ */ S(p, { size: 18 }), " Location"]
145
- }) }), /* @__PURE__ */ S(n, { children: /* @__PURE__ */ S("p", {
146
- className: "text-sm",
147
- children: y(D.address)
148
- }) })] }),
149
- /* @__PURE__ */ C(t, { children: [/* @__PURE__ */ S(i, { children: /* @__PURE__ */ S(r, { children: "Metrics" }) }), /* @__PURE__ */ C(n, {
150
- className: "space-y-3",
151
- children: [
152
- /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("p", {
153
- className: "text-sm text-text-secondary",
154
- children: "Throughput"
155
- }), /* @__PURE__ */ C("p", {
156
- className: "text-2xl font-bold",
157
- children: [D.metrics.throughput, /* @__PURE__ */ S("span", {
158
- className: "text-sm font-normal",
159
- children: " orders/day"
160
- })]
161
- })] }),
162
- /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("p", {
163
- className: "text-sm text-text-secondary",
164
- children: "Accuracy"
165
- }), /* @__PURE__ */ C("p", {
166
- className: "text-2xl font-bold",
167
- children: [D.metrics.accuracy, "%"]
168
- })] }),
169
- /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("p", {
170
- className: "text-sm text-text-secondary",
171
- children: "Productivity"
172
- }), /* @__PURE__ */ C("p", {
173
- className: "text-2xl font-bold",
174
- children: [D.metrics.productivity, "%"]
175
- })] }),
176
- /* @__PURE__ */ C("div", { children: [/* @__PURE__ */ S("p", {
177
- className: "text-sm text-text-secondary",
178
- children: "Orders Fulfilled"
179
- }), /* @__PURE__ */ S("p", {
180
- className: "text-2xl font-bold",
181
- children: D.metrics.ordersFulfilled.toLocaleString()
182
- })] })
183
- ]
184
- })] }),
185
- /* @__PURE__ */ C(t, { children: [/* @__PURE__ */ S(i, { children: /* @__PURE__ */ C(r, {
186
- className: "flex items-center gap-2",
187
- children: [
188
- /* @__PURE__ */ S(h, { size: 18 }),
189
- " Staff (",
190
- D.staff.length,
191
- ")"
192
- ]
193
- }) }), /* @__PURE__ */ S(n, { children: D.staff.length > 0 ? /* @__PURE__ */ S("div", {
194
- className: "space-y-2",
195
- children: D.staff.map((e, t) => /* @__PURE__ */ C("div", {
196
- className: "flex items-center justify-between p-2 border rounded",
197
- children: [/* @__PURE__ */ S("span", {
198
- className: "text-sm capitalize",
199
- children: e.role
200
- }), /* @__PURE__ */ S(o, {
201
- variant: "outline",
202
- children: e.shift
203
- })]
204
- }, t))
205
- }) : /* @__PURE__ */ S("p", {
206
- className: "text-text-secondary",
207
- children: "No staff assigned"
208
- }) })] })
209
- ]
210
- })]
211
- })
212
- });
213
- }
214
- //#endregion
215
- export { w as default };
@@ -1,126 +0,0 @@
1
- import { M as e, i as t, l as n } from "./PageLayout-D3N8MCTm.js";
2
- import { t as r } from "./DataTable-CfWvFw5B.js";
3
- import { t as i } from "./plus-Dl1rLeJR.js";
4
- import { t as a } from "./refresh-cw-CWfERAit.js";
5
- import { t as o } from "./warehouse-D3WWDeTX.js";
6
- import { r as s } from "./graphqlClient-CdJyR_ed.js";
7
- import { o as c } from "./useInventory-Dwn18FPz.js";
8
- import { t as l } from "./navigation-BgnOfsVd.js";
9
- import { jsx as u, jsxs as d } from "react/jsx-runtime";
10
- import { CTAOverflowMenu as f } from "@burdenoff/fe-libs/ui";
11
- //#region src/movethewheels/pages/WarehousesPage.tsx
12
- function p() {
13
- let { basePath: p, navigate: m } = s(), { warehouses: h, totalWarehouses: g, isLoading: _, refetch: v } = c(), y = (e) => m?.(l(p, e));
14
- return /* @__PURE__ */ u(t, {
15
- title: "Warehouses",
16
- subtitle: `${g} warehouses`,
17
- icon: /* @__PURE__ */ u(o, { size: 24 }),
18
- headerActions: /* @__PURE__ */ u(f, {
19
- primary: {
20
- label: "Add Warehouse",
21
- icon: /* @__PURE__ */ u(i, { size: 16 }),
22
- onSelect: () => {}
23
- },
24
- actions: [{
25
- label: "Refresh",
26
- icon: /* @__PURE__ */ u(a, { size: 16 }),
27
- onSelect: () => v()
28
- }]
29
- }),
30
- children: /* @__PURE__ */ u(r, {
31
- columns: [
32
- {
33
- id: "name",
34
- header: "Warehouse",
35
- accessorKey: "name",
36
- sortable: !0,
37
- cell: (e) => /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ u("p", {
38
- className: "font-medium",
39
- children: e.name
40
- }), /* @__PURE__ */ u("p", {
41
- className: "text-sm text-text-secondary",
42
- children: e.code
43
- })] })
44
- },
45
- {
46
- id: "location",
47
- header: "Location",
48
- cell: (e) => /* @__PURE__ */ d("div", { children: [/* @__PURE__ */ d("p", { children: [
49
- e.address.city,
50
- ", ",
51
- e.address.state
52
- ] }), /* @__PURE__ */ u("p", {
53
- className: "text-sm text-text-secondary",
54
- children: e.address.country
55
- })] })
56
- },
57
- {
58
- id: "type",
59
- header: "Type",
60
- accessorKey: "type",
61
- cell: (e) => /* @__PURE__ */ u(n, {
62
- variant: "outline",
63
- className: "capitalize",
64
- children: e.type.replace("_", " ")
65
- })
66
- },
67
- {
68
- id: "utilization",
69
- header: "Utilization",
70
- cell: (t) => {
71
- let n = t.capacity.usedSpace / t.capacity.totalSpace * 100;
72
- return /* @__PURE__ */ d("div", {
73
- className: "flex items-center gap-2",
74
- children: [/* @__PURE__ */ u(e, {
75
- value: n,
76
- className: "w-16 h-2"
77
- }), /* @__PURE__ */ d("span", {
78
- className: "text-sm",
79
- children: [n.toFixed(0), "%"]
80
- })]
81
- });
82
- }
83
- },
84
- {
85
- id: "capacity",
86
- header: "Capacity",
87
- cell: (e) => /* @__PURE__ */ d("div", {
88
- className: "text-sm",
89
- children: [/* @__PURE__ */ d("p", { children: [
90
- e.capacity.usedSpace.toLocaleString(),
91
- " / ",
92
- e.capacity.totalSpace.toLocaleString(),
93
- " ",
94
- "sq ft"
95
- ] }), /* @__PURE__ */ d("p", {
96
- className: "text-text-secondary",
97
- children: [
98
- e.capacity.usedPallets,
99
- " / ",
100
- e.capacity.totalPallets,
101
- " pallets"
102
- ]
103
- })]
104
- })
105
- },
106
- {
107
- id: "status",
108
- header: "Status",
109
- cell: (e) => /* @__PURE__ */ u(n, {
110
- variant: e.isActive ? "default" : "secondary",
111
- children: e.isActive ? "Active" : "Inactive"
112
- })
113
- }
114
- ],
115
- data: h,
116
- isLoading: _,
117
- searchable: !0,
118
- searchPlaceholder: "Search warehouses...",
119
- searchFields: ["name", "code"],
120
- onRowClick: (e) => y(`inventory/warehouses/${e.id}`),
121
- getRowId: (e) => e.id
122
- })
123
- });
124
- }
125
- //#endregion
126
- export { p as default };