📅  最后修改于: 2022-03-11 14:46:41.304000             🧑  作者: Mango
###### views.py #####
from .forms import CreateArticleForm
from django.views.generic import CreateView
class ArticleCreateView(CreateView):
form_class = CreateArticleForm
template_name = 'articles/create_article.html'
###### urls.py ######
from .views import ArticleCreateView
urlpatterns =[ path('articles/create/', ArticleCreateView.as_view()),]