Sha256: b204c0b404a9b0327c5ce0cd999abb407955a683a01c47f72d7767b5ef680192
Contents?: true
Size: 436 Bytes
Versions: 16
Compression:
Stored size: 436 Bytes
Contents
module Moysklad::Entities class AttributeValue < Virtus::Attribute def coerce(value) case value when String, Float value when ::Hash if value['meta']['type'] == 'customentity' CustomEntity.new value else raise "Unknown meta type: #{value['meta']['type']}" end else raise "Unknown value type (#{value}) #{value.class}" end end end end
Version data entries
16 entries across 16 versions & 1 rubygems