init
This commit is contained in:
		@@ -0,0 +1,46 @@
 | 
			
		||||
using System;
 | 
			
		||||
using System.ComponentModel;
 | 
			
		||||
using System.ComponentModel.DataAnnotations;
 | 
			
		||||
using Kreta.Naplo.Domain.V3.Orarend;
 | 
			
		||||
using Kreta.Naplo.Domain.V3.Utility;
 | 
			
		||||
using Kreta.Naplo.Dto.V3.Documentation;
 | 
			
		||||
using Kreta.Naplo.Dto.V3.Interfaces;
 | 
			
		||||
 | 
			
		||||
namespace Kreta.Naplo.Dto.V3.Orarend
 | 
			
		||||
{
 | 
			
		||||
    public class HetirendListResponseDto : IDtoListDocumentation
 | 
			
		||||
    {
 | 
			
		||||
        [Required, Description(DescriptionLookUp.ResponseModelEgyediAzonosito)]
 | 
			
		||||
        public int Id { get; set; }
 | 
			
		||||
 | 
			
		||||
        [Required, Description("Az entitás kezdő napja")]
 | 
			
		||||
        public DateTime KezdoNapDatuma { get; set; }
 | 
			
		||||
 | 
			
		||||
        [Required, Description("Az entitás végének napja")]
 | 
			
		||||
        public DateTime VegNapDatuma { get; set; }
 | 
			
		||||
 | 
			
		||||
        [Required, Description("A hét sorszáma a tanév kezdetétől számítva")]
 | 
			
		||||
        public int HetSorszama { get; set; }
 | 
			
		||||
 | 
			
		||||
        [Required, Description(DescriptionLookUp.Hetirend)]
 | 
			
		||||
        public string Hetirend { get; set; }
 | 
			
		||||
 | 
			
		||||
        public DocumentationExampleDto ListExample
 | 
			
		||||
            => new DocumentationExampleDto(
 | 
			
		||||
                "ListHetirend",
 | 
			
		||||
                new HetirendListRequestDto
 | 
			
		||||
                {
 | 
			
		||||
                    OrarendElemKezdoNapDatuma = new DateTime(2022, 05, 09, 0, 0, 0),
 | 
			
		||||
                    OrarendElemVegNapDatuma = new DateTime(2022, 05, 16, 0, 0, 0)
 | 
			
		||||
                });
 | 
			
		||||
 | 
			
		||||
        public static implicit operator HetirendListResponseDto(HetirendListResponse model) => new HetirendListResponseDto
 | 
			
		||||
        {
 | 
			
		||||
            Id = model.Id,
 | 
			
		||||
            KezdoNapDatuma = model.KezdoNapDatuma.ToIso8601Utc(),
 | 
			
		||||
            VegNapDatuma = model.VegNapDatuma.ToIso8601Utc(),
 | 
			
		||||
            HetSorszama = model.HetSorszama,
 | 
			
		||||
            Hetirend = model.Hetirend
 | 
			
		||||
        };
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
		Reference in New Issue
	
	Block a user