common.go 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. package devices
  2. import "server/dao"
  3. type SearchInfo struct {
  4. Page int `json:"page" form:"page"` // 页码
  5. PageSize int `json:"pageSize" form:"pageSize"` // 每页大小
  6. ProjectId uint `json:"projectId" form:"projectId"` //关键字1
  7. Sn string `json:"sn" form:"sn"` //关键字2
  8. }
  9. type ReqScreens struct {
  10. ID uint `json:"id"` //ID
  11. ScreensName string `json:"screensName"` //名称
  12. Sn string `json:"sn"` //设备sn
  13. ProjectId uint `json:"projectId"` //归属项目id
  14. IpAddress string `json:"ipAddress"` //ip地址
  15. Remark string `json:"remark"` //备注
  16. }
  17. type ProgramReq struct {
  18. DeviceSn string `json:"deviceSn"`
  19. Program dao.Program `json:"program"`
  20. }
  21. type SoundPeriodReq struct {
  22. DeviceSn string `json:"deviceSn"`
  23. SoundPeriod dao.SoundPeriod `json:"soundPeriod"`
  24. }
  25. type SetDisContent struct {
  26. Num string `json:"num"`
  27. Effect string `json:"effect"`
  28. Speed string `json:"speed"`
  29. Stay string `json:"stay"`
  30. Total string `json:"total"`
  31. Color string `json:"color"`
  32. Content string `json:"content"`
  33. }
  34. type DiscontentJSON struct {
  35. Setdiscontent0 SetDisContent `json:"setdiscontent0"`
  36. }
  37. type SetPeropdtime struct {
  38. Time string `json:"time"`
  39. Period0 dao.IntArray `json:"period0"`
  40. Period1 dao.IntArray `json:"period1"`
  41. Period2 dao.IntArray `json:"period2"`
  42. Period3 dao.IntArray `json:"period3"`
  43. Period4 dao.IntArray `json:"period4"`
  44. Period5 dao.IntArray `json:"period5"`
  45. Period6 dao.IntArray `json:"period6"`
  46. Period7 dao.IntArray `json:"period7"`
  47. }
  48. type PeriodtimeJSON struct {
  49. Setperiodtime0 SetPeropdtime `json:"setperiodtime0"`
  50. }
  51. type VoiceReq struct {
  52. DeviceSn string `json:"deviceSn"`
  53. Voice dao.Voice `json:"voice"`
  54. }
  55. type VoiceJSON struct {
  56. Audionumset0 SetVoice `json:"audionumset0"`
  57. }
  58. type SetVoice struct {
  59. Num0 string `json:"num0"`
  60. Num1 string `json:"num1"`
  61. Num2 string `json:"num2"`
  62. Num3 string `json:"num3"`
  63. Num4 string `json:"num4"`
  64. }
  65. type JSONForm struct {
  66. Sn string `json:"sn"`
  67. Json string `json:"json"`
  68. }