Class: Cardboard::Field::Boolean
Instance Attribute Summary
#seeding
Instance Method Summary
collapse
new_with_castnew, #required?, #type, #type=
Instance Method Details
#default ⇒ Object
13
14
15
|
# File 'app/models/cardboard/field/boolean.rb', line 13
def default
[true, false].sample
end
|
#value ⇒ Object
5
6
7
|
# File 'app/models/cardboard/field/boolean.rb', line 5
def value
to_boolean(value_uid)
end
|
#value=(val) ⇒ Object
9
10
11
|
# File 'app/models/cardboard/field/boolean.rb', line 9
def value=(val)
self.value_uid = to_boolean(val) end
|