随笔分类 - python 项目练习
摘要:import importlib res = 'myfile.b' ret = importlib.import_module(res) # from myfile import b # 该方法最小只能到py文件名 print(ret) def send_all(content): for path
阅读全文
摘要:1 多对多关系中,第三张表的建立 -默认使用ManyToMany,自动创建 -使用中介模型 -即手动创建第三张表,又要使用好用的查询 -完全自己写第三张表 # 使用中介模型 class Author(models.Model): nid = models.AutoField(primary_key=
阅读全文