Django-ORM

模型

模型是你的数据的唯一的、权威的信息源。它包含你所储存数据的必要字段和行为。通常,每个模型对应数据库中唯一的一张表。

A model class represents a database table, and an instance of that class represents a particular record in the database table.

一旦你建立好数据模型之后,django会自动生成一套数据库抽象的API,可以让你执行增删改查的操作。

 

posted @ 2017-08-24 20:47  Yuan先生  阅读(733)  评论(0编辑  收藏  举报