[TYPO3-ect] The Big Plan
Elmar Hinz
elmar.DOT.hinz at team.MINUS.red.DOT.net
Wed Jul 5 14:30:29 CEST 2006
Michael Scharkow wrote:
>> However the TCA does not contain all configuration we need to generate
>> the forms. We need to discuss the best solutions to fill this gap.
>
> I disagree: Not only does TCA contain enough configuration for both ORM
> and form building, but it does even contain too many form-building
> related (=view related) options, i.e. palettes.
Well, palettes are specific for the BE. There will always be differents in
the display for BE and FE or more general between different groups of
users. I am very open for proposals how this can be done.
>
> Concerning form building for TCA objects, I have the following demands:
>
> 1. TCAObjects must be able to validate themselves, independent of forms.
Yes, I also see an advantage of an additional validation on the model
level. Especially if the data comes from other sources then forms. However
model level and view level can make use of the same validation library.
> 2. TCAObjects must render themselves both input (=form) and output
> (list, detail view), or the other way round: view classes should accept
> any TCAObject as input and render forms, single view accordingly
I wrote the long intro to point out the disadvantages of this monolithic
concept. Obviously I didn't convince you. I don't will repeat my arguments
and negative experiences with this.
If functionally can be separated one should separate it. Kaspers code
suffers mostly from overloading classes with to much functionality.
Combining of separated function when it is needed is much easier than to
separate functionality from oversized classes.
> 3. The Client-Side-Validation belongs to the view part, although the
> requirements are derived from TCA
* Yes. Requirements of validation are derived from TCA in all cases.
* Validation is done with a separte validation library.
* Client side validation is JavaScript based. If we use JavaScript, we
directly can use AJAX. If we use AJAX, we directly use the server side
validation.
That makes it very simple for us. AJAX clientside, serverside view and
serverside model validation can all be done with the same library.
>
> By mixing both model and view aspects in TCA we gain a lot of
> configurable "magic" views which IMHO far outweighs the advantages of
> strict M-V separation.
>
The advantages, the magic, you see in the monolithic concept can also be
gained at a very cheap price with separated funcitonality by combination.
With separation of functionality you don't loose any functionality. You
simply structure it more fine grained.
The costs you pay for the disadvantages of a monolithic concept are much
higher. Believe me.
Regards
Elmar
More information about the TYPO3-team-extension-coordination
mailing list