Re: URL dispatcher fallthrough?

2013-04-02 Thread David Danier
> David: The slugs wouldn't be overlapping if they inherited from some > sort of "Organization" model with unique slug. The user could also add > validation code to prevent company and schools having same slugs. If you have a common base model this sounds like some polymorphic model problem,

Re: URL dispatcher fallthrough?

2013-03-28 Thread David Danier
I'm with Tom here, this just feels wrong. The whole point of urls.py is to have a clean mapping of URLs to views. Of course I understand your problem, so let's look at the details. > // # front page for country > // / # list of schools and companies with activities > in that industry, in that

Re: ModelForms and the Rails input handling vulnerability

2012-06-13 Thread David Danier
Hi list, as I use "exclude" most of the times (to hide sensible fields from the user) I don't like the idea of this beeing removed. Perhaps another solution might be to force developers to either define fields _or_ exclude, so you have to at least think about this..without going through too much

Re: auth.User refactor: reboot

2012-03-16 Thread David Danier
Hi, sorry, if this was said before, I haven't read the latest user discussions. I'm in favor of enhancing the auth app step by step, as everything else seems unlikely (haven't happend for a long time, why should it now). What I dislike about the current auth app in general is that it solves

Re: ticket 13125 is waiting for a design decision for 18 months

2011-09-02 Thread David Danier
> Description: > "The login_required decorator is not checking User.is_active, as > staff_member_required does. If an authenticated user is deactivated > (via setting is_active to False), the user is still able to browse > login_required-protected views." > For probably most people, the expected

Re: [RFC] Moving from FormWizard to ViewWizard

2011-08-15 Thread David Danier
Hi Jannis, >> So, what do you think. Should we try to move forward to a ViewWizard? > *jumps in time machine* > Done! See [1] for the work Stephan and me did a few months ago. This really is nice, I like seeing the old FormWizard becoming more flexible and reusable. But not what I intended. The

Re: [RFC] Moving from FormWizard to ViewWizard

2011-08-15 Thread David Danier
Hi Jannis, > I think your intent is the same we had with refactoring the wizard -- > allowing access to the view state inside the wizard steps. Not only. I also tried to allow steps (=views) to completely move away from the current form based approach. This means each step can decide what to to

Re: [RFC] Moving from FormWizard to ViewWizard

2011-08-15 Thread David Danier
Hi Jannis, >> So, what do you think. Should we try to move forward to a ViewWizard? > *jumps in time machine* > Done! See [1] for the work Stephan and me did a few months ago. This really is nice, I like seeing the old FormWizard becoming more flexible and reusable. But not what I intended. The

[RFC] Moving from FormWizard to ViewWizard

2011-08-13 Thread David Danier
Hi, ich recently found myself fighting with FormWizard, again. I think its a known fact that the integrated wizard lacks features and needs to be refactored, but this time I struggled using one of the third-party implementations out in the wild (http://github.com/stephrdev/django-formwizard). The

Re: Django urls in JavaScript

2011-03-24 Thread David Danier
I currently handle this issue in a much easier way: I've created an app which allows creating a context for Javascript (this basically works like the template context processors do, calling defined functions and combining its results into a dict). The resulting context will be available in the

Re: One Django instance, hundreds of websites

2011-01-26 Thread David Danier
> On the other hand, having one setting file per site where the only difference > is the site id seems a bit too much overhead. Why not use something like this: from global_settings import * SITE_ID = 235 #This also allows further changes like: #INSTALLED_APPS = INSTALLED_APPS + ( #

Re: Ticket #7817: Extending "with" and "include" tags.

2010-10-27 Thread David Danier
> Other tags which currently use the "as" token are: cycle, regroup and > url. These all introduce a new variable into the current context, > which does differ slightly from how {% with %} alters a variable in a > contained scope. So my secondary (perhaps somewhat feeble) argument is > that this

Re: Feature proposal: escape hatch for colliding template syntax in django templates

2010-10-20 Thread David Danier
> If we're going to do this, could we also look at deprecating the > 'templatetag' template tag? There are a couple cases a 'verbatim' tag > wouldn't cover that 'templatetag' wouldn't, but I'm kinda hard-pressed > to think of when they'd ever come up in reality. +1 for this. I for one don't even

Re: Model translation

2010-08-07 Thread David Danier
ly touches most of the parts of Django (urls.py, QuerySet, views and of course models). I intentionally have left out some aspects, because they are not relevant to most users (for example translated content and full text search (haystack)). Thanks for reading this far, David Danier -- You rece

Re: Pass Thru Image Proxy Patch Interest?

2010-04-16 Thread David Danier
utting this into serve() always means a request to your local webserver which may lead to a HTTP-redirect (so we have two requests). Of course having a template tags means {{ MEDIA_URL }}path/to/file must be replaced everywhere in your templates. But I think it's worth the benefit. Greetings, David Danier -

Re: admin javacripts

2010-02-20 Thread David Danier
f sounds nice, but perhaps some sort of django namespace could be introduced. Meaning $jQD -> dj.$: var dj = {}; dj.$ = dj.jQuery = jQuery.noConflict(true); Greetings, David Danier -- You received this message because you are subscribed to the Google Groups "Django developers" g

Re: I need a pony: Model translations (aka "my proposal")

2009-08-25 Thread David Danier
t;>> fields = ('foo',) This way the translation system stays very extendable and may be used for some version-tracking-scenario while not supporting this itself. btw.: This is another reason why I want to always use a JOIN. Greetings, David Danier --~--~-~--~~---

Re: I need a pony: Model translations (aka "my proposal")

2009-08-19 Thread David Danier
attributes more easy. Using the Meta-subclass allows future ModelTranslation's to add/override fields to/of the original model and keeps this in sync with normal models (ModelTranslation could be a subclass of models.Model, using its own metaclass). Greetings, David Danier

Re: About multilingual models

2009-08-19 Thread David Danier
r default language without the need to tell it so (sites usually only display one translation at a time, of course there needs so exist some way to get all translations) Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed

Re: I need a pony: Model translations (aka "my proposal")

2009-08-02 Thread David Danier
e-model-i18n in a productive environment. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.c

Re: I need a pony: Model translations (aka "my proposal")

2009-07-14 Thread David Danier
e currently uses this. Foreign fields by design always need some JOIN related to them, so this will depend on conditional joins. If this gets implemented perhaps model inheritance can be rewritten to use foreign fields, as this looks like a more generic approach. Did I miss something? Greetin

I need a pony: Model translations (aka "my proposal")

2009-07-11 Thread David Danier
even start implementing this together. I am willing to spend some time with this topic, because I need some solution flexible enough (aka "fits my needs") for a client. Additionally I think django would very much benefit from a official solution on this topic. Greetings, David Danier --~

Re: unique_for_ fields

2008-10-01 Thread David Danier
r urls like /foo unique_together = ('slug', 'category', 'pub_date__year') Just some ideas I had when reading the original post, don't know if this would require lots of work. :) Greetings, David Danier --~--~-~--~~~---~--~~ You received this message b

Re: Make clickable area of object links larger

2008-07-13 Thread David Danier
s, too. So making the whole field () clickable should really be enough, the row itself (everything inside ) does not need to be clickable by default. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google

Re: Make clickable area of object links larger

2008-07-13 Thread David Danier
the whole field clickable, every other field can be made clickable by configuration, if someone wants. I don't like the idea of making the whole row clickable. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to t

Some ideas about AUTH_PROFILE_MODULE (tickets: #7584, #7592 and #7400)

2008-07-02 Thread David Danier
nes and should not cause any trouble I think. Of course docs are missing so far. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this grou

Re: XMLField in nfa

2008-07-01 Thread David Danier
ted some code that works here, but it doesn't fit into django in its current state. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to thi

Re: XMLField in nfa

2008-07-01 Thread David Danier
ils. The second ticket contains a XML-validator using lxml. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-de

Unify wraps() and update_wrapper() imports?

2008-06-28 Thread David Danier
, but this is somewhat different) Greetings, David Danier P.S.: I did not open a ticket on this, as I think, this needs discussion and such minor issues should not flood trac. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the

Re: API question for model saving

2008-04-28 Thread David Danier
e are a number of non-database uses for it. You don't have to stick to this names. I just used them, as I think they are pretty self-explainig. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: API question for model saving

2008-04-28 Thread David Danier
ems with naming the new parameter and difficulties in creating self-explaining possible values ("not must_create", rather than "must_not_create"). Just my 2 cents, David Danier --~--~-~--~~~---~--~~ You received this message because you are subsc

Re: newforms-admin and django.contrib.auth

2007-12-19 Thread David Danier
and clean permission-framework?). It looks to me like the "unreplaceable django.contrib.auth"-problem will be fixed (or worked around) only in the admin now, without considering adding this functionality to the entire django-framework. Greetings, David Danier --~--~-~--~~

Re: newforms-admin and django.contrib.auth

2007-12-18 Thread David Danier
before: It only fixes one application out of many. Instead replacing code like LogEntry.objects.log_action(...) with request.user.logentry_set.create(...) would help, not only in the admin. Greetings, David Danier --~--~-~--~~~---~--~~ You received th

Re: newforms-admin and django.contrib.auth

2007-12-18 Thread David Danier
the case when not using django.contrib.auth or not using an auth-system at all) and that it has a is_authenticated/message_set attribute (which might be ok, as this could be called "API" you need to reproduce). Greetings, David Danier --~--~-~--~~~---~--~

Re: ModelChoiceField's clean() uses default manager instead of query set

2007-08-07 Thread David Danier
may guess valid IDs that they should not use (for example if you use user_profile.some_relation as the queryset). Perhaps it could be changed to only allow choices in the queryset, but an option is added to ModelChoiceField to use the default manager? Greetings, Dav

About Changeset [5819]

2007-08-06 Thread David Danier
/models/fields/__init__.py?rev=5819#L785). Why is this done? If I read the code right self.upload_to gets stripped later in FileField.get_filename() and is added in File.get_directory_name(), again. Greetings, David Danier --~--~-~--~~~---~--~~ You received

Re: usability issues

2007-08-05 Thread David Danier
finitely needs to be put into your own middleware or view (which does the redirect). Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group,

Re: How submit a patch with files not in subversion?

2007-08-02 Thread David Danier
al.com/ Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from this group, send

Re: schema evolution

2007-07-23 Thread David Danier
that they screw the whole thing up easily. In a professional environment this might help having a nice way to deprecate things. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Dja

Re: #4001 - newforms commit=false and m2m data loss

2007-07-21 Thread David Danier
et called by it. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from thi

Re: Problem in current svn TRUNK

2007-07-11 Thread David Danier
ngoproject.com/wiki/UnicodeBranch#PortingApplicationsTheQuickChecklist Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to djang

Re: Unicode branch - last call for comments(?)

2007-07-04 Thread David Danier
> Well if I have understood what you say, it is exactly what is > explained here <http://code.djangoproject.com/wiki/ > UnicodeBranch#PortingApplicationsTheQuickChecklist>.. Right, now I feel dump. ;-) I even read the docs some time ago.... Greeting

Re: Shared memory across processes

2007-06-26 Thread David Danier
he settings-module should do the rest... Sorry if this is stupid and I miss some bigger picture here. ;-) Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group

Re: contrib.thumbnails approval?

2007-06-20 Thread David Danier
folder if the file does not exists any more. Perhaps this can even be done in some post_delete-signal-handler (iterate over all fields, find image-fields, delete thumbnail-folders). Greetings, David Danier --~--~-~--~~~---~--~~ You received this message becaus

Re: Ticket #3297 and File uploads

2007-06-04 Thread David Danier
ely with foreign languages' If you change the encoding of the request this might be fine, but the items in the dict returned by copy() should (/MUST?) look the same as the items in the original. Or am I missing something? Greetings, David Danier --~--~-~--~~~---~--~~

Re: Ticket #3297 and File uploads

2007-06-04 Thread David Danier
orm(new_data) But I think copy() already allocates memory, so the performance difference might be small. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group.

Re: newforms issues

2007-05-22 Thread David Danier
ta will get easier). And of course clean_FIELD() is not documented so far, which was the reason for changing its name to do_clean_FIELD() in some commit lately. So I don't see any reason why not to do this again to get things straight. Greetings, David Danier --~--~-~--~~~---~--~

Re: Changeset [5231] -- do_clean_*() is awkward naming

2007-05-14 Thread David Danier
en replaced by cleaned_data") clean_data = property(_clean_data_error) [...] Classes extending this can override clean_data with some method validating a data-field, users get some nice message, full_clean() writes to cleaned_data and this can be removed in the realese after the next one. Greetin

Re: Changeset [5231] -- do_clean_*() is awkward naming

2007-05-14 Thread David Danier
an_FIELD/clean__FIELD)? validate_FIELD sounds right, too. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers

Re: Merge some branches in before 1.0?

2007-04-30 Thread David Danier
ault, instead this can go into a different application). But the code seems mature and working, only some details are missing, if the current auth-solution should be kept. (Changing this might be better for post-1.0...but adding this now and changing it later may be worse than changing it now) G

Re: Maintaining a patched Django (was re: Templates: short comments {##} eats text)

2007-04-25 Thread David Danier
ild the patches: http://dpaste.com/hold/9043/ svk patch help: http://dpaste.com/hold/9044/ svk Homepage: http://svk.bestpractical.com/ Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups &quo

Re: Ticket #3297 (reopened) - FileField / ImageField - newforms

2007-04-23 Thread David Danier
need to do so)? Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from this g

Re: {% url %} for generic views (proposal)

2007-03-28 Thread David Danier
ed to a {% url %} refactoring, but if it can be done on the way it should be considered. Would really improve what you can do with include(). Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "D

Re: Newforms: colon after label

2007-03-27 Thread David Danier
is should stay default. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubsc

Re: Support for a binary storage field?

2007-03-26 Thread David Danier
us_ than a binary representation." Besides the other methods provide some optimization: "Protocol version 2 was introduced in Python 2.3. It provides much _more efficient_ pickling of new-style classes." Just my 2 cents, David Danier --~--~-~--~~~--

Re: newsessions

2007-03-15 Thread David Danier
any interface. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from thi

Re: newsessions

2007-03-13 Thread David Danier
ut I haven't seen this so far, nor searched for it. ;-) Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-devel

Re: Ticket 3688 -- Improve support for mutually-referential models

2007-03-09 Thread David Danier
? (except for looking nicer) 8<- from django.db.models.loading import get_model [...] models.ForeignKey(get_model('account', 'User')) --------->8 Greetings, David Danier --~--~-~--~~~---~--~~ You rece

Re: Possible bug: How does Django decide when to quote SQL arguments?

2007-03-07 Thread David Danier
> I found this query that isn't quoted correctly (I trimmed out some > stuff to make this shorter): AFAIK the queries are logged without quoting but executed correctly. (You can see this, if you have a SQL-error and the DB-backends throws an exception with the real query) Greetings,

Reworking the authentication and user-system (Was: Creating an independent auth/permission-framework, separate the models)

2007-03-06 Thread David Danier
ere, but I'm willing to change that if I get some positive response on this. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, s

Re: Creating an independent auth/permission-framework, separate the models (Was: Adding support for replacing the auth User model to fit custom needs)

2007-03-05 Thread David Danier
making things simpler for application-developers. For the permissions-system I would do similar. (One configuration-directive, some API thats fixed but allows model- and row-level-permissions) If you are interested I could try to contribute some code, too. ;-) Greetings, David Danier --~--~

Re: Model.add() ?

2007-03-01 Thread David Danier
ependent of save() and can be called directly (if you know what you do). Anyhow there needs to be some logic inside save(), of course. I'm not familiar with the current implementation of save(), so I don't know how complex it would be to accomplish this, but it sounds easy. Greetin

Re: Model.add() ?

2007-03-01 Thread David Danier
nk allowing the user to explicit use UPDATE or INSERT would be a nice feature. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, se

Re: Creating an independent auth/permission-framework, separate the models (Was: Adding support for replacing the auth User model to fit custom needs)

2007-02-27 Thread David Danier
). But it's nice to see separation the admin from the auth-app is on its way already. Greetings, David Danier --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this grou

Creating an independent auth/permission-framework, separate the models (Was: Adding support for replacing the auth User model to fit custom needs)

2007-02-19 Thread David Danier
e as it could be. And even better, it would simplify managing the auth-system as a whole (only small apps, that implement, provide or use some API). Greetings, David Danier P.S.: Sorry about the missing "In-Reply-To"-Header, I just joined this list. --~--~-~--~~--