mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-27 00:52:50 +00:00
fix slip
This commit is contained in:
@@ -44,12 +44,19 @@ interface LastMileJob {
|
||||
// Booking info shown in the Assign / View Detail modals.
|
||||
serviceType: string;
|
||||
weight: string;
|
||||
price: number;
|
||||
originYard: string;
|
||||
contactName: string;
|
||||
contactPhone: string;
|
||||
requestedDate: string;
|
||||
}
|
||||
|
||||
const formatPrice = (amount: number) =>
|
||||
`ETB ${amount.toLocaleString("en-US", {
|
||||
minimumFractionDigits: 2,
|
||||
maximumFractionDigits: 2,
|
||||
})}`;
|
||||
|
||||
const DELIVERY_STATUS_META: Record<
|
||||
DeliveryStatus,
|
||||
{ label: string; color: string }
|
||||
@@ -93,6 +100,7 @@ const PLACEHOLDER_JOBS: LastMileJob[] = [
|
||||
assignedVehicle: null,
|
||||
serviceType: "Door-to-door (Last Mile)",
|
||||
weight: "12.4 t",
|
||||
price: 4500,
|
||||
originYard: "Indode Dry Port",
|
||||
contactName: "Selam Bekele",
|
||||
contactPhone: "+251 911 234 567",
|
||||
@@ -109,6 +117,7 @@ const PLACEHOLDER_JOBS: LastMileJob[] = [
|
||||
assignedVehicle: "Isuzu FVR (3-AA-45821)",
|
||||
serviceType: "Terminal-to-door (Last Mile)",
|
||||
weight: "18.0 t",
|
||||
price: 3200,
|
||||
originYard: "Dire Dawa Terminal",
|
||||
contactName: "Yonas Tadesse",
|
||||
contactPhone: "+251 912 887 010",
|
||||
@@ -125,6 +134,7 @@ const PLACEHOLDER_JOBS: LastMileJob[] = [
|
||||
assignedVehicle: null,
|
||||
serviceType: "Door-to-door (Last Mile)",
|
||||
weight: "24.7 t",
|
||||
price: 6800,
|
||||
originYard: "Mojo Dry Port",
|
||||
contactName: "Hanna Girma",
|
||||
contactPhone: "+251 913 445 221",
|
||||
@@ -177,6 +187,7 @@ const BookingInfo = ({ job }: { job: LastMileJob }) => (
|
||||
<InfoRow label="Destination" value={job.destination} />
|
||||
<InfoRow label="Cargo" value={job.cargo} />
|
||||
<InfoRow label="Weight" value={job.weight} />
|
||||
<InfoRow label="Price" value={formatPrice(job.price)} />
|
||||
<InfoRow label="Contact" value={job.contactName} />
|
||||
<InfoRow label="Phone" value={job.contactPhone} />
|
||||
<InfoRow label="Requested date" value={job.requestedDate} />
|
||||
@@ -193,6 +204,7 @@ const tripSlipRows = (job: LastMileJob): [string, string][] => [
|
||||
["Destination", job.destination],
|
||||
["Cargo", job.cargo],
|
||||
["Weight", job.weight],
|
||||
["Price", formatPrice(job.price)],
|
||||
["Vehicle", job.assignedVehicle ?? "Unassigned"],
|
||||
["Contact", `${job.contactName} · ${job.contactPhone}`],
|
||||
["Requested date", job.requestedDate],
|
||||
@@ -544,6 +556,12 @@ const LastMilePage = () => {
|
||||
meta: { headerClassName, cellClassName },
|
||||
cell: ({ row }) => row.original.cargo,
|
||||
},
|
||||
{
|
||||
id: "price",
|
||||
header: "Price",
|
||||
meta: { headerClassName, cellClassName },
|
||||
cell: ({ row }) => formatPrice(row.original.price),
|
||||
},
|
||||
{
|
||||
id: "vehicle",
|
||||
header: "Vehicle",
|
||||
|
||||
Reference in New Issue
Block a user