Sha256: b2e5cfb40b61795cdd2af06d85ca8ee3cb71fef92cd4e554449f906445a24738

Contents?: true

Size: 524 Bytes

Versions: 12

Compression:

Stored size: 524 Bytes

Contents

module WashOut
  module Model
    def wash_out_columns
      columns_hash
    end

    def wash_out_param_map
      types = {
        :text      => :string,
        :float     => :double,
        :decimal   => :double,
        :timestamp => :string
      }
      map = {}

      wash_out_columns.each do |key, column|
        type = column.type
        type = types[type] if types.has_key?(type)
        map[key] = type
      end

      map
    end

    def wash_out_param_name
      return name.underscore
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
wash_out-0.9.0 lib/wash_out/model.rb
wash_out-0.9.0.beta.2 lib/wash_out/model.rb
wash_out-0.9.0.beta.1 lib/wash_out/model.rb
wash_out-0.8.4 lib/wash_out/model.rb
wash_out-0.8.3 lib/wash_out/model.rb
wash_out-0.8.2 lib/wash_out/model.rb
wash_out-0.8.1 lib/wash_out/model.rb
wash_out-0.7.1 lib/wash_out/model.rb
wash_out-0.7.0 lib/wash_out/model.rb
wash_out-0.6.1 lib/wash_out/model.rb
wash_out-0.6.0 lib/wash_out/model.rb
wash_out-0.5.6 lib/wash_out/model.rb