interface_log.go 541 B

12345678910111213141516171819202122
  1. package cygx
  2. import (
  3. "github.com/beego/beego/v2/client/orm"
  4. "time"
  5. )
  6. type CygxInterfaceLog struct {
  7. Id int `orm:"column(id);pk"`
  8. Uid int `description:"用户ID "`
  9. Url string `description:"路由"`
  10. Method string `description:"请求方式"`
  11. Data string `description:"信息内容"`
  12. CreateTime time.Time `description:"创建时间"`
  13. }
  14. // 新增
  15. func AddCygxInterfaceLog(item *CygxInterfaceLog) (err error) {
  16. o := orm.NewOrmUsingDB("hz_cygx")
  17. _, err = o.Insert(item)
  18. return
  19. }