View code to auto-update FileField with pdf

2009-10-29 Thread bweiss
I've set up my app to generate a pdf file based on user selections (following these instructions here: http://www.20seven.org/journal/2008/11/pdf-generation-with-pisa-in-django.html). The code returns " return http.HttpResponse(result.getvalue(), \ mimetype='application/pdf')' prom

Multiple queryset filter parameters on same instance of related model

2009-10-06 Thread bweiss
I know it's possible to combine filter parameters, so as to return a queryset of objects that meet all the conditions. And it's also possible to perform filters on related models. Is it possible to do both at once? ie. Return a list of objects that have a related object meeting both of two condit

Defining subsets of "list" variable at template level

2009-08-06 Thread bweiss
Is there a simple way to do the following that I'm just not seeing, or am I looking at trying to write a custom tag? The functionality I need is similar to {% regroup %} but not quite the same... My app currently has a custom admin view in which I've defined a whole bunch of different lists, whi

Re: "For object in object_list: related_list="...

2009-07-29 Thread bweiss
29, 5:17 pm, Daniel Roseman wrote: > On Jul 29, 5:18 am, bweiss wrote: > > > > > I've got this to work in python shell mode, but am having trouble > > translating it into a django view, and am hoping someone can point out > > where I'm stuffing up. >

"For object in object_list: related_list="...

2009-07-28 Thread bweiss
I've got this to work in python shell mode, but am having trouble translating it into a django view, and am hoping someone can point out where I'm stuffing up. For background, I'm working with a database with two models: "Employees" and "Projects", joined by a ForeignKey field on the Project mode

"Lookups that span relationships" + objects.exclude()

2009-05-05 Thread bweiss
ications at all, and it *does* include the ones who have A1 as well as other qualifications. Can anyone suggest what I'm doing wrong? Thanks, Bianca On Apr 20, 10:54 am, Alex Gaynor wrote: > On Sun, Apr 19, 2009 at 8:48 PM, bweiss wrote: > > > I'm working on a database p

Writing a request filter to find objects without related objects

2009-04-19 Thread bweiss
s. Can anyone tell me if this is even possible, and if so, how I might go about it? Many thanks in advance for any help, BWeiss --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To pos