[Zope] Newbie Design Issue

Steve Spicklemire steve@spvi.com
Sun, 25 Nov 2001 05:22:32 -0500


Hi Jeremy,

	I'm guessing the simplest way would be to have 2 ZClasses. 
"CheckList" would subclass from ObjectManager and would be permitted to 
contain "CheckListItems". A "CheckListItem" would be a simple ZClass 
with a propertysheet that held all the properties of an individual item. 
You could the Catalog all the "CheckListItems" so that searches could be 
easily performed. If you want these classes to be automatically 
cataloged you'll probably want to subclass from "CatalogAware", though I 
haven't actually used it myself for a long time. The tricky part with 
ZClasses is that you need to be careful to get the parent classes right 
at the beginning. There's no easy/supported/dependable way, yet, to 
change your mind later.

	Before I mention another approach (ZPatterns) let me say:

	1) It's true that active development of new features of ZPatterns 
has basically stopped since the primary developers are now moving on the 
stage 2, TransWarp.

	2) The current "release" of ZPatterns doesn't work "as is" with 
Zope 2.4.x. Steve Alexander has been very helpfully providing his own 
patches (along with some other folks' contributions) as another product 
"TransactionAgents" which does work in 2.4.x. You can get this at:

http://www.cat-box.net/steve/TransactionAgents-0.0.4.tar.gz

	3) There is an active ZPatterns "group" with CVS archives/mailing 
list etc. You can find out more at: http://www.eby-sarna.com/.

Now, for better or worse, here's what I really think:

	Since you say your are "fairly versed" in development and python, I 
should also suggest you look into ZPatterns before putting in a lot of 
work. I've got some simple examples of ZPatterns in my member area you 
might visit:

http://www.zope.org/Members/sspickle

It's a bit of a learning curve to grok ZPatterns (but so is Zope in 
general!) but it does two important things for you:

1) Provides a way for you to start your design in ZODB, and later, if 
necessary, migrate to RDBMS with little disruption.

2) Gives you a number of great tools for adding "triggers" (e.g., 
automatic cataloging) and externally provided attributes (e.g., we have 
this RDBMS with serial numbers etc... how do I get that "into" my app?).

Anyway... simple ZClasses are "simple"... and that's good. With 
ZPatterns you can use ZClasses, but also take advantage of lots of other 
good work to allow your app to expand beyond the "testing" stage. You 
can also use filesystem based classes if you need them. It would surely 
be best to play around with ZClasses a while before even thinking about 
other ways, such as ZPatterns.

Anyway.. hope I didn't confuse you! Bottom line: Start with ZClasses, 
learn the ropes, then look around a bit before making a big investment.

good luck!
-steve


On Sunday, November 25, 2001, at 02:20 AM, Jeremy Lowery wrote:

> I've just got involved with Zope, but I'm fairly versued in traditional 
> web development, and python.
>
> I'm currently working on an app that tracks seting up computers based 
> on a "check list" type deal, and who was responsible for it. If this 
> were just a static "check list" of things that had to be done, this 
> would be easy, but it needs the facilities to allow users to make new 
> check lists, edit them, and destroy them.
>
> Since I'm not an old pro at Zope, I figured that I would just use some 
> ZClasses to represent these things. My question is, what would be the 
> easiest (as far as time, and need of indepth knowledge of Zope) way to 
> do this? The ideas I have are...to let users enter in Check List items 
> and then dynamically generate Zope Objects that represent each check 
> list...Or another way would be to have Zope objects for all the check 
> list items, and the check lists, and then more objects for the actual 
> data stored in the check lists (Like who installed this piece of 
> software, and what is the Computer's Service and Serial numbers.)
>
> As I said, the main purpose of this post is to get design ideas. 
> Origionally, I had set this up in a RDBMS but that would cause too much 
> overhead.
>
> Jeremy
>
> _________________________________________________________________
> Get your FREE download of MSN Explorer at 
> http://explorer.msn.com/intl.asp
>
>
> _______________________________________________
> Zope maillist  -  Zope@zope.org
> http://lists.zope.org/mailman/listinfo/zope
> **   No cross posts or HTML encoding!  **
> (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce
> http://lists.zope.org/mailman/listinfo/zope-dev )