You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

88 lines
2.9 KiB

  1. package api
  2. import (
  3. model "LAPP_LF_MOM_BACKEND/models/api"
  4. "LAPP_LF_MOM_BACKEND/services/api/implments"
  5. "LAPP_LF_MOM_BACKEND/web/models"
  6. )
  7. /******************************************************************************
  8. *
  9. * @Interface Name : ScrewService
  10. *-----------------------------------------------------------------------------
  11. *
  12. * @Description : Screw的服务接口
  13. *
  14. * @Author : zhangxin
  15. *
  16. * @Date : 2021-05-14
  17. *
  18. ******************************************************************************/
  19. type ScrewService interface {
  20. /******************************************************************************
  21. *
  22. * @Function Name : Receive
  23. *-----------------------------------------------------------------------------
  24. *
  25. * @Description : 接收一条screw数据
  26. *
  27. * @Function Parameters : screw指针
  28. *
  29. * @Return Value : 执行时发生的错误
  30. *
  31. * @Author : zhangxin
  32. *
  33. * @Date : 2021-05-14
  34. *
  35. ******************************************************************************/
  36. Receive(defect *model.Screw) error
  37. /******************************************************************************
  38. *
  39. * @Function Name : NewestScrew
  40. *-----------------------------------------------------------------------------
  41. *
  42. * @Description : 获取最新的screw
  43. *
  44. * @Return Value : 最新的screw
  45. *
  46. * @Author : zhangxin
  47. *
  48. * @Date : 2021-05-14
  49. *
  50. ******************************************************************************/
  51. GetNewestScrew(usertab *models.Usertab, stn string) (model.ScrewWithData, error)
  52. /******************************************************************************
  53. *
  54. * @Function Name : GetScrewLi
  55. *-----------------------------------------------------------------------------
  56. *
  57. * @Description : 获取screw list
  58. *
  59. * @Return Value : screw list
  60. *
  61. * @Author : zhangxin
  62. *
  63. * @Date : 2021-05-14
  64. *
  65. ******************************************************************************/
  66. GetScrewLi(usertab *models.Usertab, stn string) ([]model.ScrewWithData, error)
  67. }
  68. /******************************************************************************
  69. *
  70. * @Function Name : NewScrewService
  71. *-----------------------------------------------------------------------------
  72. *
  73. * @Description : 创建一个NewScrewService
  74. *
  75. * @Return Value : NewScrewService实例
  76. *
  77. * @Author : zhangxin
  78. *
  79. * @Date : 2021-05-14
  80. *
  81. ******************************************************************************/
  82. func NewScrewService() ScrewService {
  83. return implments.NewScrewServiceImplement()
  84. }