List of Django Model _meta fields options and methods

written by Herman Schaaf on Jan. 22, 2011
Find me on Twitter, Google+ or LinkedIn

I've found out that it's almost impossible to find a list of all available _meta options for models in Django. Well, here is one, for both my own and your reference. Be warned, however, that these are internal options to the Django system, and can change at any time. But many of these are very useful indeed.

1 abstract
2 abstract_managers
3 add_field
4 add_virtual_field
5 admin
6 app_label
7 auto_created
8 auto_field
9 concrete_managers
10 contribute_to_class
11 db_table
12 db_tablespace
13 duplicate_targets
14 fields
15 get_add_permission
16 get_all_field_names
17 get_all_related_m2m_objects_with_model
18 get_all_related_many_to_many_objects
19 get_all_related_objects
20 get_all_related_objects_with_model
21 get_ancestor_link
22 get_base_chain
23 get_change_permission
24 get_delete_permission
25 get_field
26 get_field_by_name
27 get_fields_with_model
28 get_latest_by
29 get_m2m_with_model
30 get_ordered_objects
31 get_parent_list
32 has_auto_field
33 init_name_map
34 installed
35 local_fields
36 local_many_to_many
37 managed
38 many_to_many
39 module_name
40 object_name
41 order_with_respect_to
42 ordering
43 parents
44 permissions
45 pk
46 pk_index
47 proxy
48 proxy_for_model
49 setup_pk
50 setup_proxy
51 unique_together
52 verbose_name
53 verbose_name_plural
54 verbose_name_raw
55 virtual_fields


If you found this post interesting, you might also like our blog post, Django: It's DRY, but you can sink your teeth into it