2008/11/7 Octavian Rasnita <[EMAIL PROTECTED]>:
> Hello,
>
> I try to use H::F::M::DBIC (because I want to update a related table easier), 
> but I can't even use default_values() and update() methods.
>
> $form->default_values doesn't do anything, while $form->update gives the 
> error "Can't locate object method "update" via package "HTML::FormFu".
>
> $form->model->default_values and $form->model->update work fine though.
>
> Am I doing something wrong, or H::F::M::DBIC is not working yet?
> Please tell me if there is a sample program that uses H::F::M::DBIC methods.

Hmm, I need to fix the documentation!

The correct methods are:
    $form->model->default_values;
    $form->model->update;
    $form->model->create;

Note that $form->default_values() does something else entirely [1]

There are many tests in the HTML-FormFu-Model-DBIC distribution, which
is probably the best place to start.

Carl

[1] 
http://search.cpan.org/~cfranks/HTML-FormFu-0.03005/lib/HTML/FormFu.pm#default_values

_______________________________________________
HTML-FormFu mailing list
HTML-FormFu@lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/html-formfu

Reply via email to