public async Task <ActionResult> Detail(Guid id) { var token = await GetAccessToken(); var user = await UserDetailModel.GetUserDetail(String.Format("{0}/users/{1}", SettingsHelper.AzureAdTenant, id.ToString()), token.AccessToken); return(View(user)); }
public async Task <ActionResult> Index() { var token = await GetAccessToken(); var user = await UserDetailModel.GetUserDetail("me", token.AccessToken); return(View(user)); }
public async Task <ActionResult> Detail(Guid id) { var token = await GetAccessToken(); // wait for model class 'Models/UserDetailModel' to be populated.... var user = await UserDetailModel.GetUserDetail(String.Format("{0}/users/{1}", SettingsHelper.AzureAdTenant, id.ToString()), token.AccessToken); // pass model data to 'Views/User/Detail' return(View(user)); }
public async Task <ActionResult> Index() { var token = await GetAccessToken(); // wait for model class 'Models/UserDetailModel' to be populated.... var user = await UserDetailModel.GetUserDetail("me", token.AccessToken); // pass model data to 'Views/User/Index' return(View(user)); }