public static Issues ToModel(this ISSUES Table)
        {
            if (Table == null)
            {
                return(null);
            }

            return(new Issues()
            {
                Id = Table.Id,
                Descripcion = Table.Descripcion,
                Fecha_Creacion = Table.Fecha_Creacion
            });
        }
Exemplo n.º 2
0
        /// <summary>
        /// Converts this instance of <see cref="ISSUES"/> to an instance of <see cref="Issues"/>.
        /// </summary>
        /// <param name="entity"><see cref="ISSUES"/> to convert.</param>
        public static Issues ToModel(this ISSUES entity)
        {
            if (entity == null)
            {
                return(null);
            }

            var dto = new Issues();

            dto.Id             = entity.Id;
            dto.Descripcion    = entity.Descripcion;
            dto.Fecha_Creacion = entity.Fecha_Creacion;

            entity.OnDTO(dto);

            return(dto);
        }
Exemplo n.º 3
0
        /// <summary>
        /// Converts this instance of <see cref="Issues"/> to an instance of <see cref="ISSUES"/>.
        /// </summary>
        /// <param name="dto"><see cref="Issues"/> to convert.</param>
        public static ISSUES ToTable(this Issues dto)
        {
            if (dto == null)
            {
                return(null);
            }

            var entity = new ISSUES();

            entity.Id             = dto.Id;
            entity.Descripcion    = dto.Descripcion;
            entity.Fecha_Creacion = DateTime.Now;

            dto.OnEntity(entity);

            return(entity);
        }
Exemplo n.º 4
0
 /// <summary>
 /// Invoked when <see cref="ToTable"/> operation is about to return.
 /// </summary>
 /// <param name="entity"><see cref="ISSUES"/> converted from <see cref="Issues"/>.</param>
 static partial void OnEntity(this Issues dto, ISSUES entity);
Exemplo n.º 5
0
 /// <summary>
 /// Invoked when <see cref="ToModel"/> operation is about to return.
 /// </summary>
 /// <param name="dto"><see cref="Issues"/> converted from <see cref="ISSUES"/>.</param>
 static partial void OnDTO(this ISSUES entity, Issues dto);