(refactor) Refactor ab_test, query, and timer files. Add <script> tags f...

...or all states in index.html. Adds controllers for each state in app.config.js.