Example #1
0
        public IActionResult ReplyForm()
        {
            //ReplyForm needs a parent message ID because it tells the code which comment the reply belongs to

            //get the messageID
            //get the discussion genre (make it easier to search the messageboard content)
            int    messageID   = int.Parse(TempData["originalMessage"].ToString());
            string threadGenre = TempData["discussionThread"].ToString();

            //search the messageboard to find the original message object
            Message originalMessage = messageRepo.getMessageFromBoard(threadGenre, messageID);

            //Viewbag for background image
            ViewBag.BackgroundStyle = "pageContainer8";

            //pass in original message to be parsed and used
            return(View(originalMessage));
        }