Beispiel #1
0
        /// <summary>
        /// Sets Post from DB using ID
        /// </summary>
        /// <returns></returns>
        public async Task OnGet()
        {
            // set all the data for my .cshtml page.

            // Get the specific Restaurant data for the id that was sent.
            Post = await _post.FindPost(ID);
        }
 /// <summary>
 /// Sets the Post
 /// </summary>
 /// <returns>Post</returns>
 public async Task OnGet()
 {
     Post = await _post.FindPost(ID.GetValueOrDefault()) ?? new Post();
 }