Re: Refactoring Views

2006-10-23 Thread Matt Adams
[EMAIL PROTECTED] wrote: > Ditto I would love to see that framework, Matt, even if it's not all > packaged up and ready for prime time. I will do my utmost to release it when I have time. I've been crazy busy lately and haven't had time to even think about it. I will, of course, have to get c

Re: Refactoring Views

2006-10-22 Thread Sonic Baker
Hi guys,Thank you your responses and code samples. Some interesting things to think about. Your input has been very much appreciated.Cheers,Sonic --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To po

Re: Refactoring Views

2006-10-21 Thread [EMAIL PROTECTED]
Ditto I would love to see that framework, Matt, even if it's not all packaged up and ready for prime time. I've been thinking since starting with Cake that more extensive and versatile code generation would advance Cake from merely wonderful to absolutely earthshaking, Holy Grail kind of material

Re: Refactoring Views

2006-10-20 Thread Grant Cox
I'd be interested in seeing it too. Personally I make a _addedit($id) action in my controller, and a _addedit.thtml element (in with the normal view files). These have the common parts of add and edit in them. I'm not sure if this will stay this way once I start serious work on the application

RE: Refactoring Views

2006-10-20 Thread Christian Winther
> To be brief, what I've done is create a meta-framework that works > hand-in-hand with Cake (using Cake itself and a small number of external > scripts and processes) that is able to generate all of my views for me > using a series of reusable elements and helpers. > This meta-framework knows

Re: Refactoring Views

2006-10-20 Thread Matt Adams
Sonic Baker wrote: > I was just using the forms generated form Bake as an example to > illustrate the types of duplication I mean. > > That meta-framework of yours sounds wonderful. Is it hard on resources? Not particularly. Running in production mode it takes about 1 second to render each v

Re: Refactoring Views

2006-10-20 Thread Sonic Baker
Hi Matt,Thank you for your reply.I was just using the forms generated form Bake as an example to illustrate the types of duplication I mean.That meta-framework of yours sounds wonderful. Is it hard on resources? If you weren't using it, how would you answer my questions above?Cheers,Sonic --~--~--

Re: Refactoring Views

2006-10-20 Thread Matt Adams
Sonic Baker wrote: > In my quest to follow the DRY principle I've been looking into > refactoring my views. If you use Bake to generate default views you'll > have 'add' and 'edit' views. These both share the same form inputs and > if you start playing around with error messages you'll have to

Refactoring Views

2006-10-20 Thread Sonic Baker
In my quest to follow the DRY principle I've been looking into refactoring my views. If you use Bake to generate default views you'll have 'add' and 'edit' views. These both share the same form inputs and if you start playing around with error messages you'll have to do it on both forms. Would this