public async Task <ViewResult> Edit(SxVMSiteQuestion model)
        {
            if (!ModelState.IsValid)
            {
                return(View(model));
            }

            var mm = new SxAppMailManager();

            var sb = new StringBuilder();

            sb.AppendLine(model.Email);
            sb.AppendLine(model.UserName);
            sb.AppendLine(model.Text);

            var result = await mm.SendMail(sb.ToString(), new[] {
                "*****@*****.**",
                "*****@*****.**"
            }, "Обращение с формы обратной связи");

            var mes = new SxVMResultMessage("Ваше письмо успешно отправлено", SxVMResultMessage.ResultMessageType.Ok);

            if (!result)
            {
                mes.Message     = "Ошибка отправки сообщения. Попробуйте еще раз";
                mes.MessageType = SxVMResultMessage.ResultMessageType.Error;
            }
            ViewBag.Message = mes;
            ;
            return(View(model: new SxVMSiteQuestion()));
        }
        public async Task<ViewResult> Edit(SxVMSiteQuestion model)
        {
            if (ModelState.IsValid)
            {
                var smtpUserName = ConfigurationManager.AppSettings["NoReplyMail"];
                var mm = new SxAppMailManager(smtpUserName, ConfigurationManager.AppSettings["NoReplyMailPassword"], "mail.game-exe.com");

                var sb = new StringBuilder();
                sb.AppendLine(model.Email);
                sb.AppendLine(model.UserName);
                sb.AppendLine(model.Text);

                var result= await mm.SendMail(model.Email, sb.ToString(), new string[] { "*****@*****.**", "*****@*****.**" }, "Обращение с формы обратной связи");

                TempData["Message"] = "Ваше письмо успешно отправлено";
                return View(model: new SxVMSiteQuestion());
            }
            return View(model);
        }
 public ActionResult Edit()
 {
     var viewModel = new SxVMSiteQuestion();
     return View(viewModel);
 }
        public ActionResult Edit()
        {
            var viewModel = new SxVMSiteQuestion();

            return(View(viewModel));
        }