The Trip Lifecycle, End to End
The complete guide to a WinTrack trip — from quotation and contract creation through delivery and settlement, with every step and the party responsible for it.
The trip is the central object in WinTrack. Every trip moves through a fixed sequence of stages, and responsibility shifts between parties as it progresses: the Sales Manager, the CEO, the Regional Supervisor, and the Driver. Each stage is stamped with a timestamp for reporting and settlement.
Why the order matters
You cannot skip ahead. For example, a driver cannot start moving until the supervisor approves the pre-loading checklist, and the post-loading checklist cannot be submitted until the supervisor attaches the Bayan al-Naql document.
The stages in detail
Quotation and approvals
Everything starts with a quotation. It is approved by the Sales Manager, then the client, then the CEO. After all three approvals, the quotation becomes a contract.
Contract and routes
Once the contract is approved, routes are added to it. Each route defines the loading point and unloading point, the load type, quantity, and unit price. Trip revenue is later computed from these values — it is never approximated by dividing the contract total.
Asset assignment
The vehicle (truck), trailer, and driver are assigned to the route through asset assignment. The driver must acknowledge equipment handover (the handover document) before proceeding.
Dispatch
The regional supervisor dispatches the trip to the driver. It appears in the driver's mobile app under their assigned trips. The driver can accept or reject it.
The dispatch screen lists only ready drivers (equipped with an active vehicle and valid documents); anyone not meeting the requirements appears disabled with the reason, and the list re-validates automatically before saving so the final step can't fail.
Pre-loading checklist
After acceptance, the driver completes the vehicle-readiness checklist before loading. This stage requires supervisor approval (operations sign-off) before continuing.
Server-side enforcement
Since v0.47 the server rejects any checklist submission that does not have every item checked, any submission containing an item that does not belong to the trip's checklist, and any out-of-order stage transition (e.g. uploading a weight document before reaching the weight station) with a clear bilingual message. Re-submitting after completion is safe — the server treats it as an idempotent replay with no side effects.
Loading and the weight station
The truck is loaded, then passes through the weight station. The driver uploads the weight document through the app.
Attaching the Bayan al-Naql
The supervisor attaches the Bayan document. The post-loading checklist cannot be submitted until this document is attached — it is the mandatory gate to the next stage.
Post-loading checklist
After the Bayan, the driver completes the post-loading checklist (which includes the Bayan and weight document). Once approved, the trip is cleared to move.
In transit
Movement begins. The vehicle's location is tracked live via the Afaqy integration (if the device IMEI is bound to the vehicle).
Arrival and unloading
On arrival at the delivery point, unloading begins.
Delivery and proof
The driver completes delivery with a signature and a delivery proof photo. The trip is then completed.
Settlement
The trip's financial settlement is calculated: revenue minus (fuel, maintenance, violations, insurance, depreciation, driver pay, and other costs) = gross profit + profit margin. The driver rating is also updated.
The recorded timestamps (16 points)
The system stores these per trip for reporting:
| Stamp | Meaning |
|---|---|
dispatchedAt | Trip dispatched to driver |
acceptedAt | Driver accepted |
arrivedLoadingAt | Arrived at loading point |
preLoadingChecklistAt | Pre-loading checklist submitted |
preLoadingApprovedAt | Supervisor approved the checklist |
loadingStartedAt | Loading began |
atWeightStationAt | Arrived at weight station |
weightDocumentUploadedAt | Weight document uploaded |
bayanAlNaqlAttachedAt | Bayan attached |
postLoadingChecklistAt | Post-loading checklist submitted |
clearedToMoveAt | Cleared to move |
inTransitAt | Movement began |
arrivedDeliveryAt | Arrived at delivery |
unloadingStartedAt | Unloading began |
deliveredAt | Delivered |
completedAt | Trip completed |
Key points
- There are two checklists:
pre_loading(vehicle readiness before loading) andpost_loading(Bayan + weight document after loading). - The Bayan always precedes the post-loading checklist — a driver cannot submit it before the Bayan is attached.
- Revenue is computed per trip from
route.quantityUnitand the unit price — it is never derived by splitting the contract total. - Vehicle status syncs automatically with trip progress.