view Agendas/trunk/src/Agendas.Web/Models/EventoModel.cs @ 78:2adf55ea9199

Fecha del evento en los eventos agendados
author nelopauselli
date Tue, 24 May 2011 17:56:20 -0300
parents 96d7609f2e08
children 8df9db937434
line wrap: on
line source

using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;

namespace AltNetHispano.Agendas.Web.Models
{
    public class EventoIndexModel
    {
        public IEnumerable<EventoDto> ProximosEventos { get; set; }
    }

    public class EventoNewModel
    {
        [Required(ErrorMessage = "debe ingresar el título")]
        public string Titulo { get; set; }

        [Required(ErrorMessage = "debe ingresar el nombre del ponente")]
        public string Ponente { get; set; }

        [Required(ErrorMessage = "debe ingresar la fecha del evento")]
        public DateTime Fecha { get; set; }

        public string UrlInvitacion { get; set; }
    }

    public class EventoEditModel
    {
        [HiddenInput(DisplayValue = false)]
        public string Id { get; set; }

        [Required(ErrorMessage = "debe ingresar el título")]
        public string Titulo { get; set; }

        [Required(ErrorMessage = "debe ingresar el nombre del ponente")]
        public string Ponente { get; set; }

        [Required(ErrorMessage = "debe ingresar la fecha del evento")]
        public DateTime? Fecha { get; set; }

		public string UrlInvitacion { get; set; }
	}
    

    public class EventoDto
    {
        public string Id { get; set; }
        public string Titulo { get; set; }
		public DateTime Fecha { get; set; }
    }
}