Relational Data Design
classDiagram
class Order
Order : +UUID id
Order : +DECIMAL(7,4) origin
Order : +DECIMAL(7,4) destination
Order : +STRING status
Sequence Diagram
sequenceDiagram
participant User
participant Driver
participant API
participant GoogleMaps
User->>API: Create Order
API->>GoogleMaps: Ask for distance
GoogleMaps->>API: Returning distance
loop SaveData
API->>API: Set status to UNASSIGNED
API->>API: Save distance to database
end
API->>User: Returning Order Creation Response
Driver->>API: Take Order
loop UpdateStatus
API->>API: Update status to TAKEN
end