修改mysql连接

This commit is contained in:
eson
2023-08-22 13:43:13 +08:00
parent d35ffd793a
commit 2dee02b6c5
29 changed files with 41 additions and 31 deletions

View File

@@ -1,10 +1,12 @@
package initalize
import (
"log"
"time"
"gorm.io/driver/mysql"
"gorm.io/gorm"
"gorm.io/gorm/schema"
"time"
)
// 初始化mysql
@@ -24,6 +26,7 @@ func InitMysql(sourceMysql string) *gorm.DB {
},
SkipDefaultTransaction: true,
})
log.Println(db.Rows())
if err != nil {
panic(err)
}