On Tue, 15 Oct 2002, David Kaufman wrote:

> while this is statisfyingly powerful, and simple enough even for
> non-programmers to add, it too leads to template-as-language addiction, when
> the brain-rush resulting from the taste of power corrupts the normal,
> keep-it-simple sensibilities of the programmer:
> 
>     <repeat invoice_item type="greenbar_report">
>       <if test="__ROW_NUM__" assert="IS_ODD" set="row_color" value="green">
>       <else set="row_color" value="white">
>           $item_id | $item_name | $item_cost | $item_qty | $item_total
>     </repeat>
> 

I'll admit you've followed a pretty logical flow of how these things can
get really out of hand.

The downside of this, is that what Andy did, and what I did is of out
of our control when it comes to code added on by a user.  It's
possible in both systems for people to construct their own conditional
blocks, even though it's better that they don't.

I'd prefer to see
 
 [uber.customer payment-reminder]

in a template than

 [uber.conditional if:(overdue > 100) -> ]
   Your past due balance is over $100.  Please contact us to make
   plans regarding remittance.
 [uber.conditional else ]
   Just a friendly reminder that you currently carry a past due balance.
 [<- uber.conditional endif ]

The best we can do is make recommendations on what makes a good template,
and that means the programmer using either TT or UT needs to create better 
extensions for the document writers.

It's kind of wierd how all of these examples always fall back on invoices, 
bills, or other business documents.

--------------------
Christopher Josephes 
[EMAIL PROTECTED]

Reply via email to