1
0
mirror of https://github.com/django/django.git synced 2025-03-11 01:42:35 +00:00
Loïc Bistuer ed0ff913c6 Fixed #10506, #13793, #14891, #25201 -- Introduced new APIs to specify models' default and base managers.
This deprecates use_for_related_fields.

Old API:

class CustomManager(models.Model):
    use_for_related_fields = True

class Model(models.Model):
    custom_manager = CustomManager()

New API:

class Model(models.Model):
    custom_manager = CustomManager()

    class Meta:
        base_manager_name = 'custom_manager'

Refs #20932, #25897.

Thanks Carl Meyer for the guidance throughout this work.
Thanks Tim Graham for writing the docs.
2016-05-17 12:07:22 +07:00
..
2016-03-13 19:48:24 +01:00
2013-10-10 16:49:20 -04:00
2015-02-20 09:21:39 -05:00
2014-12-19 18:07:52 +01:00
2014-12-19 18:07:52 +01:00
2015-01-02 19:20:18 -05:00
2015-02-20 09:21:39 -05:00
2015-02-20 09:21:39 -05:00
2014-12-19 18:07:52 +01:00
2014-12-19 18:07:52 +01:00
2015-01-02 19:20:18 -05:00
2014-12-19 18:07:52 +01:00
2015-02-20 09:21:39 -05:00
2014-09-02 21:34:29 -04:00
2015-01-02 19:20:18 -05:00
2015-02-20 09:21:39 -05:00
2015-01-27 11:48:04 -05:00
2015-05-01 16:24:39 -04:00
2015-05-20 13:48:06 -04:00
2015-10-03 19:31:45 -04:00
2015-11-04 17:48:49 +01:00
2016-05-03 19:30:48 -04:00
2016-05-02 18:16:36 -04:00
2016-05-02 19:02:21 -04:00
2016-03-13 19:48:24 +01:00