Sha256: 1a4d65ac11381729ecb3d515cfd7f5f00ca0f20c4ad3bbf0f41727ef7db50e9b

Contents?: true

Size: 653 Bytes

Versions: 1

Compression:

Stored size: 653 Bytes

Contents

require 'money_s3/parsers/base_parser'
require 'money_s3/parsers/dokl_ref_type'

module MoneyS3
  module Parsers
    class KurzRozd
      include BaseParser

      def typ
        at :Typ
      end

      def preceneni
        at :Preceneni
      end

      def castka
        at :Castka
      end

      def kr_poradi
        at :KRPoradi
      end

      def doklad
        submodel_at(DoklRefType, :Doklad)
      end

      def to_h
        { typ: typ,
          preceneni: preceneni,
          castka: castka,
          kr_poradi: kr_poradi,
          doklad: doklad.to_h
        }.delete_if { |k, v| v.nil? || v.empty? }
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
money_s3-0.4.0 lib/money_s3/parsers/kurz_rozd.rb