package routers import ( "Medical_ERP/controllers" beego "github.com/beego/beego/v2/server/web" ) func init() { // 分组 dosageForm := beego.NewNamespace("/api/dosage-form", beego.NSRouter("/list", &controllers.DosageFormController{}, "*:List"), beego.NSRouter("/detail", &controllers.DosageFormController{}, "*:Detail"), beego.NSRouter("/add", &controllers.DosageFormController{}, "*:Add"), beego.NSRouter("/edit", &controllers.DosageFormController{}, "*:Edit"), beego.NSRouter("/delete", &controllers.DosageFormController{}, "*:Delete"), ) //注册 namespace beego.AddNamespace(dosageForm) }