diff Agendas/trunk/src/Agendas.Web/Controllers/EventoController.cs @ 212:6944c54f834f

Ticket 175: Se cambia el mensaje por una pantalla de confirmaciĆ³n, que sugiere los textos.
author juanjose.montesdeocaarbos
date Fri, 26 Aug 2011 21:54:36 -0300
parents 607384590bf8
children c4c60e034103
line wrap: on
line diff
--- a/Agendas/trunk/src/Agendas.Web/Controllers/EventoController.cs	Fri Aug 26 07:27:01 2011 -0300
+++ b/Agendas/trunk/src/Agendas.Web/Controllers/EventoController.cs	Fri Aug 26 21:54:36 2011 -0300
@@ -68,11 +68,27 @@
     	[CustomAuthorize(Roles = Roles.Administrador)]
 		public ActionResult Confirmar(string id)
 		{
+			var agenda = AgendaFactory.GetAgenda();
+			var evento = agenda.GetEvento(new Guid(id));
+
+			var model = new EventoConfirmModel
+			{
+				Id = id,
+				Titulo = evento.Titulo/*,
+				Mensaje = "Recuerde agendar los eventos en http://twuffer.com/ u otro servicio similar."*/
+			};
+			return View("Defaulteditor", model);
+		}
+
+		[HttpPost]
+		[CustomAuthorize(Roles = Roles.Administrador)]
+		public ActionResult Confirmar(EventoConfirmModel model)
+		{
 			return
 				GenericAction(
-					(agenda, m) => agenda.Confirmar(m),
-					m => View("Index", m),
-					new Guid(id));
+					(agenda, m) => agenda.Confirmar(new Guid(m.Id)),
+					m => View("Defaulteditor", m),
+					model);
 		}
 
 		[CustomAuthorize(Roles = Roles.Administrador)]