Sha256: 36d4b89850854fcb9a3419f40a2c8726bce797cd1a56d17c1c05edd1c62ef544

Contents?: true

Size: 645 Bytes

Versions: 1

Compression:

Stored size: 645 Bytes

Contents

Kajam.config do |config|
  config.namespace('testing', :allow_change => true) do |testing|
    testing.define 'defaulted', :label => 'Has a default', :default => "this default string"
    testing.define 'protected', :label => 'Cannot change', :default => "something", :allow_change => false
    testing.define 'validated', :label => 'Has validation', :default => "monkey", :validate_with => lambda {|s| s.errors.add(:value, "not monkey") unless s.value == "monkey" }
    testing.define 'selected', :select_from => lambda { TextFilter.descendants.map { |s| s.filter_name }.sort }, :label => "Default text filter", :allow_blank => true
  end
end 

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
kajam-1.0.3.rc2 spec/fixtures/more_settings.rb