panel.go 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. package server
  2. import (
  3. "go-common/app/service/main/vip/model"
  4. "go-common/library/log"
  5. "go-common/library/net/rpc/context"
  6. )
  7. // VipPanelInfo rpc user vip panel info.
  8. func (r *RPC) VipPanelInfo(c context.Context, arg *model.ArgPanel, res *[]*model.VipPanelInfo) (err error) {
  9. var v []*model.VipPanelInfo
  10. if v, err = r.svc.VipUserPanel(c, arg.Mid, arg.Plat, arg.SortTp, arg.Build); err == nil && res != nil {
  11. *res = v
  12. }
  13. return
  14. }
  15. // VipPanelInfo2 rpc user vip panel info v2.
  16. func (r *RPC) VipPanelInfo2(c context.Context, arg *model.ArgPanel, res *model.VipPirceResp) (err error) {
  17. var v *model.VipPirceResp
  18. if v, err = r.svc.VipUserPanelV4(c, arg); err == nil && v != nil {
  19. *res = *v
  20. }
  21. if err != nil {
  22. log.Error("rpc.VipPanelInfo2(%+v) err(%+v)", arg, err)
  23. }
  24. return
  25. }
  26. // VipPanelInfo5 rpc user vip panel info v5.
  27. func (r *RPC) VipPanelInfo5(c context.Context, arg *model.ArgPanel, res *model.VipPirceResp5) (err error) {
  28. var v *model.VipPirceResp5
  29. if v, err = r.svc.VipUserPanelV5(c, arg); err == nil && v != nil {
  30. *res = *v
  31. }
  32. return
  33. }