add @fk to note

添加外键注解。
This commit is contained in:
xxj
2021-02-02 15:16:10 +08:00
parent dccbfce68a
commit 689c8a30d9
10 changed files with 94 additions and 18 deletions

View File

@@ -147,7 +147,7 @@ func (m *sqliteModel) getTableElement(orm *gorm.DB, tab string) (el []model.Colu
var tmp model.ColumnsInfo
tmp.Name = v.Name
tmp.Type = v.Type
FixElementTag(&tmp, "")
FixNotes(&tmp, "")
if v.Pk == 1 { // 主键
tmp.Index = append(tmp.Index, model.KList{
Key: model.ColumnsKeyPrimary,