R: [Zope] Discussion: Best practice site struture (LONG)

Maik Jablonski maik.jablonski@uni-bielefeld.de
Wed, 10 Apr 2002 15:28:36 +0200


On Wed, 10 Apr 2002 14:49:39 +0200 "Max M" <maxm@mxm.dk> wrote:

> Well in fact it is VERY easy to do in the ZODB. My mxmRelations product 
> does exactly this. Only, a product like that should be in the core.

hi max and all the others who are interested in ZODB-Relation-Management,

my idea for the mxmRelations (I call it RelationManager...
think of the Zope-Cache-Managers) is that we need something like the following
(yes, mxmRelations has some of the features already, but we need the
management trough ZMI for easy use):

- Each RelationManager should have two EntityContainers and one CrossTable.

- Each EntityContainer can be filled up TTW with references to objects (think
of the selection for a CacheManager... you can fill it up with all objects
in entire Folders, all DTML-Documents with title == '*.doc' and so).

So you can fill your Students easily into one EntityContainer and Classes into
another.

- In the CrossTable-View you can set or remove relations between elements of
the  EntityContainers with multiple selects and Relate-Or-Unrelate-Buttons.

   EntityContainer1        EntityContainer2
     Student1          |-----  Class1
     Student2          |-----  Class2
    [Student1] --------|       Class3
    ...
   
    SetRelationButton  DelRelationButton ...

- Now you can create different RelationManagers for all kind of Relationships
and talk to them if you want to know which relations between the objects
exist. For example:   

   You have RelationManagers for:

    Students<->Class
    Class<->Teachers
    Teachers<->Hobbies

So if I want to know which Students visit Classes from Teachers with the
Hobby of Bowling,  I get all Teachers with Bowling-Hobby from
Teachers<->Hobbies. Then I will get all the  Classes from Class<->Teachers and
then I will get the Students from Students<->Class. It's  a little bit like a
query in a relational database without SQL  (should work with intersecting
python lists...;-)

- But the rocking point would be: each object which is related in a
RelationManager should   have an additional View where you can set and delete
relations to and from this object.  Something like the thing with the new Tab
if you have created a CacheManager. I guess this must be a patch of the
ObjectManager/SimpleItem/andSoOn-Code...

thanks for listening...

maik

-- 
 maik jablonski                  http://www.sachunterricht-online.de
 universitaet bielefeld         http://www.zfl.uni-bielefeld.de
 zentrum fuer lehrerbildung    tlph://+49.(0).521.106.4234