随笔分类 - Django框架
摘要:from django.db import models# Create your models here.class Book(models.Model): title = models.CharField(max_length=32) price = models.DecimalField(ma
阅读全文
摘要:from django.shortcuts import render,HttpResponse,redirectfrom book.models import Bookfrom django.urls import reverseimport datetime# Create your views
阅读全文
摘要:from django.shortcuts import render,HttpResponse,redirectfrom book.models import Bookfrom django.urls import reverseimport datetime# Create your views
阅读全文
摘要:"""mysite URL ConfigurationThe `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/3.2/topics/
阅读全文
摘要:from django.shortcuts import render,HttpResponsefrom book.models import Bookimport datetime# Create your views here.def add_book(request): if request.
阅读全文
摘要:from django.shortcuts import render,HttpResponsefrom book.models import Bookimport datetime# Create your views here.def add_book(request): if request.
阅读全文
摘要:from django.shortcuts import render,HttpResponsefrom book.models import Bookimport datetime# Create your views here.def add_book(request): if request.
阅读全文
摘要:from django.shortcuts import render,HttpResponsefrom book.models import Bookimport datetime# Create your views here.def add_book(request): if request.
阅读全文
摘要:from django.shortcuts import render,HttpResponsefrom book.models import Bookimport datetime# Create your views here.def add_book(request): #添加书籍 # 方式1
阅读全文
摘要:from django.db import models# Create your models here.class Book(models.Model): id = models.AutoField(primary_key=True) #自增类型 title = models.CharField
阅读全文
摘要:from django.db import models# Create your models here.'''create table t1( name varchar (32) unique not null age int xxx double 8 2 )'''class Ncov(mode
阅读全文
摘要:"""Django settings for mysite project.Generated by 'django-admin startproject' using Django 3.2.For more information on this file, seehttps://docs.dja
阅读全文
摘要:PyMySQL是从Python连接到MySQL数据库服务器的接口, 简单理解就是,Pymysql是python操作mysql数据库的三方模块。就是可以理解为可以在python中连接数据库写MySQL命令。 一 。Pymysql使用基本流程 1、要有mysql数据库 2、要有python 3、要有py
阅读全文
摘要:<!doctype html><html lang="zh-CN"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="
阅读全文
摘要:"""mysite URL ConfigurationThe `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/3.2/topics/
阅读全文
摘要:"""mysite URL ConfigurationThe `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/3.2/topics/
阅读全文
摘要:"""mysite URL ConfigurationThe `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/3.2/topics/
阅读全文
摘要:"""mysite URL ConfigurationThe `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/3.2/topics/
阅读全文
摘要:<!doctype html><html lang="zh-CN"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="
阅读全文
摘要:链接地址: https://v3.bootcss.com/examples/theme/ view-source:https://v3.bootcss.com/examples/theme/ https://2019ncov.chinacdc.cn/JKZX/yq_20220401.json """
阅读全文