[html-formfu] Creating a new row automaticly (with Catalyst)
    Octavian Rasnita 
    orasnita at gmail.com
       
    Sat Sep 20 20:30:49 BST 2008
    
    
  
Hi,
I have read that it is possible to create  a new row automaticly from a 
form, without creating first the row then updating it.
I have tried to do this with Catalyst, but it doesn't work. Here is what 
I've done:
in MyApp.pm:
__PACKAGE__->config(
  'Controller::HTML::FormFu' => {
    model_stash => {
      schema => 'AccesDB',
    },
  },
);
In the form config:
<model_config>
resultset Domain
</model_config>
(And I have also tried
resultset AccesDB::Domain
but without any effect.)
In the controller:
if ($form->submitted_and_valid) {
$form->model->update;
}
The result is that it gives the following error:
Caught exception in MyApp::Controller::Domain->add "row object missing at 
e:/web/MyApp/lib/MyApp/Controller/Domain.pm line 12"
Please tell me how it is possible to do this.
Thank you.
Octavian
    
    
More information about the HTML-FormFu
mailing list