Class: Koi::Helpers::AttributeTypes::EnumType
- Inherits:
-
Base
- Object
- Base
- Koi::Helpers::AttributeTypes::EnumType
show all
- Defined in:
- lib/generators/koi/helpers/attribute_types.rb
Instance Attribute Summary
Attributes inherited from Base
#attribute
Instance Method Summary
collapse
Methods inherited from Base
#initialize
Instance Method Details
#collection_attribute ⇒ Object
155
156
157
|
# File 'lib/generators/koi/helpers/attribute_types.rb', line 155
def collection_attribute
%(attribute :#{attribute.name}, :enum)
end
|
143
144
145
|
# File 'lib/generators/koi/helpers/attribute_types.rb', line 143
def govuk_input
%(<%= form.govuk_enum_select :#{attribute.name} %>)
end
|
#index_row ⇒ Object
147
148
149
|
# File 'lib/generators/koi/helpers/attribute_types.rb', line 147
def index_row
%(<% row.enum :#{attribute.name} %>)
end
|
#show_row ⇒ Object
151
152
153
|
# File 'lib/generators/koi/helpers/attribute_types.rb', line 151
def show_row
%(<% row.enum :#{attribute.name} %>)
end
|