django使用mysql数据库: 首先cmd创建库 1.settings: """Django settings for day42 project. Generated by 'django-admin startproject' using Django 1.11.26. For more information on this file, seehttps://docs.djangoproject.com/en/1.11/topics/settings/ For th…
from django.db import models # Create your models here. class Category(models.Model): caption = models.CharField(max_length=) class ArticleType(models.Model): caption = models.CharField(max_length=) class Article(models.Model): title = models.CharFie…