Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: DBIx::Class and Template toolkit context problem

by LTjake (Prior)
on Jan 05, 2010 at 15:42 UTC ( #815778=note: print w/ replies, xml ) Need Help??


in reply to DBIx::Class and Template toolkit context problem

All relationships should have an _rs method for exactly this issue. Try:

[% IF user.objects_rs.count %] ... [% END %]

FYI, this is a FAQ. (See "How do I use DBIx::Class objects in my TT templates?")

--
"Go up to the next female stranger you see and tell her that her "body is a wonderland."
My hypothesis is that she’ll be too busy laughing at you to even bother slapping you.
" (src)


Comment on Re: DBIx::Class and Template toolkit context problem
Download Code
Re^2: DBIx::Class and Template toolkit context problem
by Cybris (Sexton) on Jan 05, 2010 at 15:51 UTC

    Thank you very much, this is even better than my ugly workaround!

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://815778]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (10)
As of 2014-12-19 09:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (77 votes), past polls