timemachine.go 963 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. package http
  2. import bm "go-common/library/net/http/blademaster"
  3. func timemachine2018(c *bm.Context) {
  4. v := new(struct {
  5. Mid int64 `form:"mid"`
  6. })
  7. if err := c.Bind(v); err != nil {
  8. return
  9. }
  10. midStr, _ := c.Get("mid")
  11. loginMid := midStr.(int64)
  12. c.JSON(tmSvc.Timemachine2018(c, loginMid, v.Mid))
  13. }
  14. func timemachine2018Raw(c *bm.Context) {
  15. v := new(struct {
  16. Mid int64 `form:"mid"`
  17. })
  18. if err := c.Bind(v); err != nil {
  19. return
  20. }
  21. midStr, _ := c.Get("mid")
  22. loginMid := midStr.(int64)
  23. c.JSON(tmSvc.Timemachine2018Raw(c, loginMid, v.Mid))
  24. }
  25. func timemachine2018Cache(c *bm.Context) {
  26. v := new(struct {
  27. Mid int64 `form:"mid"`
  28. })
  29. if err := c.Bind(v); err != nil {
  30. return
  31. }
  32. midStr, _ := c.Get("mid")
  33. loginMid := midStr.(int64)
  34. c.JSON(tmSvc.Timemachine2018Cache(c, loginMid, v.Mid))
  35. }
  36. //func startTmProc(c *bm.Context) {
  37. // c.JSON(nil, tmSvc.StartTmproc(c))
  38. //}
  39. //
  40. //func stopTmProc(c *bm.Context) {
  41. // c.JSON(nil, tmSvc.StopTmproc(c))
  42. //}