Form::VisibleFields() and FieldList::VisibleFields() #210

merged 2 commits into from Mar 9, 2012


None yet
2 participants

sminnee commented Mar 7, 2012

I added these when working on a form when is too heavyweight. It let me structure a form like this:

    <% with Form %>
    <form $FormAttributes>
        <% loop VisibleFields %>$Field<% end_loop %>
    <% end_with %>
+ * Return all fields except for the hidden fields.
+ * Useful when making your own simplified form layouts.
+ */
+ function VisibleFields() {

stojg Mar 9, 2012


According to style guidelines, public keyword must be explicitly set


sminnee commented Mar 9, 2012

OK, @stojg I've added some publicity.

sminnee added some commits Mar 7, 2012

API CHANGE: Added Form::VisibleFields() and FieldList::VisibleFields(…
…), which list everything except hidden fields, to assist with the creation of custom form layouts.

stojg commented Mar 9, 2012

all good, merging.

stojg pushed a commit that referenced this pull request Mar 9, 2012

Stig Lindqvist
Merge pull request #210 from sminnee/form-visiblefields
Form::VisibleFields() and FieldList::VisibleFields()

@stojg stojg merged commit 2ab12af into silverstripe:master Mar 9, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment