OT Re: [Zope-DB] writing a template to test if the sql worked
Philip Kilner
phil at xfr.co.uk
Thu May 6 12:08:43 EDT 2004
Hi Charlie,
Charlie Clark wrote:
>>So, to apply this to a new process, I only need to define the formulator
>>objects, the sequence, and the results script and page - everything else
>>is now automated/generic.
>>
>>Re. the compartmentalisation, absolutely - each bit is intelligible.
>
> Yes, this is the key. As long as you're happy with it. I'd have to look at
> the source to get the full picture but it sounds reasonable, better in some
> ways than some of the things I've done. I really need to sit down with
> Formulator and see if I can't get my head around it.
>
I'm going to write this up as a "how to" very, very, soon - it's taken a
lot of blood, sweat and tears (nothing like a tantrum to blow the
cobwebs away!) to get this far, in large part I think because the
documentation (aside from the usual issues about fragmentation etc.)
simply isn't aimed at someone with my background (emphatically /not/ a
programmer, but a fair application developer with the right tools).
Zope is s-o-o-o close to my ideal, and I've picked up a lot of scar
tissue over Dreamweaver's take on writing data-driven web applications
(They make it easy to re-use /their/ code, but add little or no value
when it comes to re-using your /own/ work...unless you want to develop
components, which I don't!). I really think that with a non-trivial,
fully documented example, Zope would be a very accessible platform for
writing data-driven web apps - and you get all the other clever stuff it
can do "for free"!
Now I feel as though I've "tamed it" for my purposes, I'm very, very,
happy with Formulator. Not just because of the validation, but the
rendering, too.
>>Understood - in the scenario above, I initially set out merely to make
>>the formulator stuff generic. However, when I'd done that I was itching
>>to get the process /sequence/ out of the controlling script - which is
>>otherwise also completely generic.
>
> This is right way of doing things. Using TinyTable or the ZODB makes the
> process itself manageable and flexible.
>
I'm so pleased you said that - I'm pleased with the result, but I need
feedback!
> Acquisition can be painful. Namespaces and scopes are common gotchas
> everywhere.
>
The number of times I've cursed about error messages referring to
non-existent globals is without number...
> His approach is, essentially, similar to your own except he puts all the
> flow-control within a PythonScript. This makes a lot of sense for more
> complicated things than simply going through a sequence as you can use nice
> things like "dispatching" within Python. But then again the temptation is
> great to integrate real workflow for this as well.
That was my conclusion, having played about a little with DCWorkflow -
great tool for the appropriate job, but all my processes are linear at
the moment, so it's not indicated. I'd use work flow over script logic,
simply because I understand it better because - once again - it makes
the whole thing more "tangible" to me...
--
Regards,
PhilK
Email: phil at xfr.co.uk / Voicemail & Facsimile: 07092 070518
"The lyf so short, the craft so long to learne" - Chaucer
More information about the Zope-DB
mailing list