service.go 901 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. package appeal
  2. import (
  3. "context"
  4. "go-common/app/interface/main/creative/conf"
  5. "go-common/app/interface/main/creative/dao/account"
  6. "go-common/app/interface/main/creative/dao/appeal"
  7. "go-common/app/interface/main/creative/dao/archive"
  8. "go-common/app/interface/main/creative/dao/tag"
  9. "go-common/app/interface/main/creative/service"
  10. )
  11. //Service struct
  12. type Service struct {
  13. c *conf.Config
  14. ap *appeal.Dao
  15. arc *archive.Dao
  16. acc *account.Dao
  17. tag *tag.Dao
  18. appealTag int64
  19. }
  20. //New get service
  21. func New(c *conf.Config, rpcdaos *service.RPCDaos) *Service {
  22. s := &Service{
  23. c: c,
  24. ap: appeal.New(c),
  25. arc: rpcdaos.Arc,
  26. acc: rpcdaos.Acc,
  27. tag: tag.New(c),
  28. appealTag: c.AppealTag,
  29. }
  30. return s
  31. }
  32. // Ping service
  33. func (s *Service) Ping(c context.Context) (err error) {
  34. return
  35. }
  36. // Close dao
  37. func (s *Service) Close() {
  38. }