Re: REMOVE ME

2012-07-28 Thread David Lam
Try this from manage.py shell >>>DjangoMailListSubscription.objects.filter(email="collective...@gmail.com").delete() On Jul 28, 2012, at 10:47 PM, Andrew Miller wrote: > > > On Sun, Jul 29, 2012 at 10:43 AM, forthfan wrote: > Hi all, > > Being lazy, I want Django to validate the stuff I rea

Re: {% spaceless %} abuse (?)

2012-07-06 Thread David Lam
On Fri, Jul 6, 2012 at 7:29 AM, Cal Leeming [Simplicity Media Ltd] < cal.leem...@simplicitymedialtd.co.uk> wrote: > -1 on removing spaceless. > > On pages where you have lots of rows in a loop, the amount of whitespace > you end up with can massively increase page loading times. > > Sure, you coul

Re: {% spaceless %} abuse (?)

2012-07-05 Thread David Lam
On Thu, Jul 5, 2012 at 5:00 PM, Russell Keith-Magee wrote: > On Fri, Jul 6, 2012 at 4:27 AM, David Lam wrote: > > hmm, kinda semi-noob, but heres my scenario > > > > I just started working on a fairly large Django project thats been around > > for a couple years. &

{% spaceless %} abuse (?)

2012-07-05 Thread David Lam
hmm, kinda semi-noob, but heres my scenario I just started working on a fairly large Django project thats been around for a couple years. In the templates, I see a lot of use of {% spaceless %} tags whose apparent function is solely to trim whitespace to reduce page size/page load time or someth

Re: Avoiding code repetition in views

2012-06-28 Thread David Lam
On Jun 28, 2012, at 3:20 PM, grimmus wrote: > Hi, > > I am doing a site for a DJ that lists upcoming gigs on each page. There's an > include file in each page template to output the list of gigs. > > I am wondering how i can pass the gig information to every page without > having to repeat th

Re: more than 1 level of belongsTo

2012-06-08 Thread David Lam
On Fri, Jun 8, 2012 at 5:56 AM, rahajiyev wrote: > Hi, I have a model Foo belongsTo Bar, which in turn belongsTo Xyzzy. > When I do $this->Foo->find('all'); > > sql dump shows that the SQL join is performed only for Foo->Bar, but > Xyzzy is never mentioned. > I tried all sorts of 'recursive' => 1