示例#1
0
        public Certificado EmitirCertificado(CertificadoCommand command)
        {
            var evento      = _repositorioEventos.RecuperarPorEventoId(new EventoId(command.EventoId));
            var certificado = new Certificado(evento.EventoId, command.NomeParticipante, command.ChavePaticipante);

            // TODO : Persistir certificado
            // Disparar pelo domain Events o redirect para a view de emissão
            throw new NotImplementedException();
        }
示例#2
0
        public Certificado EmitirCertificado(CertificadoCommand command)
        {
            var evento = _repositorioEventos.RecuperarPorEventoId(new EventoId(command.EventoId));
            var certificado = new Certificado(evento.EventoId, command.NomeParticipante, command.ChavePaticipante);

            // TODO : Persistir certificado
            // Disparar pelo domain Events o redirect para a view de emissão
            throw new NotImplementedException();
        }
示例#3
0
        // GET: Default
        public ActionResult Index(Guid guid, string chave)
        {
            var evento = _servicoEvento.RecuperarEvento(guid);
            var participante = evento.RecuperarParticipantePelaChave(chave);

            // TODO: Validação de participante e evento;

            var command = new CertificadoCommand
            {
                EventoId = evento.EventoId.Id,
                ChavePaticipante = participante.ChaveAcesso,
                NomeParticipante = participante.Nome,
                TemplateId = evento.Tempelate.Id
            };

            var certificado = _servicoCertificado.EmitirCertificado(command);

            return View(certificado.UriCertificado());
        }