added templates, added some work on the views