Jorge Godoy wrote:
> But since I can use this employee structure in other projects, I'd like to
> make it as generic as possible and "plug it" into my applications.  (In fact,
> the application would start with all these basic modules and evolve to the
> specific activity that the client performs, for several clients and different
> activities, but I'd like to have this common base shared among all projects,
> so this example is not 100% accurate but it shows the problem.)
>
> What would be the best way to do that?  Entry points?  Plain modules?  How
> about using the specific layout -- master.kid and other templates -- for each
> client or application that depends on this common part?  What would be the
> best approach for that in TG 0.9 and later reusable on FirstClass?

For templating, to do something like this you really need multiple
template directory searches. Django and Myghty both have these
features, and I think Cheetah and others are picking them up too.
They've very important especially when you want to make it easy to
customize template parts of an application from "outside".

This is part of the reason why Ian Bicking's template API proposal
allows for a template finder API as well, so that every template
solution can be extended to have multiple directory template searching.

I wouldn't both with entry points, instead just make applications that
do each part of the step you want and have them provide a way to plugin
to the same database to store data. Perhaps you will need to create a
package that has some library functions you use in each app. If TG was
currently more friendly to WSGI middleware, I'd suggest having a WSGI
middleware component that takes care of common setup tasks required for
all the apps in your particular suite.

As for how to do this stuff with TG right now... unfortunately I can't
help much on that.

HTH,
Ben


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears Trunk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears-trunk
-~----------~----~----~----~------~----~------~--~---

Reply via email to