《Django 5 By Example》阅读笔记:p17-p53

《Django 5 By Example》学习第2天,p17-p53总结,总计37页。

一、技术总结

1.数据库迁移

python manage.py makemigrations blog

python manage.py sqlmigrate blog 0001

python manage.py migrate

2.ORM

Django自带ORM。

3.view

(1)定义

p42, A Django view is just a Python function that receives a web request and returns a web response.

4.template

了解 tag, variable, filter即可,不是很理解为什么作者花那么多篇幅介绍。在实际开发中,前后端后前端多使用Vue或者React进行开发,而不是使用Django自带的模板。

二、英语总结(生词:2)

1.facet

p32, Django 5.0 introduces facet filters to the administration site, showcasing facet counts.

(1)facet:face("face, appearance")。

c. one side of a multi-sided object.本意多面物体(例如钻石)的某一面,在这里表示"a specific aspect of information"或者"a specific dimension of information".

(2)show vs showcase

show表示"to present sth in a straightforward way",而showcase强调"to present sth in a way that highlight its best qualities."。

2.sake

p51, This schema doesn't include Django middleware, for the sake of simplicity.

u.purpose or reason. for the sake of = because of。

三、其它

完成chapter 01阅读,总体来说跟着书上的代码敲可以保证代码能够正常运行,但引入新的概念的时候缺乏连接性,容易导致读者看完了,也敲完了,但容易忘了。

四、参考资料

1. 编程

(1) Antonio Melé,《Django 5 By Example》:https://book.douban.com/subject/37007362/

2. 英语

(1) Etymology Dictionary:https://www.etymonline.com

(2) Cambridge Dictionary:https://dictionary.cambridge.org

欢迎搜索及关注:编程人(a_codists)

相关推荐
徐先生 @_@|||28 分钟前
Palantir Foundry 五层架构模型详解
开发语言·python·深度学习·算法·机器学习·架构
深蓝电商API1 小时前
Scrapy爬虫限速与并发控制最佳实践
爬虫·python·scrapy
Derrick__11 小时前
淘宝MD5爬虫
爬虫·python
薛定谔的猫19821 小时前
llama-index Embedding 落地到 RAG 系统
开发语言·人工智能·python·llama-index
nimadan123 小时前
**手机小说扫榜工具2025推荐,精准追踪榜单动态与题材风向
python·智能手机
编程武士3 小时前
Python 各版本主要变化速览
开发语言·python
傻啦嘿哟3 小时前
Python中的@property:优雅控制类成员访问的魔法
前端·数据库·python
sky17204 小时前
VectorStoreRetriever 三种搜索类型
python·langchain
旦莫4 小时前
Python测试开发工具库:日志脱敏工具(敏感信息自动屏蔽)
python·测试开发·自动化·ai测试
唐叔在学习4 小时前
Python自动化指令进阶:UAC提权
后端·python