[ZDP] ZDPFAQ questions

Maik Roeder roeder@berg.net
Tue, 07 Mar 2000 18:07:49 +0100


Hi Rik !

> > Model/View/Controller:
> >
> > Model: FAQ Questions (dumb domain objects)
> > View: The ordered View of the FAQ Questions
> > Controller: Changing the order of FAQ Questions is done in the FAQ Sections
> >
> > The Model does not know what to do with itself, but only has properties
> > which are modified by the FAQ Section Controller. The View is completely
> > separate, and by my reckoning should not contain the order information.
> > Rather the View only looks on the FAQ Questions, and based on what it
> > sees decided how to display them.
> 
> What is the role of the container here. The container should know what
> to display.

The Container is the FAQ Section. Unfortunately the FAQ Section also
contains the View, but I see no alternative right now, as I don't
want to introduce more ZClasses for the View.
 
> >
> > > (you could imagine a situation where more orders would be possible)
> >
> > When more orders are possible you can either define new views or
> > define new order properties.
> >
> 
> Hm, perhaps, but then the Model is not so dumb.

The Model is dumb in the sense that it does only hold the information,
but that it does not know what to do with this information, or how 
to manipulate intself based on this information.
 
> > I don't see what exactly you are storing in the line property. I also
> > don't understand how the ordering numbers are then dynamically generated.
> >
> lines have objectids.
> 
> pseudo code:
> 
> dtml-in lines
> sequence-index+1, sequence-item
> /dtml-in
> 
> The bothersome part is to add a objectids. And information is replicated
> (which I do not like).

I also think that replication of information is to be avoided. This 
only introduces unnecessary complexity.
 
> Hm, still not sure.

We may consider creating a ZClass called "Orderer" or something like this,
which would act like a Controller on the Model. The View would be separated
naturally. This ZClass would be used to order anything that has an order
property. This way we could handle the generic case. 

What do you think ?

Greetings,

Maik Röder