add commit

This commit is contained in:
xxj
2022-06-15 20:21:34 +08:00
parent b8cbd4fb30
commit dcf37c3802
2 changed files with 4 additions and 1 deletions

View File

@@ -192,6 +192,9 @@ func (m *_Model) genTableElement(cols []ColumnsInfo) (el []genstruct.GenElement)
if len(v.Gormt) > 0 {
tmp.AddTag(_tagGorm, v.Gormt)
}
if len(v.Notes) > 0 {
tmp.AddTag(_tagGorm, fmt.Sprintf("comment:'%v'", v.Notes))
}
} else {
tmp.AddTag(_tagGorm, "column:"+v.Name)
}