Sha256: f975feb6049b23772a834a603430061c626a2ca9c19abb8a999fef4adbc817a0
Contents?: true
Size: 924 Bytes
Versions: 1
Compression:
Stored size: 924 Bytes
Contents
module MoneyS3 module Parsers class MsgPrevodkaType < MessageType include ParserCore::BaseParser def sklad_pro_pr submodel_at(MessageType, 'SkladProPr') end def dod_odb submodel_at(MsgFirmaType, 'DodOdb') end def konec_prij submodel_at(MsgFirmaType, 'KonecPrij') end def polozka array_of_at(MsgPolozType, ['Polozka']) end def data submodel_at(SklDoklType, 'Data') end def to_h hash = {} hash[:attributes] = attributes hash[:sklad_pro_pr] = sklad_pro_pr.to_h if has? 'SkladProPr' hash[:dod_odb] = dod_odb.to_h if has? 'DodOdb' hash[:konec_prij] = konec_prij.to_h if has? 'KonecPrij' hash[:polozka] = polozka.map(&:to_h) if has? 'Polozka' hash[:data] = data.to_h if has? 'Data' hash super.merge(hash) end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
money_s3-1.0.0 | lib/money_s3/parsers/msg_prevodka_type.rb |