1.support dynamic registration model

2.support aggregete func
This commit is contained in:
AllenX2018
2021-01-04 16:29:03 +08:00
parent c1b7fa5381
commit 30dbf8fc3a
6 changed files with 124 additions and 26 deletions

View File

@@ -255,6 +255,22 @@ func NewTM() *TM {
return obj
}
type DeptInfo struct {
ID int `orm:"column(id)"`
Created time.Time `orm:"auto_now_add"`
DeptName string
EmployeeName string
Salary int
}
type UnregisterModel struct {
ID int `orm:"column(id)"`
Created time.Time `orm:"auto_now_add"`
DeptName string
EmployeeName string
Salary int
}
type User struct {
ID int `orm:"column(id)"`
UserName string `orm:"size(30);unique"`