File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change @@ -84,17 +84,6 @@ Add ingredients as INSTALLED_APPS:
84
84
' cookbook.ingredients' ,
85
85
]
86
86
87
- Register models with admin panel:
88
-
89
- .. code :: python
90
-
91
- # cookbook/ingredients/admin.py
92
- from django.contrib import admin
93
- from cookbook.ingredients.models import Category, Ingredient
94
-
95
- admin.site.register(Category)
96
- admin.site.register(Ingredient)
97
-
98
87
99
88
Don't forget to create & run migrations:
100
89
@@ -124,6 +113,18 @@ Alternatively you can use the Django admin interface to create some data
124
113
yourself. You'll need to run the development server (see below), and
125
114
create a login for yourself too (``./manage.py createsuperuser ``).
126
115
116
+ Register models with admin panel:
117
+
118
+ .. code :: python
119
+
120
+ # cookbook/ingredients/admin.py
121
+ from django.contrib import admin
122
+ from cookbook.ingredients.models import Category, Ingredient
123
+
124
+ admin.site.register(Category)
125
+ admin.site.register(Ingredient)
126
+
127
+
127
128
Hello GraphQL - Schema and Object Types
128
129
---------------------------------------
129
130
You can’t perform that action at this time.
0 commit comments