@@ -137,7 +137,9 @@ code:
137
137
138
138
.. tip::
139
139
140
- To learn more about the
140
+ To learn more about the ``create()`` method, see
141
+ :meth:`~django.db.models.query.QuerySet.create()` in the {+framework+}
142
+ documentation.
141
143
142
144
.. _django-crud-read:
143
145
@@ -174,6 +176,12 @@ returns ``Movie`` objects that represent movies released on January 1, 2000:
174
176
<Movie: First Person Plural>, <Movie: Just, Melvin: Just Evil>, <Movie: Sound and Fury>,
175
177
<Movie: Peppermint Candy>]>
176
178
179
+ .. tip::
180
+
181
+ To learn more about the ``filter()`` method, see
182
+ :meth:`~django.db.models.query.QuerySet.filter()` in the {+framework+}
183
+ documentation.
184
+
177
185
Return One Document Example
178
186
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
179
187
@@ -206,8 +214,11 @@ retrieves a document in which the ``title`` value is ``"Boyhood"``:
206
214
207
215
Movie.objects.filter(title="Boyhood").first()
208
216
209
- .. TODO: To learn more about the ``first()`` method, see
210
- :ref:`` in the Specify a Query guide.
217
+ .. tip::
218
+
219
+ To learn more about the ``get()`` method, see
220
+ :meth:`~django.db.models.query.QuerySet.get()` in the {+framework+}
221
+ documentation.
211
222
212
223
.. _django-crud-modify:
213
224
@@ -244,6 +255,12 @@ a document that has a ``title`` value of ``"High Fidelity"`` and adds a
244
255
// Outputs the number of modified documents
245
256
1
246
257
258
+ .. tip::
259
+
260
+ To learn more about the ``update()`` method, see
261
+ :meth:`~django.db.models.query.QuerySet.update()` in the {+framework+}
262
+ documentation.
263
+
247
264
.. _django-crud-delete:
248
265
249
266
Delete Documents
@@ -276,6 +293,12 @@ and deletes documents that have a ``runtime`` value of ``5``:
276
293
// Outputs the number of deleted documents and objects
277
294
(16, {'sample_mflix.Movie': 16})
278
295
296
+ .. tip::
297
+
298
+ To learn more about the ``delete()`` method, see
299
+ :meth:`~django.db.models.query.QuerySet.delete()` in the {+framework+}
300
+ documentation.
301
+
279
302
280
303
Additional Information
281
304
----------------------
0 commit comments