Re: Denormalisation Magic, Round Two

2008-11-10 Thread David Cramer
I'm not sure on AggreateField either. What if you just do like ("Photo", "user__exact=self.user") or something. Currently there's no rerepsentation for "self" in Django QuerySet's, so this is a hard thing to call. Also, we need a way to support callables. e.g.

order_by_fields for django.contrib.admin

2008-11-10 Thread David Cramer
One of the last of my feature-needs (for optimization reasons) is the ability to specify what fields can, or can't be ordered in the admin apps. I'd like to propose something along the lines of: order_by_fields = ('field', 'field', 'field') This would allow you to only order by fields

select_related optimization and enhancement for the django.contrib.admin

2008-11-10 Thread David Cramer
While I've been working on composite primary keys, I also made a few tweaks to the admin app. Most of these are related to the primary key support, but one is an optimization. I would post this as a patch, or a ticket, but I want to open this up for discussion, and my django repo is so far from

ModelAdmin manager

2008-11-10 Thread SmileyChris
There are currently inconsistencies with how ModelAdmin decides on what query set (i.e. manager) it's using. Issue 1: The change list it uses ModelAdmin.queryset() while the change view uses ModelAdmin.model._default_manager Issue 2: Also, when searching, ChangeList uses the base QuerySet model

Re: login_required

2008-11-10 Thread John-Scott Atlakson
On Mon, Nov 10, 2008 at 3:38 PM, Sebastian Bauer <[EMAIL PROTECTED]> wrote: > but we can do this "little" modification in v1.1 > > i think this change will allow site administrator to ban users throughchange > is_active flag > > Waylan Limberg pisze: > > On Mon, Nov 10, 2008 at 2:49 PM,

Re: login_required

2008-11-10 Thread Sebastian Bauer
but we can do this "little" modification in v1.1 i think this change will allow site administrator to ban users through change is_active flag Waylan Limberg pisze: > On Mon, Nov 10, 2008 at 2:49 PM, Sebastian Bauer <[EMAIL PROTECTED]> wrote: > >> Hello, i think login_required should check

Re: login_required

2008-11-10 Thread Collin Grady
On Mon, Nov 10, 2008 at 11:49 AM, Sebastian Bauer <[EMAIL PROTECTED]> wrote: > Hello, i think login_required should check that user is not only > authenticated, but also if is active. What do you think about this change? I think you can write your own decorator to do that, and it would be a

Re: login_required

2008-11-10 Thread Waylan Limberg
On Mon, Nov 10, 2008 at 2:49 PM, Sebastian Bauer <[EMAIL PROTECTED]> wrote: > > Hello, i think login_required should check that user is not only > authenticated, but also if is active. What do you think about this change? > I see two problems with this: 1. This current behavior is fully

Re: #7611 contrib.auth PasswordResetTest requires specific templates for tests to pass

2008-11-10 Thread Matt Brown
Not intending to derail the test-skip angle (which sounds generally useful), but in this case, wouldn't a better fix be to eliminate the dependency on admin, by providing the needed templates in the auth test suite itself? PasswordResetTest could also duplicate the setup/ teardown methods used

login_required

2008-11-10 Thread Sebastian Bauer
Hello, i think login_required should check that user is not only authenticated, but also if is active. What do you think about this change? Sebastian --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django

Re: problem with inlineformset_factory

2008-11-10 Thread Petry
Hello Colling ok, but then did a test and saw that this problem is a bug in Django, with the database sqlite works, but is giving problems with postgresql On 7 nov, 01:38, "Collin Grady" <[EMAIL PROTECTED]> wrote: > Usage questions belong on the django-users list - this list is for the >

Re: Denormalisation Magic, Round Two

2008-11-10 Thread Andrew Godwin
A Mele wrote: > I have followed the discussions about denormalization and I really > would like to see this in trunk. I agree with Rusell, the syntax > should be more like Django's query syntax, but I think this kind of > field is very useful for a lot of projects. > I obviously agree, but

Re: unable to use django when not connect the network,what’s wrong??

2008-11-10 Thread Karen Tracey
Please post your question to djang-users. This list is for discussion of developing Django itself, not usage questions. Karen --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to

Django templates - Can I change the form field name in template dynamically?

2008-11-10 Thread ChelseaFC
I have a form with fields "num1" and "num2". Both are FloatField. In templates, i have too use something like the following: First Number: {{ form.num1}} {% if form.num1.errors %} {{ form.num1.errors|join:", " }} {% endif %} Second Number: {{

unable to use django when not connect the network,what’s wrong??

2008-11-10 Thread shuxiang
when my ubuntu8.10 not connect the Internet ,i use command “python manage.py runserver” and use firefox to view http://127.0.0.1:8080but it‘s strange that nothing show,no “it worked” page. but when connect the Internet it show the "it worked" page. i don't know why? it take too much money