Add Tasks Controller and fix idiotic bug in model