Пример #1
0
        /// <summary>
        /// The create new answer.
        /// </summary>
        /// <param name="answer">
        /// The answer.
        /// </param>
        public void CreateNewAnswer(IAnswer answer)
        {
            var ans = answer.ToEntity();

            ans.CreatedOn   = DateTime.UtcNow;
            ans.UpdatedOn   = DateTime.UtcNow;
            ans.UpdatedBy   = Thread.CurrentPrincipal.Identity.Name;
            ans.CreatedBy   = Thread.CurrentPrincipal.Identity.Name;
            ans.Header     += string.Empty;
            ans.Directions += string.Empty;
            ans.Trailer    += string.Empty;
            AddNewQuestionAnswer(ans);
        }