Change GFK to FK

2014-09-28 Thread carlos
Hi, is posible to change GenericForeingnKey to ForeignKey without losing data? any link to explain the trick? I have an old application with GFK but now I want to FK moment but I will not lose data this is example my models old and below the new models http://pastebin.com/ym6Scrmd Cheers --

Re: Best way to use a 'all' QuerySet as a dict with id first

2014-09-28 Thread aRkadeFR
Thanks for the answer, I just wondered if there was a built-in solution in Django. On 27/09/14 06:01, tkdchen wrote: > > > On Saturday, September 27, 2014 9:06:58 PM UTC+8, aRkadeFR wrote: > > > > @James Brewer: > > If I change my code, I can have this user_ids list. > > btw, it's filter and n

Re: Django Generic Create VIew and Hidden fields

2014-09-28 Thread Tom Evans
On Sun, Sep 28, 2014 at 5:49 PM, Sabine Maennel wrote: > Can someone please help me with Create View? I have a hidden field and not > having it in the form causes Django to not store my object in the database. > It fails silently. > > So here are my files: > > model.py: > class Application(TimeSta

Django Generic Create VIew and Hidden fields

2014-09-28 Thread Sabine Maennel
Can someone please help me with Create View? I have a hidden field and not having it in the form causes Django to not store my object in the database. It fails silently. So here are my files: *model.py:* class Application(TimeStampedModel): name = models.CharField(max_length=50) applic

Re: Django 1.7 and Python 2.6

2014-09-28 Thread François Schiettecatte
Russell Thanks, this the answer I was looking for, I think virtualenv is the way to go. Cheers François On Sep 27, 2014, at 7:14 PM, Russell Keith-Magee wrote: > > Out of the box, it won't work - but if maintaining an internal fork that adds > Python 2.6 compatibility back in shouldn't be

Re: Re: Upgrading Django (to 1.7)

2014-09-28 Thread bobhaugen
Fred, thanks a jillion for the excellent advice! I obviously missed that bit in the data migration boilerplate. On Saturday, September 27, 2014 9:29:10 AM UTC-5, Fred Stluka wrote: > > Bob, > > Are you referring directly to the models by name in the data > migrations? That could be the probl