Skip to content

Commit

Permalink
Merge 3d1a5a5 into a2d5381
Browse files Browse the repository at this point in the history
  • Loading branch information
bricesanchez committed Jan 7, 2015
2 parents a2d5381 + 3d1a5a5 commit 8a3d792
Showing 1 changed file with 23 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
h2. Generates a custom form

h3. Description

Generates a custom form based extension for Refinery automatically.
It works very similarly to the Refinery Engine generator.

The first string attribute should always be the one which is the title or name field in your model.

There must be at least one attribute.

h3. Additional Supported Field Types

All field types that are supported by the Refinery Engine generator are supported with the addition of these form specific ones:

* radio - creates a set of radio buttons based off Model::FIELD_NAMES
* checkbox - creates a checkbox for true/false values.
* select - creates a select list with options using Model::FIELD_NAMES

Example:
<shell>
$ rails generate refinery:form job_inquiry name:string message:text job_type:radio brochure:checkbox qualification:select
</shell>

0 comments on commit 8a3d792

Please sign in to comment.