Using angular to the ajax call