view Agendas/trunk/src/Agendas.Web/Models/PropuestaModel.cs @ 83:7e9ffde4022d

Implementando DataAnnotation desde recursos y por convención
author nelopauselli
date Tue, 24 May 2011 21:37:06 -0300
parents 8df9db937434
children 80c22175c9b5
line wrap: on
line source

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

namespace AltNetHispano.Agendas.Web.Models
{
    public class PropuestaIndexModel
    {
        public IEnumerable<PropuestaDto> Propuestas { get; set; }
    }

    public class PropuestaNewModel
    {
        [Required]
        public string Titulo { get; set; }

        public string Ponente { get; set; }

		[Url]
		public string UrlInvitacion { get; set; }
	}

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

        [Required]
        public string Titulo { get; set; }

        public string Ponente { get; set; }

		[Url]
		public string UrlInvitacion { get; set; }
	}
    

    public class PropuestaDto
    {
        public string Id { get; set; }
        public string Titulo { get; set; }
    	public string Ponente { get; set; }
    }
}