[jifty-devel] Doc patch for Jifty::DBI::Schema

David H. Adler dha at panix.com
Fri Feb 17 19:00:07 EST 2006


After noticing that it wasn't clear what options one had for render_as,
I figured listing them where your class'd docs indicate they'd be was a
good idea.


--- lib/Jifty/DBI/Schema.pm	2006-02-17 15:35:54.000000000 -0500
+++ lib/Jifty/DBI/Schema.pm.rev	2006-02-17 18:46:40.000000000 -0500
@@ -289,6 +289,45 @@ sub hints ($) {
 
 Used in user interface generation to know how to render the column.
 
+The values for this attribute are the same as the names of the modules under
+Jifty::Web::Form::Field, i.e. 
+
+=over 
+
+=item * Button
+
+=item * Checkbox
+
+=item * Combobox
+
+=item * Date
+
+=item * Hidden
+
+=item * InlineButton
+
+=item * Password
+
+=item * Radio
+
+=item * Select
+
+=item * Textarea
+
+=item * Upload
+
+=item * Unrendered
+
+=back
+
+You may also use the same names with the initial character in lowercase. 
+
+The "Unrendered" may seem counter-intuitive, but is there to allow for
+internal fields that should not actually be displayed.
+
+If these don't meet your needs, you can write your own subclass of
+Jifty::Web::Form::Field. See the documentation for that module.
+
 =cut
 
 sub render_as ($) {

-- 
David H. Adler - <dha at panix.com> - http://www.panix.com/~dha/
Writing modules is easy.  Naming modules is hard.
	- Anno Siegel


More information about the jifty-devel mailing list