mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Alphabetized imports in various docs.
Follow-up ofd97cce3409and7d3fe36c62.
This commit is contained in:
@@ -38,8 +38,8 @@ many projects they are typically the most commonly used views.
|
||||
|
||||
**Example myapp/views.py**::
|
||||
|
||||
from django.views.generic.detail import DetailView
|
||||
from django.utils import timezone
|
||||
from django.views.generic.detail import DetailView
|
||||
|
||||
from articles.models import Article
|
||||
|
||||
@@ -107,8 +107,8 @@ many projects they are typically the most commonly used views.
|
||||
|
||||
**Example views.py**::
|
||||
|
||||
from django.views.generic.list import ListView
|
||||
from django.utils import timezone
|
||||
from django.views.generic.list import ListView
|
||||
|
||||
from articles.models import Article
|
||||
|
||||
|
||||
@@ -15,8 +15,8 @@ editing content:
|
||||
Some of the examples on this page assume that an ``Author`` model has been
|
||||
defined as follows in ``myapp/models.py``::
|
||||
|
||||
from django.urls import reverse
|
||||
from django.db import models
|
||||
from django.urls import reverse
|
||||
|
||||
class Author(models.Model):
|
||||
name = models.CharField(max_length=200)
|
||||
@@ -226,8 +226,8 @@ editing content:
|
||||
|
||||
**Example myapp/views.py**::
|
||||
|
||||
from django.views.generic.edit import DeleteView
|
||||
from django.urls import reverse_lazy
|
||||
from django.views.generic.edit import DeleteView
|
||||
from myapp.models import Author
|
||||
|
||||
class AuthorDelete(DeleteView):
|
||||
|
||||
Reference in New Issue
Block a user