修改账号注册方法,以及邮箱协议对接

This commit is contained in:
zyj
2025-09-24 18:22:25 +08:00
parent 002419a7ed
commit 81ed379cf3
21 changed files with 1090 additions and 8 deletions

View File

@@ -0,0 +1,28 @@
package services
import (
"go-account-register/models"
"go-account-register/utils"
"time"
"gorm.io/gorm"
)
type BrowserInstanceService struct {
db *gorm.DB
}
func InitBrowserInstanceService() *BrowserInstanceService {
db := utils.GetDB()
return &BrowserInstanceService{db: db}
}
func (b *BrowserInstanceService) Create(params *models.BrowserInstance) {
b.db.Create(params)
}
func (b *BrowserInstanceService) Update(browserId string, params *models.BrowserInstance) {
params.UpdateTime = time.Now().Unix()
b.db.Model(&models.BrowserInstance{}).Updates(params)
}