Skip to content
This repository has been archived by the owner on Mar 8, 2018. It is now read-only.

Latest commit

 

History

History
13 lines (7 loc) · 2.79 KB

data_model.md

File metadata and controls

13 lines (7 loc) · 2.79 KB

#FixMyTransport data model

In terms of transport locations, in the interface, there are bus stops, stations, ferry terminals and routes. In the application itself, the models more closely reflect one of the chief data sources, NaPTAN (http://data.gov.uk/dataset/naptan). Stops represent transport access points - so bus stops, but also station platforms and entrances. Stop areas represent stations and ferry terminals, but also groups of related bus stops. Stops can be associated to zero or more stop areas.

Each route is associated with a single mode of transport and has one or more associated journey patterns. Each journey pattern for a route has one or more route segments - a segment represents one leg of the journey and is associated with the stop it comes from and the stop is goes to. It may be marked as a terminus for that journey pattern. In FixMyTransport, Sub-routes are used for problems on train routes to represent the sub-part of the larger route where the problem is.

A hierarchy of places is used to help identify what transport location users want to report problems at - stops and stop areas belong to localities (towns, villages etc), and these can belong to each other and to larger administrative areas.

Transport locations have responsible organisations associated with them - operators (companies responsible for running routes or maintaining stops and stations), councils, and passenger transport executives (http://en.wikipedia.org/wiki/Passenger_transport_executive). Passenger transport executives have responsibilities for public transport in large urban areas in the U.K. When a user reports a problem via FixMyTransport, a problem model is created - this is associated with the user and with the transport location they have selected.

Responsibilities join responsible organisations to problems. The initial responsibilities for a problem are determined by the responsible organisations for the transport location at which it is reported. Responsible organisations can have zero or more contacts - email addresses to which problem reports can be sent. Each contact can be associated with a category of problem report e.g. "Ticket Machines". Initial problem report emails are sent to the responsible organisations. A user may choose to create a campaign - a public page for gathering support for their proposed solution to a problem. Other users can then support the campaign. Additionally, any replies to a problem report which has an associated campaign will come directly into the application and be published on the campaign page. Replies to problem reports for problems without associated campaigns go directly to the users themselves.

Subscriptions represent users' interest in receiving email updates on problem reports and campaigns. Comments can be made on transport locations, campaigns and problems.