As part of a screening process I was recently asked to build a basic web application.
This repo is what I put together in the time available.
Build a web app to administer an elevatory system that:
- Is responsive.
- Caters for 4 elevators (A,B,C,D).
- Caters for 10 floors.
- Has a max person load of 20 per elevator.
- Dispatches an elevator closest to floor where one was requested.
- Shows how many boarding passengers are waiting for a given floor.
- Has a mechanism for entering boarding passengers and destination for a given floor (related to the above).
- Shows each elevator and its direction of travel (up, down, stationary) along with its load.
The built app can be found in the
This can be served through your web server of choice.
Alternatively, you can use
grunt to serve it with
grunt serveCompiledApp from the terminal.
To install dependencies run:
To develop, run:
This will start a server and see LiveReload changes.
The tests focus on the brief's requirements.
This will run automatically while developing using
This will build the app into the
compiled-app directory and start a server to serve it on:
It essentially runs
grunt serveCompiledApp as the last task in the
- There is no backend although it could benefit from one. The data is mocked in the
main.htmlview could refactor the use of
ng-class, perhaps making use of a directive instead.
- There could be better error handling and validation in the view and controller.