feat: standardize REST and RPC routes
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
package routers
|
||||
|
||||
import (
|
||||
"path"
|
||||
|
||||
"bsm/full/module/base/mgt/internal/logic/application"
|
||||
"bsm/full/module/base/mgt/internal/logic/department"
|
||||
"bsm/full/module/base/mgt/internal/logic/hello"
|
||||
@@ -14,9 +16,9 @@ import (
|
||||
"github.com/gin-gonic/gin"
|
||||
)
|
||||
|
||||
// 完成请求地址: ip:port/srvKey/group/xxx
|
||||
// 完成请求地址: ip:port/rest/srvKey/group/xxx
|
||||
func Register(srvKey string, engine *gin.Engine) {
|
||||
base := "/" + srvKey
|
||||
base := path.Join("/rest", srvKey)
|
||||
registerAnonymous(base, engine)
|
||||
registerRouters(base, engine)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user