You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
773 B
20 lines
773 B
package system
|
|
|
|
import (
|
|
v1 "github.com/flipped-aurora/gin-vue-admin/server/api/v1"
|
|
"github.com/gin-gonic/gin"
|
|
)
|
|
|
|
type AutoCodeRouter struct{}
|
|
|
|
func (s *AutoCodeRouter) InitAutoCodeRouter(Router *gin.RouterGroup) {
|
|
autoCodeRouter := Router.Group("autoCode")
|
|
autoCodeApi := v1.ApiGroupApp.SystemApiGroup.AutoCodeApi
|
|
{
|
|
autoCodeRouter.GET("getDB", autoCodeApi.GetDB) // 获取数据库
|
|
autoCodeRouter.GET("getTables", autoCodeApi.GetTables) // 获取对应数据库的表
|
|
autoCodeRouter.GET("getColumn", autoCodeApi.GetColumn) // 获取指定表所有字段信息
|
|
autoCodeRouter.POST("preview", autoCodeApi.PreviewTemp) // 获取自动创建代码预览
|
|
autoCodeRouter.POST("createTemp", autoCodeApi.CreateTemp) // 创建自动化代码
|
|
}
|
|
}
|