Sha256: d14018eeb8ca89b44a06956d60ea73a9bfe020d1235187a81ad88309778b66be
Contents?: true
Size: 829 Bytes
Versions: 18
Compression:
Stored size: 829 Bytes
Contents
module ActiveList module Helpers def recordify!(value, record_name) if value.is_a?(Symbol) return record_name + "." + value.to_s elsif value.is_a?(CodeString) return "(" + value.gsub(/RECORD/, record_name) + ")" else raise ArgumentError, "CodeString or Symbol must be given to be recordified)" end end def recordify(value, record_name) if value.is_a?(Symbol) return record_name + "." + value.to_s elsif value.is_a?(CodeString) return "(" + value.gsub(/RECORD/, record_name) + ")" else return value.inspect end end def urlify(value, record_name) if value.is_a?(CodeString) return "(" + value.gsub(/RECORD/, record_name) + ")" else return value.inspect end end end end
Version data entries
18 entries across 18 versions & 1 rubygems