///<summary /// Gets all the notes for the current user. /// </summary> /// <returns></returns> public IHttpActionResult GetNotes() { var service = new Services.NoteService(); var userId = User.Identity.GetUserId(); var notes = service.GetAllForUser(Guid.Parse(userId)); return(Ok(notes)); }
///<summary /// Gets all the notes for the current user. /// </summary> /// <returns></returns> public IHttpActionResult GetNotes() { var service = new Services.NoteService(); var userId = User.Identity.GetUserId(); var notes = service.GetAllForUser(Guid.Parse(userId)); return Ok(notes); }
// GET: Notes public ActionResult Index() { if (TempData["Result"] != null) { ViewBag.Success = TempData["Result"]; TempData.Remove("Result"); } var noteService = new Services.NoteService(); var notes = noteService.GetAllForUser(Guid.Parse(User.Identity.GetUserId())); return(View(notes)); }
// GET: Notes public ActionResult Index() { if (TempData["Result"] != null) { ViewBag.Success = TempData["Result"]; TempData.Remove("Result"); } var noteService = new Services.NoteService(); var notes = noteService.GetAllForUser(Guid.Parse(User.Identity.GetUserId())); return View(notes); }