I have a table of Rates:
class Rate( models.Model ):
edition = ForeignKey( Edition )
description = ForeignKey( Foo )
rate = IntegerField( )
...
[ other fields not relevant here ]
and a RateForm:
class RateForm( forms.ModelForm ):
class Meta:
fields = ( 'description',
You can override the delete function of your model to take care of this.
Alternatively, if you want to do this for a bunch of different models, it might
be cleaner to use signals.
Shawn
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post
It would be nice if contrib.auth threw signals for auth attempts.
I don't think a custom auth backend would be the best solution, because a
custom auth backend as described in the documentation doesn't receive the
request object, which is where the stuff you want (such as IP address) can be
any firewall??
On Sat, May 29, 2010 at 8:03 PM, gin tonic wrote:
> My development server is running but when I attempt to access it at
> the localhost 127.0.0.1:8000 I receive a page not found error while my
> command shell shows no attempt to access the site.
>
> No
My development server is running but when I attempt to access it at
the localhost 127.0.0.1:8000 I receive a page not found error while my
command shell shows no attempt to access the site.
No error messages.
No sign of a connection attempt.
Anyone ever seen this before?
Thanks.
--
You
I'm developing an intranet application where one of the requested
features is having a detailed log containing entries of IP, user and
timestamp every time someone has logged in successfully. Also as a
bonus feature I'd like to implement a log of failed login attempts.
What would be the cleanest
Hi.
here is the code: http://pastebin.com/HtNq52aV
what i am trying to do::
get the visitor location from his IP address in {{latitude}} and
{{longitude}} . get my business location in
{{BUSINESS_LOCATION}} . then trace a route from visitor location
to my business location.
On May 25,
Django-users:
Our tests take too long to run, so I'm spending the weekend sketching
an alternate fixture system, based on RoR's "factory girl".
The fixtures inject model objects directly into the current namespace,
but this test fails:
class UseFactorySquirrelTests(TestCase,
On May 29, 2:47 pm, Ogi Vranesic wrote:
> Hi
>
> I formated with python numbers like e.g.:
>
> " 3457.50"
> " 11450.25"
>
> but my problem is to show them correctly one below the other
> in a column by django templates
> because the blank spaces are ignored.
> I tried with the
Anyone?
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this
Yep, it applies then, becuase I am using jQuery 1.4 and I'm using
$.post to send the stuff to the server, with a "json" paramater at the
end.
Thanks for the link James
On May 29, 5:26 am, Euan Goddard
wrote:
> Yeah jQuery added this annoying "feature" in 1.4.
>
Hi all,
I guess this is a PATH/PYTHONPATH error, but my attempts failed so far
to make django working.
System is Ubuntu 10.04, 64bit. Python version: 2.6.5:
@mx:~/webapps$ python -V
Python 2.6.5
When I run django-admin.py, the following happens:
mx:~/webapps$ django-admin.py
Traceback (most
Don't know if you're still interested, Ben,
But I just came across this as I was searching for the best place to
tell someone how the django CommaSeparatedIntegerField(CSIF) should be
changed.
I was basically trying to do the same thing you were.
After, taking a look at the django code, I found
Hi
I formated with python numbers like e.g.:
" 3457.50"
" 11450.25"
but my problem is to show them correctly one below the other
in a column by django templates
because the blank spaces are ignored.
I tried with the filter escape, however it does not work.
A solution would be to loop over
See also:
http://birdhouse.org/blog/2009/06/27/django-profiles/
./s
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
Hi Pankaj
here you may refer my blog where i explain how you may extend some
fields while registration.
http://praveensunsetpoint.wordpress.com/category/django/django-registration-profile/
Praveen
On May 29, 4:41 pm, Pankaj Singh
wrote:
> I tried extending
Did you really mean for commit=FALSE or pre_save signal???
Praveen
On May 29, 5:22 pm, Euan Goddard
wrote:
> Hi,
>
> Could you explain the situation in a little more detail as I don't
> quite follow what you mean. As far as I'm aware if you have something
> like
Error describes well. your request key is not exist while rendering.
are you rendering your 'request' variable to page. and what is the
request here.
Thanks
Praveen
On May 29, 5:37 pm, Victor Fontes wrote:
> I get an error in this line:
>
> class="first">Inicio
>
> Everyting
I get an error in this line:
Inicio
Everyting was working just fine and all of a sudden I started to get
this error:
http://dpaste.com/200702/
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to
Yeah jQuery added this annoying "feature" in 1.4.
There's no "nice" way around it other than to recognise that any JS
arrays will have this suffix.
Euan
On 29 May, 05:33, pyfreak wrote:
> I accept this as normal now. I think, what I'll need to do if I'm
> against
Hi,
Could you explain the situation in a little more detail as I don't
quite follow what you mean. As far as I'm aware if you have something
like the following:
>>> my_inst = MyModel(foo="bar", ...)
>>> my_inst.save()
You'll have the pk at this point even if the transaction hasn't been
I tried extending RegistrationFormUniqueEmail
class CustomRegistrationFormUniqueEmail(RegistrationFormUniqueEmail):
first_name = forms.CharField(label=_('First name'),
max_length=30,required=True)
last_name = forms.CharField(label=_('Last name'), max_length=30,
required=True)
def
Hi
I want to extend django-registration form by adding fields like
first name
last name
date of birth
country
languages you speak etc.
for my project ..
how should i proceed for this ..
--
--
--
Thanking You,
Pankaj Kumar Singh,
2nd Year Undergraduate Student,
Department of Agricultural and
Thanks. It does look helpful.
On Fri, May 28, 2010 at 3:48 AM, Richard Shebora wrote:
> Try...
>
> http://alpha.djangogenerator.com
>
> It will generate a substantial amount of boilerplate code for you.
> Including templates and various views for listing, editing and viewing
Hello, I am trying to figure out how to get a pk in the middle of a
transaction. I need to set a field in the model based on the
ID(default pk) to be given. As far as a i know, this ID should be
allocated during the transaction. So i would imagine it would do the
INSERT, then i could get the pk
Hi,
Is it possible to use Django with Google Fusion Tables
http://code.google.com/apis/fusiontables/ as the backend?
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To
26 matches
Mail list logo