Sha256: 538de136b548c6a23e021cc8eeeae2ddfbc7eb19bee95e39cfdabfa17cef8fce

Contents?: true

Size: 506 Bytes

Versions: 13

Compression:

Stored size: 506 Bytes

Contents

module BrDanfe
  module DanfeLib
    module NfceLib
      class Key
        def initialize(pdf, xml)
          @pdf = pdf
          @xml = xml
        end

        def render
          @pdf.render_blank_line

          @pdf.text 'Consulte pela Chave de Acesso em', size: 9, align: :center, style: :bold
          @pdf.text @xml['urlChave'], size: 9, align: :center
          @pdf.text @xml['chNFe'].gsub(/(\d)(?=(\d\d\d\d)+(?!\d))/, '\\1 '), size: 8, align: :center
        end
      end
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
br_danfe-1.0.0 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.20.0 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.19.0 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.18.0 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.8 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.7 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.6 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.5 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.4 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.3 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.2 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.1 lib/br_danfe/danfe_lib/nfce_lib/key.rb
br_danfe-0.17.0 lib/br_danfe/danfe_lib/nfce_lib/key.rb