Sha256: 806ecb60646d0bb510e5ff0818f53c236519cd4d128f5d3678b17d520ea2df93

Contents?: true

Size: 1.13 KB

Versions: 2

Compression:

Stored size: 1.13 KB

Contents

module MoneyS3
  module Builders
    class Eshop2
      include ParserCore::BaseBuilder

      def builder
        root = Ox::Element.new(name)
        if data.respond_to? :attributes
          data.attributes.each { |k, v| root[k] = v }
        end

        root << build_element('IN_Export', data[:in_export]) if data.key? :in_export
        root << build_element('IN_Changed', data[:in_changed]) if data.key? :in_changed
        root << build_element('IN_Id', data[:in_id]) if data.key? :in_id
        root << build_element('IN_Jmeno', data[:in_jmeno]) if data.key? :in_jmeno
        root << build_element('IN_Heslo', data[:in_heslo]) if data.key? :in_heslo
        root << build_element('IN_Dealer', data[:in_dealer]) if data.key? :in_dealer
        root << build_element('IN_DSkup', data[:in_d_skup]) if data.key? :in_d_skup
        root << build_element('IN_IndSlev', data[:in_ind_slev]) if data.key? :in_ind_slev
        root << build_element('IN_Soukrom', data[:in_soukrom]) if data.key? :in_soukrom
        root << build_element('IN_DSkupZkratka', data[:in_d_skup_zkratka]) if data.key? :in_d_skup_zkratka

        root
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
money_s3-0.12.0 lib/money_s3/builders/eshop2.rb
money_s3-0.11.0 lib/money_s3/builders/eshop2.rb