While I have yet to thoroughly review Catalyst, I imagine if there was
going to be something about to inspire envy from me, it would be the
Catalyst::Model::CDBI::CRUD
which helps build CRUD applications.
Here's my review of it:
What I liked:
- It is fundamentally well designed. The guts of the functionality
are appropriately outsourced to Class::DBI::FromForm and
Class::DBI::AsForm.
- It provides reasonable defaults, but makes it easy to customize the
system with unique logic or graphic designs.
- It would be very easy to re-implement something like it in
CGI::Application because the "hard parts" are in the above Class::DBI
modules or the sample TT templates.
However, I saw a number of areas for improvement:
- The names could be improved. 'edit' and 'do_edit' are confusing. What's the difference?
I suggest what was worked well for me: 'edit_form_display' and 'edit_form_process'.
- The system does use Data::FormValidator for form validation, but only
weakly, by demonstrating how to make all the fields optional. Getting
Data::FormValidator::Util::Generator to work would improve this
integration significantly.
- There is no handling of missing/invalid error fields by default. This
could be easily and significantly improved by using DFV::Util::HTML
and ValidateRM(). to reload the page with errors.
- BREAD has better appeal than CRUD. :)
For my part, I'll work on getting DFV::Util::Generator working again, at
least with PostgreSQL. Considering this works with DB internals, it
will probably need some customization for other DB backends.
Mark
--
http://mark.stosberg.com/
---------------------------------------------------------------------
Web Archive: http://www.mail-archive.com/suppressed/
http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed
Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.