04 2020 档案

摘要:Flask 用的是 CBV, 原先的用户认证用的是自己写的一个 auth 的装饰器, 后面改成了在 before_request 中进行用户认证,而且应前端的要求, 当用户登陆认证失败后的 STATUS 要改为 401 (原先是用默认的 200)。当有了这两个改动后, 发现原先已写好的代码又出现了跨 阅读全文
posted @ 2020-04-11 19:36 neozheng 阅读(601) 评论(0) 推荐(0) 编辑
摘要:Class metaprogramming is the art of creating or customizing classes at runtime. Classes are first-class objects in Python, so a function can be used t 阅读全文
posted @ 2020-04-06 00:07 neozheng 阅读(99) 评论(0) 推荐(0) 编辑
摘要:Descriptors are a way of resuing the same access logic in multiple attributes. For example, field types in ORM such as the DjangoORM and SQL Alchemy a 阅读全文
posted @ 2020-04-02 00:52 neozheng 阅读(116) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示