Formset inside Formset

2014-05-14 Thread rgreene
Good day, We have an inline formset where each instance of the form has a ManyToManyField for selecting countries. Here is the code: *# models* *class Geographic_Scope_Region(models.Model):* *# class name exception (underscore) because ManyToManyField assumes pk is lower(Table_Name) +

Editing existing data using Form Wizard

2014-05-05 Thread rgreene
Good day, The thread at http://stackoverflow.com/questions/13822975/django-form-wizard-to-edit-model shows an approach for using the form wizard to edit data. Is this approach still recommended? If so, I'm wondering how to initialize the data for a step based on a formset? Passing a single

Overriding Default Field Names

2014-05-05 Thread rgreene
Good day, Using a ManyToManyField as in the example below causes django to automatically instantiate a Model called country_region with fields country_id and region_id, which is very cool. But what if the region_country database table (for reasons beyond the scope of this thread) has field

Re: ManyToManyField causes invalid form when limit_choices_to argument set

2014-04-30 Thread rgreene
Solved! It turned out the problem only occurred trying to uncheck the last checkbox. I needed to set blank=True on the ManyToManyField. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails

ManyToManyField causes invalid form when limit_choices_to argument set

2014-04-30 Thread rgreene
Good day, This is a somewhat contrived example, but I'm having the same problem in a real project. Assuming continents have many countries, and countries can belong to many continents, I have a continent_country "junction" table in the database and am using ManyToManyField as follows...

Geodjango and Python 3.3

2014-03-25 Thread rgreene
Good day, I'm developing under Windows against a PostGIS database. On https://docs.djangoproject.com/en/1.7/ref/contrib/gis/install/#windows, Python 2.7 is shown in the installation steps. I've been reading up on Python 3.3 (for instance, https://wiki.python.org/moin/Python2orPython3), and as