create.go 334 B

12345678910111213141516
  1. package wx_user
  2. import "hongze/hongze_yb/global"
  3. // Create 新增记录
  4. func (wxUser *WxUser) Create() (err error) {
  5. err = global.DEFAULT_MYSQL.Create(wxUser).Error
  6. return
  7. }
  8. // Create 新增记录
  9. func (wxUser *WxUser) Add() (id uint64,err error) {
  10. err = global.DEFAULT_MYSQL.Create(wxUser).Error
  11. id = wxUser.UserID
  12. return
  13. }