Revision a7f78b19
Added by Ohad Levy over 12 years ago
- ID a7f78b1919e885a0bdc8a3b0109264bb24c93b35
app/models/lookup_key.rb | ||
---|---|---|
errors.add(:default_value, "not in list") and return false unless validator_rule.split(KEY_DELM).map(&:strip).include?(default_value)
|
||
end
|
||
|
||
def as_json(options={})
|
||
super({:only => [:key, :description, :default_value, :id]}.merge(options))
|
||
end
|
||
|
||
end
|
Also available in: Unified diff
fixes #1148 - CRUD on lookup values via the API