Esempio n. 1
0
		public ActionResult AddComment(CommentModel comment)
		{
			// Create a fake ID for this comment
			comment.Id = _comments.Count + 1;
			_comments.Add(comment);
			return Content("Success :)");
		}
Esempio n. 2
0
        public ActionResult AddComment(CommentModel comment)
        {
            //repositorio.Agregar(comment);
            //NotificarComentarioNuevo();
            //return Content("Success :)");
            comment.Identificador = Guid.NewGuid().ToString();
            ServiceBusConfiguracion.EnviarMensaje(comment);

            return Content(comment.Identificador);
        }
Esempio n. 3
0
        public ActionResult AddComment(CommentModel comment)
        {
            comment.Id = (comments != null && comments.Any())
                ? comments.Max(c => c.Id) + 1
                : 1;

            comments.Add(comment);

            return Content("Success :)");
        }
 public ActionResult AddComment(CommentModel comment)
 {
     _comments.Add(comment);
     return Content("Success :)");
 }