-sub list :Exported {
- my ($self, $r) = @_;
- my %ok_columns = map {$_ => 1} $self->columns;
- if ( my $rows = $r->config->{rows_per_page}) {
- $self = $self->pager($rows, $r->query->{page});
- $r->{template_args}{pager} = $self;
- }
- my $order;
- if ($order = $r->query->{order} and $ok_columns{$order}) {
- $r->objects([ $self->retrieve_all_sorted_by( $order.
- ($r->query->{o2} eq "desc" && " DESC")
- )]);
- } else {
- $r->objects([ $self->retrieve_all ]);
- }
-}
+sub Untainter { 'CGI::Untaint::Maypole' };
+
+=head2 add_model_superclass
+
+Adds model as superclass to model classes (if necessary)
+
+Inherited from Maypole::Model::CDBI::Base
+
+=head1 Action Methods
+
+Action methods are methods that are accessed through web (or other public) interface.
+
+Inherited from L<Maypole::Model::CDBI::Base>
+
+=head2 do_edit
+
+If there is an object in C<$r-E<gt>objects>, then it should be edited
+with the parameters in C<$r-E<gt>params>; otherwise, a new object should
+be created with those parameters, and put back into C<$r-E<gt>objects>.
+The template should be changed to C<view>, or C<edit> if there were any
+errors. A hash of errors will be passed to the template.
+
+=head2 do_delete
+
+Inherited from Maypole::Model::CDBI::Base.
+
+This action deletes records
+
+=head2 do_search
+
+Inherited from Maypole::Model::CDBI::Base.
+
+This action method searches for database records.
+
+=head2 list
+
+Inherited from Maypole::Model::CDBI::Base.
+
+The C<list> method fills C<$r-E<gt>objects> with all of the
+objects in the class. The results are paged using a pager.
+
+=head1 Helper Methods
+
+=head2 setup
+
+ This method is inherited from Maypole::Model::Base and calls setup_database,
+ which uses Class::DBI::Loader to create and load Class::DBI classes from
+ the given database schema.
+
+=cut
+
+=head2 setup_database
+
+The $opts argument is a hashref of options. The "options" key is a hashref of
+Database connection options . Other keys may be various Loader arguments or
+flags. It has this form:
+ {
+ # DB connection options
+ options { AutoCommit => 1 , ... },
+ # Loader args
+ relationships => 1,
+ ...
+ }
+
+=cut