added additional logic to restrict access to certain views; added "status" to ApplicationState Model