Re: Difficulty setting dynamic 'db_table' in Meta

2019-06-26 Thread Brock Hallenbeck
nd > return one check Error for each model with a db_table that doesn’t match > the desired naming scheme. > > Thanks, > > Adam > > On Wed, 26 Jun 2019 at 15:50, Brock Hallenbeck > wrote: > >> I am trying to modify django's default table naming scheme to

Difficulty setting dynamic 'db_table' in Meta

2019-06-26 Thread Brock Hallenbeck
I am trying to modify django's default table naming scheme to better suit my needs and am having some difficulty. In order to accomplish this I need access to the 'app_label' and 'model_name' attributes. However due to python's scoping, I am unable to do so in your standard Meta subclass. I ha

Re: Set formfield.initial when created using modelformset_factory

2018-05-23 Thread Brock Hallenbeck
r form, and > as you mention, as the initial value on the boundfield has that value you > expect. > > Hope this helps, > Collin > > > On Wed, May 23, 2018 at 2:04 PM, Brock Hallenbeck > wrote: > >> When creating a formset using modelformset_factory and passin

Set formfield.initial when created using modelformset_factory

2018-05-23 Thread Brock Hallenbeck
When creating a formset using modelformset_factory and passing in a list of dictionaries to use as initial values, those values can be retrieved from the relevant form, and the relevant boundfield on that form. However the formfield class itself has no knowledge of that initial data. Is this int

[Feature Request] Let manage.py ignore migration dependencies

2017-04-13 Thread Brock Hallenbeck
We are a municipality using Django to make a CRUD tool. Our use cases are usually some department in the town wants to do CRUD stuff so they come to us. Our dream is to make an app, plug in some models and be mostly done. However it is very common for us to need to use different databases. Due t