Newbie question - setting a model form foriegn key

2012-10-01 Thread Keir Lawson
Sorry if this is a dumb question, just picking up Django. I've set up a payments form, to create payments associated with a contact (see payments model) however I'm having trouble figuring out how to save the payment with the relevant contact associated, as the contact isnt selected as part of

Re: Newbie question - setting a model form foriegn key

2012-10-02 Thread Keir Lawson
;form' : PaymentForm() >>> }) >>> return render_to_response('CRMSite/contact_payments.html',rctx) >>> >>rctx = RequestContext(request,{ >> On Tue, Oct 2, 2012 at 4:20 AM, Keir Lawson >> > wrote: >> >>> Sorry if this

Display only model fields that are non-empty

2012-10-11 Thread Keir Lawson
Hello, I was wondering what the most elegant way (using a DetailView or similar) to display the fields of a model, excluding those that are empty? Thanks Keir -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web