[Catalyst] Catalyst design philosophy

Sebastian Riedel sri at oook.de
Sat Apr 9 03:18:51 CEST 2005


Am 09.04.2005 um 02:52 schrieb Michael Reece:
> my question is, how are others doing this sort of thing?  should each 
> table
> have its own controller?  or at least those tables that override their
> list/destroy/etc methods?

I call this the Maypole syndrome... ;)
You try to wrap your application around a very restrictive crud 
architecture, instead of just using MVC to make your life easier.
CRUD may seem easy and nice at first, but your application gets a messy 
collection of hacks very fast.

Take a look at MiniMojo/MojoMojo to get some inspiration.

There is no restrictive philosophy behind Cat.
You just use Controllers to bundle actions that seem logical related.

>
> thinking to the future when/if i have to convert this to Cat5 .. it 
> looks
> like in Cat5 you can't forward to another controller's default action. 
>  how
> would a Cat5 controller know that it should handle /table/action/ for 
> any
> table without me creating redundant sub's for each table name or 
> hard-coding
> the list of tables into a :Regex action pattern?

Every action gets a unique private address, so you can still forward to 
everything.

>
> all this confusion has me thinking i am approaching this all wrong 
> from the
> start, and i would like to get into the proper mindset before i get 
> too much
> further.

Try to forget Maypole restrictions...

--
sebastian




More information about the Catalyst mailing list