private static OfertaRowViewModel ConvertToOfertaRowViewModel(this CandidaturaOferta oferta)
        {
            var ofertaRowViewModel = new OfertaRowViewModel()
            {
                OfertaId     = oferta.CandidaturaOfertaId,
                NombreOferta = oferta.NombreOferta
            };

            return(ofertaRowViewModel);
        }
示例#2
0
        private static OfertaRowViewModel ConvertToOfertaRowViewModelSinCandidatos(this Oferta oferta)
        {
            var ofertRowViewModel = new OfertaRowViewModel()
            {
                OfertaId         = oferta.OfertaId,
                Nombre           = oferta.Nombre,
                Estado           = oferta.EstadoOferta.Nombre,
                FechaPublicacion = oferta.FechaPublicacion,
                Centro           = oferta.Usuario.CentroId != null ? oferta.Usuario.Centro.Nombre : string.Empty
            };

            return(ofertRowViewModel);
        }
示例#3
0
        private static OfertaRowViewModel ConvertToOfertaRowViewModel(this Oferta oferta, Dictionary <int, int> totalCandidatos)
        {
            var ofertRowViewModel = new OfertaRowViewModel()
            {
                OfertaId         = oferta.OfertaId,
                Nombre           = oferta.Nombre,
                Estado           = oferta.EstadoOferta.Nombre,
                Candidatos       = totalCandidatos[oferta.OfertaId],
                FechaPublicacion = oferta.FechaPublicacion,
                Centro           = oferta.Usuario.CentroId != null ? oferta.Usuario.Centro.Nombre : string.Empty
            };

            return(ofertRowViewModel);
        }