Many thanks Carl, No rush on the optimization. I appreciate the time you have already put in writing the module. I actually removed the constraints as the elements were principally option lists, and if someone wanted it to fail then they would have to put the effort in to do so, I can also filter their inputs. What I found with regard to this was the constraints (cf filters) seemed to do more to check that they were operating on the correct field compared to what the filters were doing and this seemed the source of the extra processing.
Stephen On Tue, Feb 4, 2014 at 8:54 AM, Carl Franks <fireart...@gmail.com> wrote: > > I'd like to set a non db column value eg; > > > > __PACKAGE__->mk_group_accessors('simple' => qw/filter_update/); > > > > $row->filter_update(1); > > Hi Stephen, > Sorry I've not managed to look at your earlier performance issues yet > - I've not had any free time available :( > > From memory, H::F::Model::DBIC only uses values from fields matching > actual column names. > I think if you add $element->model_config->{accessor} = "simple" > to your form config, it'll do as you expect. > > Docs: > > http://search.cpan.org/~cfranks/HTML-FormFu-Model-DBIC-1.01/lib/HTML/FormFu/Model/DBIC.pm#Config_options_for_fields > > Test files: > > http://cpansearch.perl.org/src/CFRANKS/HTML-FormFu-Model-DBIC-1.01/t-aggregate/update/opt_accessor.t > > http://cpansearch.perl.org/src/CFRANKS/HTML-FormFu-Model-DBIC-1.01/t-aggregate/update/opt_accessor.yml > > Cheers, > Carl > > _______________________________________________ > HTML-FormFu mailing list > HTML-FormFu@lists.scsys.co.uk > http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/html-formfu >
_______________________________________________ HTML-FormFu mailing list HTML-FormFu@lists.scsys.co.uk http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/html-formfu