Bus Trip Manager
Technology used:
- XCode 15.0.1
- Combine
- SwiftUI
- CoreData
Libraries Added:
- snapshot testing (https://github.com/pointfreeco/swift-snapshot-testing)
- poyline (https://github.com/raphaelmor/Polyline)
Decisions:
- App for iPhone on portrait mode and minimum deployment 17.0
- Choosed blue color as primary because it's a calm color that I think fits for a Bus Trip App
- Select first trip (if available) at the start
- Set minimum date for the report 10 years ago and maximum date today
- Preestablish date as now
- Disable save button until information is valid
- Added Light / Dark mode support
Things to improve:
- Add swiftlint
- Add diferent colors for the trip status
- Order trips by date and status
- Add user location
You are asked to build a simple trip manager for our bus on demand solution. This tool will be used by the operators of the service in order to see the trips available in the system. The problem has four tasks and you should solve each one before the next.
- Goal: The initial screen should show a map and scrollable list of the current available trips.
- Guide:
- Each trip card should show some information: driver name, timestamps,... You can choose what you think is more important.
- Goal: When we click on one trip, it should be shown on the map. (map centers and zooms towards it)
- Guide:
- The route of the trip and the points of each stop should be shown on the map. Also the start and finish points of the trip.
- The map should be centered on the route and zoomed.
- It should be clear to the user which trip has been selected.
- The route returned by the API is a google encoded polyline. (check this) - You can use this third-party library: Polyline encoder / decoder in swift to represent the polyline on the map if you want to:
- Goal: When we click on one stop, a popup with the information of the stop should be shown.
- Guide:
- Each stop bubble should show some information about it: passenger, time,... You can choose what you think is more important.
- Goal: On the main screen we should be able to open a contact form in order to report an issue.
- Guide:
- The form should ask the name and surname of the user, email, phone (non-mandatory field), date and time of the reporting bug and a multiline input text (200 characters max) for the report description.
- This data should be validated and stored locally (you don’t need to send it to a server).
- The application’s icon badge number should display the total number of stored issues.