GenericRelations reverse accessors

2008-02-22 Thread Michael Elsdörfer
class Feature(models.Model): content_object = generic.GenericForeignKey() class Review(models.Model): features = GenericRelation(Feature) class Person(models.Model): features = GenericRelation(Feature) >> Person.objects.create() # id = 1 >> Review.objects.create() # id = 1 >>

Re: Adding a relative option to FilePathField

2008-02-22 Thread Justin Lilly
Fair enough. Forget I mentioned it :-/ On Fri, Feb 22, 2008 at 1:20 PM, [EMAIL PROTECTED] < [EMAIL PROTECTED]> wrote: > > I agree with Graham because you don't know where python will be > executed from what would the path be relative to? > > On Feb 22, 9:33 am, "Justin Lilly" <[EMAIL PROTECTED]>

Re: Adding a relative option to FilePathField

2008-02-22 Thread [EMAIL PROTECTED]
I agree with Graham because you don't know where python will be executed from what would the path be relative to? On Feb 22, 9:33 am, "Justin Lilly" <[EMAIL PROTECTED]> wrote: > I would personally vote on making it an optional parameter if RELATIVE_FIELD > (or something like that) is present. If

Don't Miss It ................

2008-02-22 Thread raja vathani
Adobe photoshop cs3 [image: Adobe photoshop cs3] Foreground Lighting mprove your portraits with this easy and effective foreground lighting

Hi Friend.........Tips 4u

2008-02-22 Thread raja vathani
Interior Design Ideas Episode Hi friends here u learn about interior design and how to make in AutoCAD u want any details please comments have a nice day enjoy and Learn This site provides great tutorials / lessons for the student of

Re: Adding a relative option to FilePathField

2008-02-22 Thread Justin Lilly
I would personally vote on making it an optional parameter if RELATIVE_FIELD (or something like that) is present. If it isn't present, require it just like always. -justin On Fri, Feb 22, 2008 at 9:46 AM, Graham Carlyle < [EMAIL PROTECTED]> wrote: > > In your example I think RELATIVE_FIELD would

Re: Adding a relative option to FilePathField

2008-02-22 Thread Graham Carlyle
In your example I think RELATIVE_FIELD would be relative to the django python process's current working directory which seems a bit arbitrary. Having an absolute path parameter seems a good thing, but storing this prefix for each record seems redundant and inflexible. Graham On Fri, 2008-02-22

Re: Adding a relative option to FilePathField

2008-02-22 Thread Justin Lilly
What would stop you from doing something akin to: upload = model.FilePathField(path=RELATIVE_FIELD, match="foo.*", recursive=True) where RELATIVE_FIELD is defined in your settings.py file? Perhaps I've missed the mark on this.. I'm relatively new to django-dev discussions. -justin On Fri, Feb

Adding a relative option to FilePathField

2008-02-22 Thread Graham Carlyle
I'd like to request that FilePathField should have an extra option that causes it to only save a relative path (to the path parameter), say called "relative". Having an absolute path stored makes it harder to move data between machines that are set up differently (say development and

$$$$$$$$www.200836.com tell you Beijing/peking2008 Summer Olympic Games Briefing on the relocation project for Olympic venues

2008-02-22 Thread 200836
$www.200836.com--- why we buy Peking 2008 Olympic Games― souvenirs 1 low price 2 best quality-- licensed products by Peking Organizing Committee 3 many products to choose 4 most precious―limited circulation 5,we accept all payment methods,such as paypal,credit card, telegraphic