JM-WechatMini/router/system/sys_initdb.go

18 lines
406 B
Go
Raw Normal View History

2023-11-02 04:34:46 +08:00
package system
import (
"github.com/gin-gonic/gin"
v1 "miniapp/api/v1"
)
type InitRouter struct{}
func (s *InitRouter) InitInitRouter(Router *gin.RouterGroup) {
initRouter := Router.Group("init")
dbApi := v1.ApiGroupApp.SystemApiGroup.DBApi
{
initRouter.POST("initdb", dbApi.InitDB) // 初始化数据库
initRouter.POST("checkdb", dbApi.CheckDB) // 检测是否需要初始化数据库
}
}