Fixed index.php

	* Changed order of middleware
	* Added templates to gitignore
Fixed tasks from projects

	* Missing selection of project ID
	* Added return of active and finished tasks