enterprise_user.go 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. package http_model
  2. import "youngee_m_api/model/gorm_model"
  3. type EnterpriseUserRequest struct {
  4. PageSize int32 `json:"page_size"`
  5. PageNum int32 `json:"page_num"`
  6. User string `json:"user"` // 企业用户ID
  7. Username string `json:"username"` // 企业名称
  8. CreatedAt string `json:"created_at"` // 创建时间
  9. }
  10. type EnterpriseUserPreview struct {
  11. User string `json:"user"` // 企业用户ID
  12. UserID string `json:"userID"` // 用户ID
  13. Username string `json:"username"` // 企业名称
  14. Balance int64 `json:"balance"` // 账户余额
  15. FrozenBalance int64 `json:"frozen_balance"` // 冻结余额
  16. AvailableBalance int64 `json:"available_balance"` // 可用余额
  17. Phone string `json:"phone"` // 联系方式
  18. CreatedAt string `json:"created_at"` // 创建时间
  19. }
  20. type EnterpriseUserData struct {
  21. EnterpriseUserPreview []*EnterpriseUserPreview `json:"enterprise_user_preview"`
  22. Total string `json:"total"`
  23. }
  24. type EnterpriseUser struct {
  25. Enterprise gorm_model.Enterprise
  26. YoungeeUser gorm_model.YounggeeUser
  27. }
  28. func NewEnterpriseUserRequest() *EnterpriseUserRequest {
  29. return new(EnterpriseUserRequest)
  30. }
  31. func NewEnterpriseUserResponse() *CommonResponse {
  32. resp := new(CommonResponse)
  33. resp.Data = new(EnterpriseUserData)
  34. return resp
  35. }