As I am a noob this is very possibly a stupid question
Basically I would like to be able to use composition to build some of
my models without having separate tables being created.
class baseClass:
field1
class foo(models.Model):
my_base = baseClass()
class bar(models
On Dec 10, 11:04 am, "Karen Tracey" <[EMAIL PROTECTED]> wrote:
> On Wed, Dec 10, 2008 at 1:51 PM, Mr. T <[EMAIL PROTECTED]> wrote:
>
> > As I am a noob this is very possibly a stupid question
>
> > Basically I would like to be able to use composi
response = serializers.serialize('xml', MySet.objects.all())
return HttpResponse(response , mimetype='text/xml;')
The output has each member of "MySet" with an tag, and then
within the object, a bunch of tags with each field. It seems
sort of hard to parse this on the client side.
Can anyone h
Just start with Django and liking it a lot. Made a database and a page
that displays queries as html table. It was all too easy.
In one of my models I use a Foreign key to ref another object.
class A:
class B:
a = ForeignKey(A)
When I include A in the context of my template, I see
I saw this in the docs:
"When Django deletes an object, it emulates the behavior of the SQL
constraint ON DELETE CASCADE -- in other words, any objects which had
foreign keys pointing at the object to be deleted will be deleted
along with it."
So it sounds like you don't need to do anything.
On
In the tutorial it is simply '/accounts/login'
This worked fine until I switched to a production apache server. My
login_required decorators were broken because the path is absolute,
login_required doesn't use the apache prefix.
What to do?
--~--~-~--~~~---~--~~
Y
Sorry, a QuerySet eval question. Yeah, I'm dumb I know.
My view is creating a query set, XXX.objects.all(). Stale data is
being served up all the time. Read the docs about generic views, when
sets are evaluated, some old posts in this group. Tried ._clone(),
tried iteration, tried len(), nothing
overlooked.
On Apr 10, 4:43 pm, Malcolm Tredinnick
wrote:
> On Fri, 2009-04-10 at 14:46 -0700, Mr. T wrote:
> > Sorry, a QuerySet eval question. Yeah, I'm dumb I know.
>
> > My view is creating a query set, XXX.objects.all(). Stale data is
> > being served up all the t
We've had something up and running for a while (but still developing).
Something that's been working is now broken somehow: when another
server logs out they report the connection was closed before they get
a final msg from our server.
My logout is pretty trivial
def logoff(request):
logout(
Pretty big WTF moment for me to debug what went wrong, eventually
discovering DJango's |date:"U" tempate filter is nonsense. It renders
to bogus values. Eventually found this:
http://tinyurl.com/rbop9g
Using 1.0. Has this been fixed?
--~--~-~--~~~---~--~~
You rece
Thanks!
On May 14, 1:28 pm, Alex Gaynor wrote:
> On Thu, May 14, 2009 at 3:20 PM, Mr. T wrote:
>
> > Pretty big WTF moment for me to debug what went wrong, eventually
> > discovering DJango's |date:"U" tempate filter is nonsense. It renders
> > to bogus v
I am a newbie at this Django development environment and my Python is
not as good as I would like it but I am still in the early stages of
learning, so any help is appreciated.
I have stumbled over a block which I can't yet get over so if anyone
can help I thank you in advance.
I need to display
I am having a bit of trouble posting checked items from a form to my
view so I can save it to a database table.
The data in the form are information that has been stripped from a
file so there is no database link/referencing there.
What I have done half works as it does post my selected items and
13 matches
Mail list logo