api.go 571 B

12345678910111213141516171819202122232425262728293031323334
  1. package im
  2. import (
  3. "context"
  4. "git.beswell.com/gframe/application"
  5. pb "sportfitness/base/repository/grpc/bsw/im/im"
  6. )
  7. func getClient() pb.ApiClient {
  8. conn, err := application.GetServiceGrpcConn("bsw/im")
  9. if err != nil {
  10. panic(err)
  11. }
  12. return pb.NewApiClient(conn)
  13. }
  14. func SignUp() {
  15. _, err := getClient().SignUpUserCode(context.Background(), &pb.SignUpRequest{
  16. UserCode: "",
  17. Name: "",
  18. Email: "",
  19. Phone: "",
  20. WxOpenId: "",
  21. Qq: "",
  22. Password: "",
  23. Question: "",
  24. Answer: "",
  25. Memo: "",
  26. })
  27. if err != nil {
  28. panic(err)
  29. }
  30. }