コード例 #1
0
ファイル: NFeDI.cs プロジェクト: domicioam/NFeFacilLegacy
        public NFeDI(ProcessoNFCe nota, string xml)
        {
            if (nota.NFe.Informacoes.identificacao.Modelo == 55)
            {
                throw new Exception();
            }

            Id           = nota.NFe.Informacoes.Id;
            NomeCliente  = nota.NFe.Informacoes.destinatario?.Nome ?? "Desconhecido";
            NomeEmitente = nota.NFe.Informacoes.Emitente.Nome;
            CNPJEmitente = nota.NFe.Informacoes.Emitente.CNPJ.ToString();
            DataEmissao  = DateTime.Parse(nota.NFe.Informacoes.identificacao.DataHoraEmissão).ToString("yyyy-MM-dd HH:mm:ss");
            NumeroNota   = nota.NFe.Informacoes.identificacao.Numero;
            SerieNota    = nota.NFe.Informacoes.identificacao.Serie;
            Status       = nota.ProtNFe != null ? (int)StatusNota.Emitida : nota.NFe.Signature != null ? (int)StatusNota.Assinada : (int)StatusNota.Salva;
            IsNFCe       = true;
            XML          = xml;
        }
コード例 #2
0
 public DadosImpressao(ProcessoNFCe processo, Thickness margem, double largura)
 {
     Processo = processo;
     Margem   = margem;
     Largura  = largura;
 }