from pydantic import BaseModel class User(BaseModel): id: int name = 'Jane Doe'. 上面的例子,定义了一个User模型,继承自BaseModel,有2个字段, id 是一个整数 ...
確定! 回上一頁