router.go 3.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. package routers
  2. import (
  3. "github.com/astaxie/beego"
  4. "wuyebaoxiuapi/controllers/backgroundc"
  5. "wuyebaoxiuapi/controllers/frontc"
  6. )
  7. func init() {
  8. // 默认登录
  9. beego.Router("/", &backgroundc.ApiDocController{}, "*:Index")
  10. beego.Router("/login", &backgroundc.LoginController{}, "*:LoginIn")
  11. beego.Router("/login_out", &backgroundc.LoginController{}, "*:LoginOut")
  12. beego.Router("/no_auth", &backgroundc.LoginController{}, "*:NoAuth")
  13. beego.Router("/home", &backgroundc.HomeController{}, "*:Index")
  14. beego.Router("/home/start", &backgroundc.HomeController{}, "*:Start")
  15. beego.AutoRouter(&backgroundc.ApiController{})
  16. beego.AutoRouter(&backgroundc.ApiSourceController{})
  17. beego.AutoRouter(&backgroundc.ApiPublicController{})
  18. beego.AutoRouter(&backgroundc.TemplateController{})
  19. beego.AutoRouter(&backgroundc.ApiDocController{})
  20. // beego.AutoRouter(&controllers.ApiMonitorController{})
  21. beego.AutoRouter(&backgroundc.EnvController{})
  22. beego.AutoRouter(&backgroundc.CodeController{})
  23. beego.AutoRouter(&backgroundc.GroupController{})
  24. beego.AutoRouter(&backgroundc.AuthController{})
  25. beego.AutoRouter(&backgroundc.RoleController{})
  26. beego.AutoRouter(&backgroundc.AdminController{})
  27. beego.AutoRouter(&backgroundc.UserController{})
  28. beego.Router("/uploadimg", &backgroundc.UploadController{}, "*:UploadImage")
  29. beego.Router("/propertynotice/edit", &backgroundc.PropertyNoticeController{}, "*:Edit")
  30. beego.Router("/propertynotice/add", &backgroundc.PropertyNoticeController{}, "*:Add")
  31. beego.Router("/propertynotice/index", &backgroundc.PropertyNoticeController{}, "*:Index")
  32. beego.Router("/propertynotice/del", &backgroundc.PropertyNoticeController{}, "*:Del")
  33. // 用户登录
  34. beego.Router("/user/login", &frontc.LoginController{}, "*:Login")
  35. // 更新密码
  36. beego.Router("/user/updatePassword", &frontc.UserController{}, "*:UpdatePassword")
  37. // 更新头像
  38. beego.Router("/user/updateAvatarUrl", &frontc.UserController{}, "*:UpdateAvatarUrl")
  39. // 更新学校
  40. beego.Router("/user/updateSchool", &frontc.UserController{}, "*:UpdateSchool")
  41. // 更新日常地址
  42. beego.Router("/user/updateDailyAddress", &frontc.UserController{}, "*:UpdateDailyAddress")
  43. // 更新手机号码
  44. beego.Router("/user/updatepPhone", &frontc.UserController{}, "*:UpdatepPhone")
  45. // 报修
  46. beego.Router("/repair", &frontc.RepairController{}, "*:Repair")
  47. // 报修用户报修数量
  48. beego.Router("/userRepairCount", &frontc.UserRepairController{}, "*:UserRepairCount")
  49. // 管理员报修数量
  50. beego.Router("/adminRepairCount", &frontc.UserRepairController{}, "*:AdminRepairCount")
  51. // 维修工人
  52. beego.Router("/repairWorkers", &frontc.UserRepairController{}, "*:RepairWorkers")
  53. // 管理员待维修列表
  54. beego.Router("/adminWRepairs", &frontc.UserRepairController{}, "*:AdminWRepairs")
  55. // 管理员已维修列表
  56. beego.Router("/adminHRepairs", &frontc.UserRepairController{}, "*:AdminHRepairs")
  57. // 报修用户报修列表
  58. beego.Router("/repairUserRepairs", &frontc.UserRepairController{}, "*:RepairUserRepairs")
  59. // 通知公告列表
  60. beego.Router("/pn/list", &frontc.PropertyNoticeController{}, "*:List")
  61. // 上传图片
  62. beego.Router("/uploadImage", &frontc.BaseController{}, "*:UploadImage")
  63. // 维修用户待维修列表
  64. beego.Router("/serviceUserWRepairs", &frontc.UserRepairController{}, "*:ServiceUserWRepairs")
  65. // 维修用户待维修列表
  66. beego.Router("/serviceUserHRepairs", &frontc.UserRepairController{}, "*:ServiceUserHRepairs")
  67. // 指派维修工人列表
  68. beego.Router("/assignRepairWorkers", &frontc.UserRepairController{}, "*:AssignRepairWorkers")
  69. // 指派维修任务
  70. beego.Router("/assignRepairTask", &frontc.UserRepairController{}, "*:AssignRepairTask")
  71. // 维修用户维修数量
  72. beego.Router("/repairUserRepairCount", &frontc.UserRepairController{}, "*:RepairUserRepairCount")
  73. // 确认维修
  74. beego.Router("/confirmRepair", &frontc.UserRepairController{}, "*:ConfirmRepair")
  75. }