摘要:
from django.contrib import adminfrom .models import ProductModel,OrderModel,zhangfu,qizi,Student,Teacher# fields = ['title','content','author']#字段列表# 阅读全文
摘要:
"""djangoproject URL ConfigurationThe `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.1/ 阅读全文
摘要:
from django.shortcuts import render,HttpResponsefrom .models import ProductModel# Create your views here.# 所有的请求信息,都在request对象,视图函数的参数必须要有requestdef i 阅读全文
摘要:
from django.contrib import adminfrom django.urls import path,includefrom . import views# 当前的路由文件是总的路由文件urlpatterns = [ path('admin/', admin.site.urls) 阅读全文
摘要:
from django.db import modelsfrom django.utils.html import format_html# Create your models here.class CategoryModel(models.Model): name = models.CharFi 阅读全文