代码之家  ›  专栏  ›  技术社区  ›  Kr.98

如何设置列注释

  •  0
  • Kr.98  · 技术社区  · 7 年前

    我想用小马设置列注释,但找不到 comment 参数,

    我想要下面这样的评论栏

    class User(db.Entity):
        __tablename__ = 'account_collection'
        uid = Required(str, max_len=50, comment='unique user id')
        name = Required(str, max_len=50, comment='username')
    

    但它不会起作用 TypeError: Attribute User.uid has unknown option 'comment'

    0 回复  |  直到 7 年前
        1
  •  0
  •   sashaaero    7 年前

    小马还不支持任何评论。 也许有一天我们会添加这个功能。