Sha256: 4562b8a477545afa0ee6c7bfee20462f4d5f387744bcde7d481fb64b51547231
Contents?: true
Size: 551 Bytes
Versions: 10
Compression:
Stored size: 551 Bytes
Contents
require 'hammer_cli' module Fields class SingleReference < Field def display?(value) id_key = "#{parameters[:key]}_id" display_field = parameters[:display_field] || 'name' display_key = "#{parameters[:key]}_#{display_field}" (value[display_key.to_sym] || value[display_key]) && (value[id_key.to_sym] || value[id_key]) end end class Reference < Field end class Template < Reference def initialize(options={}) options[:details] ||= [:template_kind_name] super(options) end end end
Version data entries
10 entries across 10 versions & 1 rubygems