From 679d068a8287355ad46fcfaa16d352612abccae4 Mon Sep 17 00:00:00 2001 From: zhx Date: Wed, 3 Jun 2026 00:02:19 +0800 Subject: [PATCH] feat: remove generic USD wallet balance --- api/proto/wallet/v1/wallet.pb.go | 943 ++++++------------ api/proto/wallet/v1/wallet.proto | 28 - api/proto/wallet/v1/wallet_grpc.pb.go | 38 - .../Flutter App 通知与钱包余额对接.md | 10 +- docs/主播公会BD后台架构.md | 16 +- docs/主播公会BD实施顺序.md | 6 +- docs/主播公会BD架构.md | 4 +- docs/币商库存授信架构.md | 2 +- docs/我的页概览接口.md | 5 +- docs/接口清单.md | 1 - docs/钱包服务架构.md | 22 +- ...remove_usd_balance_withdrawal_requests.sql | 55 + .../modules/teamsalarysettlement/service.go | 45 +- .../service_integration_test.go | 10 +- .../internal/client/wallet_client.go | 5 - .../transport/http/httproutes/router.go | 2 - .../internal/transport/http/response_test.go | 14 - .../http/walletapi/app_wallet_handler.go | 80 -- .../transport/http/walletapi/handler.go | 1 - .../mysql/initdb/001_wallet_service.sql | 22 - .../internal/domain/ledger/ledger.go | 39 +- .../internal/service/wallet/service.go | 19 - .../internal/service/wallet/service_test.go | 64 +- .../storage/mysql/app_wallet_repository.go | 135 +-- .../storage/mysql/host_salary_settlement.go | 14 +- .../internal/testutil/mysqltest/mysqltest.go | 2 +- .../internal/transport/grpc/server.go | 35 - 27 files changed, 500 insertions(+), 1117 deletions(-) create mode 100644 scripts/mysql/034_remove_usd_balance_withdrawal_requests.sql diff --git a/api/proto/wallet/v1/wallet.pb.go b/api/proto/wallet/v1/wallet.pb.go index b60fd2a2..f518ea72 100644 --- a/api/proto/wallet/v1/wallet.pb.go +++ b/api/proto/wallet/v1/wallet.pb.go @@ -6517,7 +6517,6 @@ type WalletFeatureFlags struct { state protoimpl.MessageState `protogen:"open.v1"` RechargeEnabled bool `protobuf:"varint,1,opt,name=recharge_enabled,json=rechargeEnabled,proto3" json:"recharge_enabled,omitempty"` DiamondExchangeEnabled bool `protobuf:"varint,2,opt,name=diamond_exchange_enabled,json=diamondExchangeEnabled,proto3" json:"diamond_exchange_enabled,omitempty"` - WithdrawEnabled bool `protobuf:"varint,3,opt,name=withdraw_enabled,json=withdrawEnabled,proto3" json:"withdraw_enabled,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } @@ -6566,13 +6565,6 @@ func (x *WalletFeatureFlags) GetDiamondExchangeEnabled() bool { return false } -func (x *WalletFeatureFlags) GetWithdrawEnabled() bool { - if x != nil { - return x.WithdrawEnabled - } - return false -} - type GetWalletOverviewRequest struct { state protoimpl.MessageState `protogen:"open.v1"` RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` @@ -8748,250 +8740,6 @@ func (x *ListWalletTransactionsResponse) GetTotal() int64 { return 0 } -type WithdrawalRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - WithdrawalId string `protobuf:"bytes,1,opt,name=withdrawal_id,json=withdrawalId,proto3" json:"withdrawal_id,omitempty"` - UserId int64 `protobuf:"varint,2,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` - AssetType string `protobuf:"bytes,3,opt,name=asset_type,json=assetType,proto3" json:"asset_type,omitempty"` - Amount int64 `protobuf:"varint,4,opt,name=amount,proto3" json:"amount,omitempty"` - Status string `protobuf:"bytes,5,opt,name=status,proto3" json:"status,omitempty"` - PayoutAccount string `protobuf:"bytes,6,opt,name=payout_account,json=payoutAccount,proto3" json:"payout_account,omitempty"` - Reason string `protobuf:"bytes,7,opt,name=reason,proto3" json:"reason,omitempty"` - CreatedAtMs int64 `protobuf:"varint,8,opt,name=created_at_ms,json=createdAtMs,proto3" json:"created_at_ms,omitempty"` - UpdatedAtMs int64 `protobuf:"varint,9,opt,name=updated_at_ms,json=updatedAtMs,proto3" json:"updated_at_ms,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *WithdrawalRequest) Reset() { - *x = WithdrawalRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[95] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *WithdrawalRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*WithdrawalRequest) ProtoMessage() {} - -func (x *WithdrawalRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[95] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use WithdrawalRequest.ProtoReflect.Descriptor instead. -func (*WithdrawalRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{95} -} - -func (x *WithdrawalRequest) GetWithdrawalId() string { - if x != nil { - return x.WithdrawalId - } - return "" -} - -func (x *WithdrawalRequest) GetUserId() int64 { - if x != nil { - return x.UserId - } - return 0 -} - -func (x *WithdrawalRequest) GetAssetType() string { - if x != nil { - return x.AssetType - } - return "" -} - -func (x *WithdrawalRequest) GetAmount() int64 { - if x != nil { - return x.Amount - } - return 0 -} - -func (x *WithdrawalRequest) GetStatus() string { - if x != nil { - return x.Status - } - return "" -} - -func (x *WithdrawalRequest) GetPayoutAccount() string { - if x != nil { - return x.PayoutAccount - } - return "" -} - -func (x *WithdrawalRequest) GetReason() string { - if x != nil { - return x.Reason - } - return "" -} - -func (x *WithdrawalRequest) GetCreatedAtMs() int64 { - if x != nil { - return x.CreatedAtMs - } - return 0 -} - -func (x *WithdrawalRequest) GetUpdatedAtMs() int64 { - if x != nil { - return x.UpdatedAtMs - } - return 0 -} - -type ApplyWithdrawalRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - CommandId string `protobuf:"bytes,1,opt,name=command_id,json=commandId,proto3" json:"command_id,omitempty"` - AppCode string `protobuf:"bytes,2,opt,name=app_code,json=appCode,proto3" json:"app_code,omitempty"` - UserId int64 `protobuf:"varint,3,opt,name=user_id,json=userId,proto3" json:"user_id,omitempty"` - Amount int64 `protobuf:"varint,4,opt,name=amount,proto3" json:"amount,omitempty"` - PayoutAccount string `protobuf:"bytes,5,opt,name=payout_account,json=payoutAccount,proto3" json:"payout_account,omitempty"` - Reason string `protobuf:"bytes,6,opt,name=reason,proto3" json:"reason,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ApplyWithdrawalRequest) Reset() { - *x = ApplyWithdrawalRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[96] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ApplyWithdrawalRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ApplyWithdrawalRequest) ProtoMessage() {} - -func (x *ApplyWithdrawalRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[96] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ApplyWithdrawalRequest.ProtoReflect.Descriptor instead. -func (*ApplyWithdrawalRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{96} -} - -func (x *ApplyWithdrawalRequest) GetCommandId() string { - if x != nil { - return x.CommandId - } - return "" -} - -func (x *ApplyWithdrawalRequest) GetAppCode() string { - if x != nil { - return x.AppCode - } - return "" -} - -func (x *ApplyWithdrawalRequest) GetUserId() int64 { - if x != nil { - return x.UserId - } - return 0 -} - -func (x *ApplyWithdrawalRequest) GetAmount() int64 { - if x != nil { - return x.Amount - } - return 0 -} - -func (x *ApplyWithdrawalRequest) GetPayoutAccount() string { - if x != nil { - return x.PayoutAccount - } - return "" -} - -func (x *ApplyWithdrawalRequest) GetReason() string { - if x != nil { - return x.Reason - } - return "" -} - -type ApplyWithdrawalResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Withdrawal *WithdrawalRequest `protobuf:"bytes,1,opt,name=withdrawal,proto3" json:"withdrawal,omitempty"` - Balance *AssetBalance `protobuf:"bytes,2,opt,name=balance,proto3" json:"balance,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *ApplyWithdrawalResponse) Reset() { - *x = ApplyWithdrawalResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[97] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *ApplyWithdrawalResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*ApplyWithdrawalResponse) ProtoMessage() {} - -func (x *ApplyWithdrawalResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[97] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use ApplyWithdrawalResponse.ProtoReflect.Descriptor instead. -func (*ApplyWithdrawalResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{97} -} - -func (x *ApplyWithdrawalResponse) GetWithdrawal() *WithdrawalRequest { - if x != nil { - return x.Withdrawal - } - return nil -} - -func (x *ApplyWithdrawalResponse) GetBalance() *AssetBalance { - if x != nil { - return x.Balance - } - return nil -} - type VipRewardItem struct { state protoimpl.MessageState `protogen:"open.v1"` ResourceId int64 `protobuf:"varint,1,opt,name=resource_id,json=resourceId,proto3" json:"resource_id,omitempty"` @@ -9009,7 +8757,7 @@ type VipRewardItem struct { func (x *VipRewardItem) Reset() { *x = VipRewardItem{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[98] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[95] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9021,7 +8769,7 @@ func (x *VipRewardItem) String() string { func (*VipRewardItem) ProtoMessage() {} func (x *VipRewardItem) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[98] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[95] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9034,7 +8782,7 @@ func (x *VipRewardItem) ProtoReflect() protoreflect.Message { // Deprecated: Use VipRewardItem.ProtoReflect.Descriptor instead. func (*VipRewardItem) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{98} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{95} } func (x *VipRewardItem) GetResourceId() int64 { @@ -9123,7 +8871,7 @@ type VipLevel struct { func (x *VipLevel) Reset() { *x = VipLevel{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[99] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[96] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9135,7 +8883,7 @@ func (x *VipLevel) String() string { func (*VipLevel) ProtoMessage() {} func (x *VipLevel) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[99] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[96] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9148,7 +8896,7 @@ func (x *VipLevel) ProtoReflect() protoreflect.Message { // Deprecated: Use VipLevel.ProtoReflect.Descriptor instead. func (*VipLevel) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{99} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{96} } func (x *VipLevel) GetLevel() int32 { @@ -9271,7 +9019,7 @@ type UserVip struct { func (x *UserVip) Reset() { *x = UserVip{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[100] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[97] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9283,7 +9031,7 @@ func (x *UserVip) String() string { func (*UserVip) ProtoMessage() {} func (x *UserVip) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[100] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[97] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9296,7 +9044,7 @@ func (x *UserVip) ProtoReflect() protoreflect.Message { // Deprecated: Use UserVip.ProtoReflect.Descriptor instead. func (*UserVip) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{100} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{97} } func (x *UserVip) GetUserId() int64 { @@ -9359,7 +9107,7 @@ type ListVipPackagesRequest struct { func (x *ListVipPackagesRequest) Reset() { *x = ListVipPackagesRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[101] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[98] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9371,7 +9119,7 @@ func (x *ListVipPackagesRequest) String() string { func (*ListVipPackagesRequest) ProtoMessage() {} func (x *ListVipPackagesRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[101] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[98] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9384,7 +9132,7 @@ func (x *ListVipPackagesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListVipPackagesRequest.ProtoReflect.Descriptor instead. func (*ListVipPackagesRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{101} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{98} } func (x *ListVipPackagesRequest) GetRequestId() string { @@ -9418,7 +9166,7 @@ type ListVipPackagesResponse struct { func (x *ListVipPackagesResponse) Reset() { *x = ListVipPackagesResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[102] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[99] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9430,7 +9178,7 @@ func (x *ListVipPackagesResponse) String() string { func (*ListVipPackagesResponse) ProtoMessage() {} func (x *ListVipPackagesResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[102] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[99] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9443,7 +9191,7 @@ func (x *ListVipPackagesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListVipPackagesResponse.ProtoReflect.Descriptor instead. func (*ListVipPackagesResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{102} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{99} } func (x *ListVipPackagesResponse) GetCurrentVip() *UserVip { @@ -9471,7 +9219,7 @@ type GetMyVipRequest struct { func (x *GetMyVipRequest) Reset() { *x = GetMyVipRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[103] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[100] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9483,7 +9231,7 @@ func (x *GetMyVipRequest) String() string { func (*GetMyVipRequest) ProtoMessage() {} func (x *GetMyVipRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[103] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[100] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9496,7 +9244,7 @@ func (x *GetMyVipRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetMyVipRequest.ProtoReflect.Descriptor instead. func (*GetMyVipRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{103} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{100} } func (x *GetMyVipRequest) GetRequestId() string { @@ -9529,7 +9277,7 @@ type GetMyVipResponse struct { func (x *GetMyVipResponse) Reset() { *x = GetMyVipResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[104] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[101] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9541,7 +9289,7 @@ func (x *GetMyVipResponse) String() string { func (*GetMyVipResponse) ProtoMessage() {} func (x *GetMyVipResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[104] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[101] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9554,7 +9302,7 @@ func (x *GetMyVipResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetMyVipResponse.ProtoReflect.Descriptor instead. func (*GetMyVipResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{104} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{101} } func (x *GetMyVipResponse) GetVip() *UserVip { @@ -9576,7 +9324,7 @@ type PurchaseVipRequest struct { func (x *PurchaseVipRequest) Reset() { *x = PurchaseVipRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[105] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[102] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9588,7 +9336,7 @@ func (x *PurchaseVipRequest) String() string { func (*PurchaseVipRequest) ProtoMessage() {} func (x *PurchaseVipRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[105] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[102] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9601,7 +9349,7 @@ func (x *PurchaseVipRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use PurchaseVipRequest.ProtoReflect.Descriptor instead. func (*PurchaseVipRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{105} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{102} } func (x *PurchaseVipRequest) GetCommandId() string { @@ -9646,7 +9394,7 @@ type PurchaseVipResponse struct { func (x *PurchaseVipResponse) Reset() { *x = PurchaseVipResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[106] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[103] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9658,7 +9406,7 @@ func (x *PurchaseVipResponse) String() string { func (*PurchaseVipResponse) ProtoMessage() {} func (x *PurchaseVipResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[106] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[103] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9671,7 +9419,7 @@ func (x *PurchaseVipResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use PurchaseVipResponse.ProtoReflect.Descriptor instead. func (*PurchaseVipResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{106} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{103} } func (x *PurchaseVipResponse) GetOrderId() string { @@ -9731,7 +9479,7 @@ type GrantVipRequest struct { func (x *GrantVipRequest) Reset() { *x = GrantVipRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[107] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[104] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9743,7 +9491,7 @@ func (x *GrantVipRequest) String() string { func (*GrantVipRequest) ProtoMessage() {} func (x *GrantVipRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[107] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[104] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9756,7 +9504,7 @@ func (x *GrantVipRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GrantVipRequest.ProtoReflect.Descriptor instead. func (*GrantVipRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{107} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{104} } func (x *GrantVipRequest) GetCommandId() string { @@ -9820,7 +9568,7 @@ type GrantVipResponse struct { func (x *GrantVipResponse) Reset() { *x = GrantVipResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[108] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[105] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9832,7 +9580,7 @@ func (x *GrantVipResponse) String() string { func (*GrantVipResponse) ProtoMessage() {} func (x *GrantVipResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[108] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[105] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9845,7 +9593,7 @@ func (x *GrantVipResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GrantVipResponse.ProtoReflect.Descriptor instead. func (*GrantVipResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{108} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{105} } func (x *GrantVipResponse) GetTransactionId() string { @@ -9892,7 +9640,7 @@ type AdminVipLevelInput struct { func (x *AdminVipLevelInput) Reset() { *x = AdminVipLevelInput{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[109] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[106] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9904,7 +9652,7 @@ func (x *AdminVipLevelInput) String() string { func (*AdminVipLevelInput) ProtoMessage() {} func (x *AdminVipLevelInput) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[109] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[106] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -9917,7 +9665,7 @@ func (x *AdminVipLevelInput) ProtoReflect() protoreflect.Message { // Deprecated: Use AdminVipLevelInput.ProtoReflect.Descriptor instead. func (*AdminVipLevelInput) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{109} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{106} } func (x *AdminVipLevelInput) GetLevel() int32 { @@ -9986,7 +9734,7 @@ type ListAdminVipLevelsRequest struct { func (x *ListAdminVipLevelsRequest) Reset() { *x = ListAdminVipLevelsRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[110] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[107] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -9998,7 +9746,7 @@ func (x *ListAdminVipLevelsRequest) String() string { func (*ListAdminVipLevelsRequest) ProtoMessage() {} func (x *ListAdminVipLevelsRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[110] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[107] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10011,7 +9759,7 @@ func (x *ListAdminVipLevelsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListAdminVipLevelsRequest.ProtoReflect.Descriptor instead. func (*ListAdminVipLevelsRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{110} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{107} } func (x *ListAdminVipLevelsRequest) GetRequestId() string { @@ -10038,7 +9786,7 @@ type ListAdminVipLevelsResponse struct { func (x *ListAdminVipLevelsResponse) Reset() { *x = ListAdminVipLevelsResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[111] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[108] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10050,7 +9798,7 @@ func (x *ListAdminVipLevelsResponse) String() string { func (*ListAdminVipLevelsResponse) ProtoMessage() {} func (x *ListAdminVipLevelsResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[111] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[108] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10063,7 +9811,7 @@ func (x *ListAdminVipLevelsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListAdminVipLevelsResponse.ProtoReflect.Descriptor instead. func (*ListAdminVipLevelsResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{111} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{108} } func (x *ListAdminVipLevelsResponse) GetLevels() []*VipLevel { @@ -10092,7 +9840,7 @@ type UpdateAdminVipLevelsRequest struct { func (x *UpdateAdminVipLevelsRequest) Reset() { *x = UpdateAdminVipLevelsRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[112] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[109] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10104,7 +9852,7 @@ func (x *UpdateAdminVipLevelsRequest) String() string { func (*UpdateAdminVipLevelsRequest) ProtoMessage() {} func (x *UpdateAdminVipLevelsRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[112] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[109] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10117,7 +9865,7 @@ func (x *UpdateAdminVipLevelsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateAdminVipLevelsRequest.ProtoReflect.Descriptor instead. func (*UpdateAdminVipLevelsRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{112} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{109} } func (x *UpdateAdminVipLevelsRequest) GetRequestId() string { @@ -10158,7 +9906,7 @@ type UpdateAdminVipLevelsResponse struct { func (x *UpdateAdminVipLevelsResponse) Reset() { *x = UpdateAdminVipLevelsResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[113] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[110] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10170,7 +9918,7 @@ func (x *UpdateAdminVipLevelsResponse) String() string { func (*UpdateAdminVipLevelsResponse) ProtoMessage() {} func (x *UpdateAdminVipLevelsResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[113] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[110] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10183,7 +9931,7 @@ func (x *UpdateAdminVipLevelsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateAdminVipLevelsResponse.ProtoReflect.Descriptor instead. func (*UpdateAdminVipLevelsResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{113} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{110} } func (x *UpdateAdminVipLevelsResponse) GetLevels() []*VipLevel { @@ -10217,7 +9965,7 @@ type CreditTaskRewardRequest struct { func (x *CreditTaskRewardRequest) Reset() { *x = CreditTaskRewardRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[114] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[111] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10229,7 +9977,7 @@ func (x *CreditTaskRewardRequest) String() string { func (*CreditTaskRewardRequest) ProtoMessage() {} func (x *CreditTaskRewardRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[114] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[111] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10242,7 +9990,7 @@ func (x *CreditTaskRewardRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CreditTaskRewardRequest.ProtoReflect.Descriptor instead. func (*CreditTaskRewardRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{114} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{111} } func (x *CreditTaskRewardRequest) GetCommandId() string { @@ -10314,7 +10062,7 @@ type CreditTaskRewardResponse struct { func (x *CreditTaskRewardResponse) Reset() { *x = CreditTaskRewardResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[115] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[112] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10326,7 +10074,7 @@ func (x *CreditTaskRewardResponse) String() string { func (*CreditTaskRewardResponse) ProtoMessage() {} func (x *CreditTaskRewardResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[115] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[112] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10339,7 +10087,7 @@ func (x *CreditTaskRewardResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CreditTaskRewardResponse.ProtoReflect.Descriptor instead. func (*CreditTaskRewardResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{115} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{112} } func (x *CreditTaskRewardResponse) GetTransactionId() string { @@ -10389,7 +10137,7 @@ type CreditLuckyGiftRewardRequest struct { func (x *CreditLuckyGiftRewardRequest) Reset() { *x = CreditLuckyGiftRewardRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[116] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[113] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10401,7 +10149,7 @@ func (x *CreditLuckyGiftRewardRequest) String() string { func (*CreditLuckyGiftRewardRequest) ProtoMessage() {} func (x *CreditLuckyGiftRewardRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[116] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[113] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10414,7 +10162,7 @@ func (x *CreditLuckyGiftRewardRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CreditLuckyGiftRewardRequest.ProtoReflect.Descriptor instead. func (*CreditLuckyGiftRewardRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{116} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{113} } func (x *CreditLuckyGiftRewardRequest) GetCommandId() string { @@ -10500,7 +10248,7 @@ type CreditLuckyGiftRewardResponse struct { func (x *CreditLuckyGiftRewardResponse) Reset() { *x = CreditLuckyGiftRewardResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[117] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[114] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10512,7 +10260,7 @@ func (x *CreditLuckyGiftRewardResponse) String() string { func (*CreditLuckyGiftRewardResponse) ProtoMessage() {} func (x *CreditLuckyGiftRewardResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[117] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[114] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10525,7 +10273,7 @@ func (x *CreditLuckyGiftRewardResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CreditLuckyGiftRewardResponse.ProtoReflect.Descriptor instead. func (*CreditLuckyGiftRewardResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{117} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{114} } func (x *CreditLuckyGiftRewardResponse) GetTransactionId() string { @@ -10577,7 +10325,7 @@ type ApplyGameCoinChangeRequest struct { func (x *ApplyGameCoinChangeRequest) Reset() { *x = ApplyGameCoinChangeRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[118] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[115] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10589,7 +10337,7 @@ func (x *ApplyGameCoinChangeRequest) String() string { func (*ApplyGameCoinChangeRequest) ProtoMessage() {} func (x *ApplyGameCoinChangeRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[118] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[115] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10602,7 +10350,7 @@ func (x *ApplyGameCoinChangeRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ApplyGameCoinChangeRequest.ProtoReflect.Descriptor instead. func (*ApplyGameCoinChangeRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{118} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{115} } func (x *ApplyGameCoinChangeRequest) GetRequestId() string { @@ -10701,7 +10449,7 @@ type ApplyGameCoinChangeResponse struct { func (x *ApplyGameCoinChangeResponse) Reset() { *x = ApplyGameCoinChangeResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[119] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[116] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10713,7 +10461,7 @@ func (x *ApplyGameCoinChangeResponse) String() string { func (*ApplyGameCoinChangeResponse) ProtoMessage() {} func (x *ApplyGameCoinChangeResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[119] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[116] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10726,7 +10474,7 @@ func (x *ApplyGameCoinChangeResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ApplyGameCoinChangeResponse.ProtoReflect.Descriptor instead. func (*ApplyGameCoinChangeResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{119} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{116} } func (x *ApplyGameCoinChangeResponse) GetWalletTransactionId() string { @@ -10769,7 +10517,7 @@ type RedPacketConfig struct { func (x *RedPacketConfig) Reset() { *x = RedPacketConfig{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[120] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[117] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10781,7 +10529,7 @@ func (x *RedPacketConfig) String() string { func (*RedPacketConfig) ProtoMessage() {} func (x *RedPacketConfig) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[120] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[117] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10794,7 +10542,7 @@ func (x *RedPacketConfig) ProtoReflect() protoreflect.Message { // Deprecated: Use RedPacketConfig.ProtoReflect.Descriptor instead. func (*RedPacketConfig) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{120} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{117} } func (x *RedPacketConfig) GetAppCode() string { @@ -10893,7 +10641,7 @@ type RedPacketClaim struct { func (x *RedPacketClaim) Reset() { *x = RedPacketClaim{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[121] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[118] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -10905,7 +10653,7 @@ func (x *RedPacketClaim) String() string { func (*RedPacketClaim) ProtoMessage() {} func (x *RedPacketClaim) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[121] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[118] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -10918,7 +10666,7 @@ func (x *RedPacketClaim) ProtoReflect() protoreflect.Message { // Deprecated: Use RedPacketClaim.ProtoReflect.Descriptor instead. func (*RedPacketClaim) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{121} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{118} } func (x *RedPacketClaim) GetAppCode() string { @@ -11028,7 +10776,7 @@ type RedPacket struct { func (x *RedPacket) Reset() { *x = RedPacket{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[122] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[119] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11040,7 +10788,7 @@ func (x *RedPacket) String() string { func (*RedPacket) ProtoMessage() {} func (x *RedPacket) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[122] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[119] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11053,7 +10801,7 @@ func (x *RedPacket) ProtoReflect() protoreflect.Message { // Deprecated: Use RedPacket.ProtoReflect.Descriptor instead. func (*RedPacket) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{122} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{119} } func (x *RedPacket) GetAppCode() string { @@ -11220,7 +10968,7 @@ type GetRedPacketConfigRequest struct { func (x *GetRedPacketConfigRequest) Reset() { *x = GetRedPacketConfigRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[123] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[120] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11232,7 +10980,7 @@ func (x *GetRedPacketConfigRequest) String() string { func (*GetRedPacketConfigRequest) ProtoMessage() {} func (x *GetRedPacketConfigRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[123] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[120] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11245,7 +10993,7 @@ func (x *GetRedPacketConfigRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetRedPacketConfigRequest.ProtoReflect.Descriptor instead. func (*GetRedPacketConfigRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{123} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{120} } func (x *GetRedPacketConfigRequest) GetRequestId() string { @@ -11272,7 +11020,7 @@ type GetRedPacketConfigResponse struct { func (x *GetRedPacketConfigResponse) Reset() { *x = GetRedPacketConfigResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[124] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[121] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11284,7 +11032,7 @@ func (x *GetRedPacketConfigResponse) String() string { func (*GetRedPacketConfigResponse) ProtoMessage() {} func (x *GetRedPacketConfigResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[124] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[121] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11297,7 +11045,7 @@ func (x *GetRedPacketConfigResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetRedPacketConfigResponse.ProtoReflect.Descriptor instead. func (*GetRedPacketConfigResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{124} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{121} } func (x *GetRedPacketConfigResponse) GetConfig() *RedPacketConfig { @@ -11332,7 +11080,7 @@ type UpdateRedPacketConfigRequest struct { func (x *UpdateRedPacketConfigRequest) Reset() { *x = UpdateRedPacketConfigRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[125] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[122] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11344,7 +11092,7 @@ func (x *UpdateRedPacketConfigRequest) String() string { func (*UpdateRedPacketConfigRequest) ProtoMessage() {} func (x *UpdateRedPacketConfigRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[125] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[122] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11357,7 +11105,7 @@ func (x *UpdateRedPacketConfigRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateRedPacketConfigRequest.ProtoReflect.Descriptor instead. func (*UpdateRedPacketConfigRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{125} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{122} } func (x *UpdateRedPacketConfigRequest) GetRequestId() string { @@ -11440,7 +11188,7 @@ type UpdateRedPacketConfigResponse struct { func (x *UpdateRedPacketConfigResponse) Reset() { *x = UpdateRedPacketConfigResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[126] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[123] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11452,7 +11200,7 @@ func (x *UpdateRedPacketConfigResponse) String() string { func (*UpdateRedPacketConfigResponse) ProtoMessage() {} func (x *UpdateRedPacketConfigResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[126] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[123] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11465,7 +11213,7 @@ func (x *UpdateRedPacketConfigResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateRedPacketConfigResponse.ProtoReflect.Descriptor instead. func (*UpdateRedPacketConfigResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{126} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{123} } func (x *UpdateRedPacketConfigResponse) GetConfig() *RedPacketConfig { @@ -11499,7 +11247,7 @@ type CreateRedPacketRequest struct { func (x *CreateRedPacketRequest) Reset() { *x = CreateRedPacketRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[127] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[124] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11511,7 +11259,7 @@ func (x *CreateRedPacketRequest) String() string { func (*CreateRedPacketRequest) ProtoMessage() {} func (x *CreateRedPacketRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[127] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[124] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11524,7 +11272,7 @@ func (x *CreateRedPacketRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateRedPacketRequest.ProtoReflect.Descriptor instead. func (*CreateRedPacketRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{127} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{124} } func (x *CreateRedPacketRequest) GetRequestId() string { @@ -11601,7 +11349,7 @@ type CreateRedPacketResponse struct { func (x *CreateRedPacketResponse) Reset() { *x = CreateRedPacketResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[128] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[125] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11613,7 +11361,7 @@ func (x *CreateRedPacketResponse) String() string { func (*CreateRedPacketResponse) ProtoMessage() {} func (x *CreateRedPacketResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[128] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[125] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11626,7 +11374,7 @@ func (x *CreateRedPacketResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateRedPacketResponse.ProtoReflect.Descriptor instead. func (*CreateRedPacketResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{128} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{125} } func (x *CreateRedPacketResponse) GetPacket() *RedPacket { @@ -11663,7 +11411,7 @@ type ClaimRedPacketRequest struct { func (x *ClaimRedPacketRequest) Reset() { *x = ClaimRedPacketRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[129] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[126] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11675,7 +11423,7 @@ func (x *ClaimRedPacketRequest) String() string { func (*ClaimRedPacketRequest) ProtoMessage() {} func (x *ClaimRedPacketRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[129] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[126] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11688,7 +11436,7 @@ func (x *ClaimRedPacketRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ClaimRedPacketRequest.ProtoReflect.Descriptor instead. func (*ClaimRedPacketRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{129} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{126} } func (x *ClaimRedPacketRequest) GetRequestId() string { @@ -11738,7 +11486,7 @@ type ClaimRedPacketResponse struct { func (x *ClaimRedPacketResponse) Reset() { *x = ClaimRedPacketResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[130] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[127] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11750,7 +11498,7 @@ func (x *ClaimRedPacketResponse) String() string { func (*ClaimRedPacketResponse) ProtoMessage() {} func (x *ClaimRedPacketResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[130] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[127] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11763,7 +11511,7 @@ func (x *ClaimRedPacketResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ClaimRedPacketResponse.ProtoReflect.Descriptor instead. func (*ClaimRedPacketResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{130} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{127} } func (x *ClaimRedPacketResponse) GetClaim() *RedPacketClaim { @@ -11814,7 +11562,7 @@ type ListRedPacketsRequest struct { func (x *ListRedPacketsRequest) Reset() { *x = ListRedPacketsRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[131] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[128] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11826,7 +11574,7 @@ func (x *ListRedPacketsRequest) String() string { func (*ListRedPacketsRequest) ProtoMessage() {} func (x *ListRedPacketsRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[131] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[128] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11839,7 +11587,7 @@ func (x *ListRedPacketsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListRedPacketsRequest.ProtoReflect.Descriptor instead. func (*ListRedPacketsRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{131} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{128} } func (x *ListRedPacketsRequest) GetRequestId() string { @@ -11937,7 +11685,7 @@ type ListRedPacketsResponse struct { func (x *ListRedPacketsResponse) Reset() { *x = ListRedPacketsResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[132] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[129] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -11949,7 +11697,7 @@ func (x *ListRedPacketsResponse) String() string { func (*ListRedPacketsResponse) ProtoMessage() {} func (x *ListRedPacketsResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[132] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[129] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -11962,7 +11710,7 @@ func (x *ListRedPacketsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListRedPacketsResponse.ProtoReflect.Descriptor instead. func (*ListRedPacketsResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{132} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{129} } func (x *ListRedPacketsResponse) GetPackets() []*RedPacket { @@ -11999,7 +11747,7 @@ type GetRedPacketRequest struct { func (x *GetRedPacketRequest) Reset() { *x = GetRedPacketRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[133] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[130] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12011,7 +11759,7 @@ func (x *GetRedPacketRequest) String() string { func (*GetRedPacketRequest) ProtoMessage() {} func (x *GetRedPacketRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[133] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[130] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -12024,7 +11772,7 @@ func (x *GetRedPacketRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetRedPacketRequest.ProtoReflect.Descriptor instead. func (*GetRedPacketRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{133} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{130} } func (x *GetRedPacketRequest) GetRequestId() string { @@ -12072,7 +11820,7 @@ type GetRedPacketResponse struct { func (x *GetRedPacketResponse) Reset() { *x = GetRedPacketResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[134] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[131] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12084,7 +11832,7 @@ func (x *GetRedPacketResponse) String() string { func (*GetRedPacketResponse) ProtoMessage() {} func (x *GetRedPacketResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[134] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[131] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -12097,7 +11845,7 @@ func (x *GetRedPacketResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetRedPacketResponse.ProtoReflect.Descriptor instead. func (*GetRedPacketResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{134} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{131} } func (x *GetRedPacketResponse) GetPacket() *RedPacket { @@ -12125,7 +11873,7 @@ type ExpireRedPacketsRequest struct { func (x *ExpireRedPacketsRequest) Reset() { *x = ExpireRedPacketsRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[135] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[132] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12137,7 +11885,7 @@ func (x *ExpireRedPacketsRequest) String() string { func (*ExpireRedPacketsRequest) ProtoMessage() {} func (x *ExpireRedPacketsRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[135] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[132] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -12150,7 +11898,7 @@ func (x *ExpireRedPacketsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ExpireRedPacketsRequest.ProtoReflect.Descriptor instead. func (*ExpireRedPacketsRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{135} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{132} } func (x *ExpireRedPacketsRequest) GetRequestId() string { @@ -12185,7 +11933,7 @@ type ExpireRedPacketsResponse struct { func (x *ExpireRedPacketsResponse) Reset() { *x = ExpireRedPacketsResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[136] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[133] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12197,7 +11945,7 @@ func (x *ExpireRedPacketsResponse) String() string { func (*ExpireRedPacketsResponse) ProtoMessage() {} func (x *ExpireRedPacketsResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[136] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[133] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -12210,7 +11958,7 @@ func (x *ExpireRedPacketsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ExpireRedPacketsResponse.ProtoReflect.Descriptor instead. func (*ExpireRedPacketsResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{136} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{133} } func (x *ExpireRedPacketsResponse) GetExpiredCount() int32 { @@ -12246,7 +11994,7 @@ type RetryRedPacketRefundRequest struct { func (x *RetryRedPacketRefundRequest) Reset() { *x = RetryRedPacketRefundRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[137] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[134] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12258,7 +12006,7 @@ func (x *RetryRedPacketRefundRequest) String() string { func (*RetryRedPacketRefundRequest) ProtoMessage() {} func (x *RetryRedPacketRefundRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[137] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[134] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -12271,7 +12019,7 @@ func (x *RetryRedPacketRefundRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use RetryRedPacketRefundRequest.ProtoReflect.Descriptor instead. func (*RetryRedPacketRefundRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{137} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{134} } func (x *RetryRedPacketRefundRequest) GetRequestId() string { @@ -12313,7 +12061,7 @@ type RetryRedPacketRefundResponse struct { func (x *RetryRedPacketRefundResponse) Reset() { *x = RetryRedPacketRefundResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[138] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[135] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12325,7 +12073,7 @@ func (x *RetryRedPacketRefundResponse) String() string { func (*RetryRedPacketRefundResponse) ProtoMessage() {} func (x *RetryRedPacketRefundResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[138] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[135] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -12338,7 +12086,7 @@ func (x *RetryRedPacketRefundResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use RetryRedPacketRefundResponse.ProtoReflect.Descriptor instead. func (*RetryRedPacketRefundResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{138} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{135} } func (x *RetryRedPacketRefundResponse) GetPacket() *RedPacket { @@ -12377,7 +12125,7 @@ type CronBatchRequest struct { func (x *CronBatchRequest) Reset() { *x = CronBatchRequest{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[139] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[136] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12389,7 +12137,7 @@ func (x *CronBatchRequest) String() string { func (*CronBatchRequest) ProtoMessage() {} func (x *CronBatchRequest) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[139] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[136] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -12402,7 +12150,7 @@ func (x *CronBatchRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CronBatchRequest.ProtoReflect.Descriptor instead. func (*CronBatchRequest) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{139} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{136} } func (x *CronBatchRequest) GetRequestId() string { @@ -12461,7 +12209,7 @@ type CronBatchResponse struct { func (x *CronBatchResponse) Reset() { *x = CronBatchResponse{} - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[140] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[137] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -12473,7 +12221,7 @@ func (x *CronBatchResponse) String() string { func (*CronBatchResponse) ProtoMessage() {} func (x *CronBatchResponse) ProtoReflect() protoreflect.Message { - mi := &file_proto_wallet_v1_wallet_proto_msgTypes[140] + mi := &file_proto_wallet_v1_wallet_proto_msgTypes[137] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -12486,7 +12234,7 @@ func (x *CronBatchResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CronBatchResponse.ProtoReflect.Descriptor instead. func (*CronBatchResponse) Descriptor() ([]byte, []int) { - return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{140} + return file_proto_wallet_v1_wallet_proto_rawDescGZIP(), []int{137} } func (x *CronBatchResponse) GetClaimedCount() int32 { @@ -13237,11 +12985,10 @@ const file_proto_wallet_v1_wallet_proto_rawDesc = "" + "\tpage_size\x18\f \x01(\x05R\bpageSize\"f\n" + "\x19ListRechargeBillsResponse\x123\n" + "\x05bills\x18\x01 \x03(\v2\x1d.hyapp.wallet.v1.RechargeBillR\x05bills\x12\x14\n" + - "\x05total\x18\x02 \x01(\x03R\x05total\"\xa4\x01\n" + + "\x05total\x18\x02 \x01(\x03R\x05total\"y\n" + "\x12WalletFeatureFlags\x12)\n" + "\x10recharge_enabled\x18\x01 \x01(\bR\x0frechargeEnabled\x128\n" + - "\x18diamond_exchange_enabled\x18\x02 \x01(\bR\x16diamondExchangeEnabled\x12)\n" + - "\x10withdraw_enabled\x18\x03 \x01(\bR\x0fwithdrawEnabled\"m\n" + + "\x18diamond_exchange_enabled\x18\x02 \x01(\bR\x16diamondExchangeEnabled\"m\n" + "\x18GetWalletOverviewRequest\x12\x1d\n" + "\n" + "request_id\x18\x01 \x01(\tR\trequestId\x12\x19\n" + @@ -13461,31 +13208,7 @@ const file_proto_wallet_v1_wallet_proto_rawDesc = "" + "\tpage_size\x18\x06 \x01(\x05R\bpageSize\"~\n" + "\x1eListWalletTransactionsResponse\x12F\n" + "\ftransactions\x18\x01 \x03(\v2\".hyapp.wallet.v1.WalletTransactionR\ftransactions\x12\x14\n" + - "\x05total\x18\x02 \x01(\x03R\x05total\"\xa7\x02\n" + - "\x11WithdrawalRequest\x12#\n" + - "\rwithdrawal_id\x18\x01 \x01(\tR\fwithdrawalId\x12\x17\n" + - "\auser_id\x18\x02 \x01(\x03R\x06userId\x12\x1d\n" + - "\n" + - "asset_type\x18\x03 \x01(\tR\tassetType\x12\x16\n" + - "\x06amount\x18\x04 \x01(\x03R\x06amount\x12\x16\n" + - "\x06status\x18\x05 \x01(\tR\x06status\x12%\n" + - "\x0epayout_account\x18\x06 \x01(\tR\rpayoutAccount\x12\x16\n" + - "\x06reason\x18\a \x01(\tR\x06reason\x12\"\n" + - "\rcreated_at_ms\x18\b \x01(\x03R\vcreatedAtMs\x12\"\n" + - "\rupdated_at_ms\x18\t \x01(\x03R\vupdatedAtMs\"\xc2\x01\n" + - "\x16ApplyWithdrawalRequest\x12\x1d\n" + - "\n" + - "command_id\x18\x01 \x01(\tR\tcommandId\x12\x19\n" + - "\bapp_code\x18\x02 \x01(\tR\aappCode\x12\x17\n" + - "\auser_id\x18\x03 \x01(\x03R\x06userId\x12\x16\n" + - "\x06amount\x18\x04 \x01(\x03R\x06amount\x12%\n" + - "\x0epayout_account\x18\x05 \x01(\tR\rpayoutAccount\x12\x16\n" + - "\x06reason\x18\x06 \x01(\tR\x06reason\"\x96\x01\n" + - "\x17ApplyWithdrawalResponse\x12B\n" + - "\n" + - "withdrawal\x18\x01 \x01(\v2\".hyapp.wallet.v1.WithdrawalRequestR\n" + - "withdrawal\x127\n" + - "\abalance\x18\x02 \x01(\v2\x1d.hyapp.wallet.v1.AssetBalanceR\abalance\"\xb1\x02\n" + + "\x05total\x18\x02 \x01(\x03R\x05total\"\xb1\x02\n" + "\rVipRewardItem\x12\x1f\n" + "\vresource_id\x18\x01 \x01(\x03R\n" + "resourceId\x12#\n" + @@ -13829,7 +13552,7 @@ const file_proto_wallet_v1_wallet_proto_rawDesc = "" + "\x11WalletCronService\x12n\n" + "%ProcessHostSalaryDailySettlementBatch\x12!.hyapp.wallet.v1.CronBatchRequest\x1a\".hyapp.wallet.v1.CronBatchResponse\x12r\n" + ")ProcessHostSalaryHalfMonthSettlementBatch\x12!.hyapp.wallet.v1.CronBatchRequest\x1a\".hyapp.wallet.v1.CronBatchResponse\x12g\n" + - "\x1eProcessHostSalaryMonthEndBatch\x12!.hyapp.wallet.v1.CronBatchRequest\x1a\".hyapp.wallet.v1.CronBatchResponse2\xe52\n" + + "\x1eProcessHostSalaryMonthEndBatch\x12!.hyapp.wallet.v1.CronBatchRequest\x1a\".hyapp.wallet.v1.CronBatchResponse2\xff1\n" + "\rWalletService\x12R\n" + "\tDebitGift\x12!.hyapp.wallet.v1.DebitGiftRequest\x1a\".hyapp.wallet.v1.DebitGiftResponse\x12X\n" + "\vGetBalances\x12#.hyapp.wallet.v1.GetBalancesRequest\x1a$.hyapp.wallet.v1.GetBalancesResponse\x12g\n" + @@ -13873,7 +13596,6 @@ const file_proto_wallet_v1_wallet_proto_rawDesc = "" + "\x15DeleteRechargeProduct\x12-.hyapp.wallet.v1.DeleteRechargeProductRequest\x1a..hyapp.wallet.v1.DeleteRechargeProductResponse\x12\x7f\n" + "\x18GetDiamondExchangeConfig\x120.hyapp.wallet.v1.GetDiamondExchangeConfigRequest\x1a1.hyapp.wallet.v1.GetDiamondExchangeConfigResponse\x12y\n" + "\x16ListWalletTransactions\x12..hyapp.wallet.v1.ListWalletTransactionsRequest\x1a/.hyapp.wallet.v1.ListWalletTransactionsResponse\x12d\n" + - "\x0fApplyWithdrawal\x12'.hyapp.wallet.v1.ApplyWithdrawalRequest\x1a(.hyapp.wallet.v1.ApplyWithdrawalResponse\x12d\n" + "\x0fListVipPackages\x12'.hyapp.wallet.v1.ListVipPackagesRequest\x1a(.hyapp.wallet.v1.ListVipPackagesResponse\x12O\n" + "\bGetMyVip\x12 .hyapp.wallet.v1.GetMyVipRequest\x1a!.hyapp.wallet.v1.GetMyVipResponse\x12X\n" + "\vPurchaseVip\x12#.hyapp.wallet.v1.PurchaseVipRequest\x1a$.hyapp.wallet.v1.PurchaseVipResponse\x12O\n" + @@ -13904,7 +13626,7 @@ func file_proto_wallet_v1_wallet_proto_rawDescGZIP() []byte { return file_proto_wallet_v1_wallet_proto_rawDescData } -var file_proto_wallet_v1_wallet_proto_msgTypes = make([]protoimpl.MessageInfo, 141) +var file_proto_wallet_v1_wallet_proto_msgTypes = make([]protoimpl.MessageInfo, 138) var file_proto_wallet_v1_wallet_proto_goTypes = []any{ (*DebitGiftRequest)(nil), // 0: hyapp.wallet.v1.DebitGiftRequest (*DebitGiftResponse)(nil), // 1: hyapp.wallet.v1.DebitGiftResponse @@ -14001,52 +13723,49 @@ var file_proto_wallet_v1_wallet_proto_goTypes = []any{ (*WalletTransaction)(nil), // 92: hyapp.wallet.v1.WalletTransaction (*ListWalletTransactionsRequest)(nil), // 93: hyapp.wallet.v1.ListWalletTransactionsRequest (*ListWalletTransactionsResponse)(nil), // 94: hyapp.wallet.v1.ListWalletTransactionsResponse - (*WithdrawalRequest)(nil), // 95: hyapp.wallet.v1.WithdrawalRequest - (*ApplyWithdrawalRequest)(nil), // 96: hyapp.wallet.v1.ApplyWithdrawalRequest - (*ApplyWithdrawalResponse)(nil), // 97: hyapp.wallet.v1.ApplyWithdrawalResponse - (*VipRewardItem)(nil), // 98: hyapp.wallet.v1.VipRewardItem - (*VipLevel)(nil), // 99: hyapp.wallet.v1.VipLevel - (*UserVip)(nil), // 100: hyapp.wallet.v1.UserVip - (*ListVipPackagesRequest)(nil), // 101: hyapp.wallet.v1.ListVipPackagesRequest - (*ListVipPackagesResponse)(nil), // 102: hyapp.wallet.v1.ListVipPackagesResponse - (*GetMyVipRequest)(nil), // 103: hyapp.wallet.v1.GetMyVipRequest - (*GetMyVipResponse)(nil), // 104: hyapp.wallet.v1.GetMyVipResponse - (*PurchaseVipRequest)(nil), // 105: hyapp.wallet.v1.PurchaseVipRequest - (*PurchaseVipResponse)(nil), // 106: hyapp.wallet.v1.PurchaseVipResponse - (*GrantVipRequest)(nil), // 107: hyapp.wallet.v1.GrantVipRequest - (*GrantVipResponse)(nil), // 108: hyapp.wallet.v1.GrantVipResponse - (*AdminVipLevelInput)(nil), // 109: hyapp.wallet.v1.AdminVipLevelInput - (*ListAdminVipLevelsRequest)(nil), // 110: hyapp.wallet.v1.ListAdminVipLevelsRequest - (*ListAdminVipLevelsResponse)(nil), // 111: hyapp.wallet.v1.ListAdminVipLevelsResponse - (*UpdateAdminVipLevelsRequest)(nil), // 112: hyapp.wallet.v1.UpdateAdminVipLevelsRequest - (*UpdateAdminVipLevelsResponse)(nil), // 113: hyapp.wallet.v1.UpdateAdminVipLevelsResponse - (*CreditTaskRewardRequest)(nil), // 114: hyapp.wallet.v1.CreditTaskRewardRequest - (*CreditTaskRewardResponse)(nil), // 115: hyapp.wallet.v1.CreditTaskRewardResponse - (*CreditLuckyGiftRewardRequest)(nil), // 116: hyapp.wallet.v1.CreditLuckyGiftRewardRequest - (*CreditLuckyGiftRewardResponse)(nil), // 117: hyapp.wallet.v1.CreditLuckyGiftRewardResponse - (*ApplyGameCoinChangeRequest)(nil), // 118: hyapp.wallet.v1.ApplyGameCoinChangeRequest - (*ApplyGameCoinChangeResponse)(nil), // 119: hyapp.wallet.v1.ApplyGameCoinChangeResponse - (*RedPacketConfig)(nil), // 120: hyapp.wallet.v1.RedPacketConfig - (*RedPacketClaim)(nil), // 121: hyapp.wallet.v1.RedPacketClaim - (*RedPacket)(nil), // 122: hyapp.wallet.v1.RedPacket - (*GetRedPacketConfigRequest)(nil), // 123: hyapp.wallet.v1.GetRedPacketConfigRequest - (*GetRedPacketConfigResponse)(nil), // 124: hyapp.wallet.v1.GetRedPacketConfigResponse - (*UpdateRedPacketConfigRequest)(nil), // 125: hyapp.wallet.v1.UpdateRedPacketConfigRequest - (*UpdateRedPacketConfigResponse)(nil), // 126: hyapp.wallet.v1.UpdateRedPacketConfigResponse - (*CreateRedPacketRequest)(nil), // 127: hyapp.wallet.v1.CreateRedPacketRequest - (*CreateRedPacketResponse)(nil), // 128: hyapp.wallet.v1.CreateRedPacketResponse - (*ClaimRedPacketRequest)(nil), // 129: hyapp.wallet.v1.ClaimRedPacketRequest - (*ClaimRedPacketResponse)(nil), // 130: hyapp.wallet.v1.ClaimRedPacketResponse - (*ListRedPacketsRequest)(nil), // 131: hyapp.wallet.v1.ListRedPacketsRequest - (*ListRedPacketsResponse)(nil), // 132: hyapp.wallet.v1.ListRedPacketsResponse - (*GetRedPacketRequest)(nil), // 133: hyapp.wallet.v1.GetRedPacketRequest - (*GetRedPacketResponse)(nil), // 134: hyapp.wallet.v1.GetRedPacketResponse - (*ExpireRedPacketsRequest)(nil), // 135: hyapp.wallet.v1.ExpireRedPacketsRequest - (*ExpireRedPacketsResponse)(nil), // 136: hyapp.wallet.v1.ExpireRedPacketsResponse - (*RetryRedPacketRefundRequest)(nil), // 137: hyapp.wallet.v1.RetryRedPacketRefundRequest - (*RetryRedPacketRefundResponse)(nil), // 138: hyapp.wallet.v1.RetryRedPacketRefundResponse - (*CronBatchRequest)(nil), // 139: hyapp.wallet.v1.CronBatchRequest - (*CronBatchResponse)(nil), // 140: hyapp.wallet.v1.CronBatchResponse + (*VipRewardItem)(nil), // 95: hyapp.wallet.v1.VipRewardItem + (*VipLevel)(nil), // 96: hyapp.wallet.v1.VipLevel + (*UserVip)(nil), // 97: hyapp.wallet.v1.UserVip + (*ListVipPackagesRequest)(nil), // 98: hyapp.wallet.v1.ListVipPackagesRequest + (*ListVipPackagesResponse)(nil), // 99: hyapp.wallet.v1.ListVipPackagesResponse + (*GetMyVipRequest)(nil), // 100: hyapp.wallet.v1.GetMyVipRequest + (*GetMyVipResponse)(nil), // 101: hyapp.wallet.v1.GetMyVipResponse + (*PurchaseVipRequest)(nil), // 102: hyapp.wallet.v1.PurchaseVipRequest + (*PurchaseVipResponse)(nil), // 103: hyapp.wallet.v1.PurchaseVipResponse + (*GrantVipRequest)(nil), // 104: hyapp.wallet.v1.GrantVipRequest + (*GrantVipResponse)(nil), // 105: hyapp.wallet.v1.GrantVipResponse + (*AdminVipLevelInput)(nil), // 106: hyapp.wallet.v1.AdminVipLevelInput + (*ListAdminVipLevelsRequest)(nil), // 107: hyapp.wallet.v1.ListAdminVipLevelsRequest + (*ListAdminVipLevelsResponse)(nil), // 108: hyapp.wallet.v1.ListAdminVipLevelsResponse + (*UpdateAdminVipLevelsRequest)(nil), // 109: hyapp.wallet.v1.UpdateAdminVipLevelsRequest + (*UpdateAdminVipLevelsResponse)(nil), // 110: hyapp.wallet.v1.UpdateAdminVipLevelsResponse + (*CreditTaskRewardRequest)(nil), // 111: hyapp.wallet.v1.CreditTaskRewardRequest + (*CreditTaskRewardResponse)(nil), // 112: hyapp.wallet.v1.CreditTaskRewardResponse + (*CreditLuckyGiftRewardRequest)(nil), // 113: hyapp.wallet.v1.CreditLuckyGiftRewardRequest + (*CreditLuckyGiftRewardResponse)(nil), // 114: hyapp.wallet.v1.CreditLuckyGiftRewardResponse + (*ApplyGameCoinChangeRequest)(nil), // 115: hyapp.wallet.v1.ApplyGameCoinChangeRequest + (*ApplyGameCoinChangeResponse)(nil), // 116: hyapp.wallet.v1.ApplyGameCoinChangeResponse + (*RedPacketConfig)(nil), // 117: hyapp.wallet.v1.RedPacketConfig + (*RedPacketClaim)(nil), // 118: hyapp.wallet.v1.RedPacketClaim + (*RedPacket)(nil), // 119: hyapp.wallet.v1.RedPacket + (*GetRedPacketConfigRequest)(nil), // 120: hyapp.wallet.v1.GetRedPacketConfigRequest + (*GetRedPacketConfigResponse)(nil), // 121: hyapp.wallet.v1.GetRedPacketConfigResponse + (*UpdateRedPacketConfigRequest)(nil), // 122: hyapp.wallet.v1.UpdateRedPacketConfigRequest + (*UpdateRedPacketConfigResponse)(nil), // 123: hyapp.wallet.v1.UpdateRedPacketConfigResponse + (*CreateRedPacketRequest)(nil), // 124: hyapp.wallet.v1.CreateRedPacketRequest + (*CreateRedPacketResponse)(nil), // 125: hyapp.wallet.v1.CreateRedPacketResponse + (*ClaimRedPacketRequest)(nil), // 126: hyapp.wallet.v1.ClaimRedPacketRequest + (*ClaimRedPacketResponse)(nil), // 127: hyapp.wallet.v1.ClaimRedPacketResponse + (*ListRedPacketsRequest)(nil), // 128: hyapp.wallet.v1.ListRedPacketsRequest + (*ListRedPacketsResponse)(nil), // 129: hyapp.wallet.v1.ListRedPacketsResponse + (*GetRedPacketRequest)(nil), // 130: hyapp.wallet.v1.GetRedPacketRequest + (*GetRedPacketResponse)(nil), // 131: hyapp.wallet.v1.GetRedPacketResponse + (*ExpireRedPacketsRequest)(nil), // 132: hyapp.wallet.v1.ExpireRedPacketsRequest + (*ExpireRedPacketsResponse)(nil), // 133: hyapp.wallet.v1.ExpireRedPacketsResponse + (*RetryRedPacketRefundRequest)(nil), // 134: hyapp.wallet.v1.RetryRedPacketRefundRequest + (*RetryRedPacketRefundResponse)(nil), // 135: hyapp.wallet.v1.RetryRedPacketRefundResponse + (*CronBatchRequest)(nil), // 136: hyapp.wallet.v1.CronBatchRequest + (*CronBatchResponse)(nil), // 137: hyapp.wallet.v1.CronBatchResponse } var file_proto_wallet_v1_wallet_proto_depIdxs = []int32{ 2, // 0: hyapp.wallet.v1.GetBalancesResponse.balances:type_name -> hyapp.wallet.v1.AssetBalance @@ -14092,161 +13811,157 @@ var file_proto_wallet_v1_wallet_proto_depIdxs = []int32{ 77, // 40: hyapp.wallet.v1.RechargeProductResponse.product:type_name -> hyapp.wallet.v1.RechargeProduct 89, // 41: hyapp.wallet.v1.GetDiamondExchangeConfigResponse.rules:type_name -> hyapp.wallet.v1.DiamondExchangeRule 92, // 42: hyapp.wallet.v1.ListWalletTransactionsResponse.transactions:type_name -> hyapp.wallet.v1.WalletTransaction - 95, // 43: hyapp.wallet.v1.ApplyWithdrawalResponse.withdrawal:type_name -> hyapp.wallet.v1.WithdrawalRequest - 2, // 44: hyapp.wallet.v1.ApplyWithdrawalResponse.balance:type_name -> hyapp.wallet.v1.AssetBalance - 98, // 45: hyapp.wallet.v1.VipLevel.reward_items:type_name -> hyapp.wallet.v1.VipRewardItem - 100, // 46: hyapp.wallet.v1.ListVipPackagesResponse.current_vip:type_name -> hyapp.wallet.v1.UserVip - 99, // 47: hyapp.wallet.v1.ListVipPackagesResponse.packages:type_name -> hyapp.wallet.v1.VipLevel - 100, // 48: hyapp.wallet.v1.GetMyVipResponse.vip:type_name -> hyapp.wallet.v1.UserVip - 100, // 49: hyapp.wallet.v1.PurchaseVipResponse.vip:type_name -> hyapp.wallet.v1.UserVip - 98, // 50: hyapp.wallet.v1.PurchaseVipResponse.reward_items:type_name -> hyapp.wallet.v1.VipRewardItem - 100, // 51: hyapp.wallet.v1.GrantVipResponse.vip:type_name -> hyapp.wallet.v1.UserVip - 98, // 52: hyapp.wallet.v1.GrantVipResponse.reward_items:type_name -> hyapp.wallet.v1.VipRewardItem - 99, // 53: hyapp.wallet.v1.ListAdminVipLevelsResponse.levels:type_name -> hyapp.wallet.v1.VipLevel - 109, // 54: hyapp.wallet.v1.UpdateAdminVipLevelsRequest.levels:type_name -> hyapp.wallet.v1.AdminVipLevelInput - 99, // 55: hyapp.wallet.v1.UpdateAdminVipLevelsResponse.levels:type_name -> hyapp.wallet.v1.VipLevel - 2, // 56: hyapp.wallet.v1.CreditTaskRewardResponse.balance:type_name -> hyapp.wallet.v1.AssetBalance - 2, // 57: hyapp.wallet.v1.CreditLuckyGiftRewardResponse.balance:type_name -> hyapp.wallet.v1.AssetBalance - 121, // 58: hyapp.wallet.v1.RedPacket.claims:type_name -> hyapp.wallet.v1.RedPacketClaim - 120, // 59: hyapp.wallet.v1.GetRedPacketConfigResponse.config:type_name -> hyapp.wallet.v1.RedPacketConfig - 120, // 60: hyapp.wallet.v1.UpdateRedPacketConfigResponse.config:type_name -> hyapp.wallet.v1.RedPacketConfig - 122, // 61: hyapp.wallet.v1.CreateRedPacketResponse.packet:type_name -> hyapp.wallet.v1.RedPacket - 121, // 62: hyapp.wallet.v1.ClaimRedPacketResponse.claim:type_name -> hyapp.wallet.v1.RedPacketClaim - 122, // 63: hyapp.wallet.v1.ClaimRedPacketResponse.packet:type_name -> hyapp.wallet.v1.RedPacket - 122, // 64: hyapp.wallet.v1.ListRedPacketsResponse.packets:type_name -> hyapp.wallet.v1.RedPacket - 122, // 65: hyapp.wallet.v1.GetRedPacketResponse.packet:type_name -> hyapp.wallet.v1.RedPacket - 122, // 66: hyapp.wallet.v1.RetryRedPacketRefundResponse.packet:type_name -> hyapp.wallet.v1.RedPacket - 139, // 67: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryDailySettlementBatch:input_type -> hyapp.wallet.v1.CronBatchRequest - 139, // 68: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryHalfMonthSettlementBatch:input_type -> hyapp.wallet.v1.CronBatchRequest - 139, // 69: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryMonthEndBatch:input_type -> hyapp.wallet.v1.CronBatchRequest - 0, // 70: hyapp.wallet.v1.WalletService.DebitGift:input_type -> hyapp.wallet.v1.DebitGiftRequest - 3, // 71: hyapp.wallet.v1.WalletService.GetBalances:input_type -> hyapp.wallet.v1.GetBalancesRequest - 5, // 72: hyapp.wallet.v1.WalletService.AdminCreditAsset:input_type -> hyapp.wallet.v1.AdminCreditAssetRequest - 7, // 73: hyapp.wallet.v1.WalletService.AdminCreditCoinSellerStock:input_type -> hyapp.wallet.v1.AdminCreditCoinSellerStockRequest - 9, // 74: hyapp.wallet.v1.WalletService.TransferCoinFromSeller:input_type -> hyapp.wallet.v1.TransferCoinFromSellerRequest - 21, // 75: hyapp.wallet.v1.WalletService.ListResources:input_type -> hyapp.wallet.v1.ListResourcesRequest - 23, // 76: hyapp.wallet.v1.WalletService.GetResource:input_type -> hyapp.wallet.v1.GetResourceRequest - 25, // 77: hyapp.wallet.v1.WalletService.CreateResource:input_type -> hyapp.wallet.v1.CreateResourceRequest - 26, // 78: hyapp.wallet.v1.WalletService.UpdateResource:input_type -> hyapp.wallet.v1.UpdateResourceRequest - 27, // 79: hyapp.wallet.v1.WalletService.SetResourceStatus:input_type -> hyapp.wallet.v1.SetResourceStatusRequest - 29, // 80: hyapp.wallet.v1.WalletService.ListResourceGroups:input_type -> hyapp.wallet.v1.ListResourceGroupsRequest - 31, // 81: hyapp.wallet.v1.WalletService.GetResourceGroup:input_type -> hyapp.wallet.v1.GetResourceGroupRequest - 33, // 82: hyapp.wallet.v1.WalletService.CreateResourceGroup:input_type -> hyapp.wallet.v1.CreateResourceGroupRequest - 34, // 83: hyapp.wallet.v1.WalletService.UpdateResourceGroup:input_type -> hyapp.wallet.v1.UpdateResourceGroupRequest - 35, // 84: hyapp.wallet.v1.WalletService.SetResourceGroupStatus:input_type -> hyapp.wallet.v1.SetResourceGroupStatusRequest - 37, // 85: hyapp.wallet.v1.WalletService.ListGiftConfigs:input_type -> hyapp.wallet.v1.ListGiftConfigsRequest - 39, // 86: hyapp.wallet.v1.WalletService.ListGiftTypeConfigs:input_type -> hyapp.wallet.v1.ListGiftTypeConfigsRequest - 43, // 87: hyapp.wallet.v1.WalletService.CreateGiftConfig:input_type -> hyapp.wallet.v1.CreateGiftConfigRequest - 44, // 88: hyapp.wallet.v1.WalletService.UpdateGiftConfig:input_type -> hyapp.wallet.v1.UpdateGiftConfigRequest - 45, // 89: hyapp.wallet.v1.WalletService.SetGiftConfigStatus:input_type -> hyapp.wallet.v1.SetGiftConfigStatusRequest - 41, // 90: hyapp.wallet.v1.WalletService.UpsertGiftTypeConfig:input_type -> hyapp.wallet.v1.UpsertGiftTypeConfigRequest - 47, // 91: hyapp.wallet.v1.WalletService.GrantResource:input_type -> hyapp.wallet.v1.GrantResourceRequest - 48, // 92: hyapp.wallet.v1.WalletService.GrantResourceGroup:input_type -> hyapp.wallet.v1.GrantResourceGroupRequest - 50, // 93: hyapp.wallet.v1.WalletService.ListUserResources:input_type -> hyapp.wallet.v1.ListUserResourcesRequest - 52, // 94: hyapp.wallet.v1.WalletService.EquipUserResource:input_type -> hyapp.wallet.v1.EquipUserResourceRequest - 54, // 95: hyapp.wallet.v1.WalletService.ListResourceGrants:input_type -> hyapp.wallet.v1.ListResourceGrantsRequest - 57, // 96: hyapp.wallet.v1.WalletService.ListResourceShopItems:input_type -> hyapp.wallet.v1.ListResourceShopItemsRequest - 59, // 97: hyapp.wallet.v1.WalletService.UpsertResourceShopItems:input_type -> hyapp.wallet.v1.UpsertResourceShopItemsRequest - 61, // 98: hyapp.wallet.v1.WalletService.SetResourceShopItemStatus:input_type -> hyapp.wallet.v1.SetResourceShopItemStatusRequest - 63, // 99: hyapp.wallet.v1.WalletService.PurchaseResourceShopItem:input_type -> hyapp.wallet.v1.PurchaseResourceShopItemRequest - 66, // 100: hyapp.wallet.v1.WalletService.ListRechargeBills:input_type -> hyapp.wallet.v1.ListRechargeBillsRequest - 69, // 101: hyapp.wallet.v1.WalletService.GetWalletOverview:input_type -> hyapp.wallet.v1.GetWalletOverviewRequest - 72, // 102: hyapp.wallet.v1.WalletService.GetWalletValueSummary:input_type -> hyapp.wallet.v1.GetWalletValueSummaryRequest - 75, // 103: hyapp.wallet.v1.WalletService.GetUserGiftWall:input_type -> hyapp.wallet.v1.GetUserGiftWallRequest - 78, // 104: hyapp.wallet.v1.WalletService.ListRechargeProducts:input_type -> hyapp.wallet.v1.ListRechargeProductsRequest - 80, // 105: hyapp.wallet.v1.WalletService.ConfirmGooglePayment:input_type -> hyapp.wallet.v1.ConfirmGooglePaymentRequest - 82, // 106: hyapp.wallet.v1.WalletService.ListAdminRechargeProducts:input_type -> hyapp.wallet.v1.ListAdminRechargeProductsRequest - 84, // 107: hyapp.wallet.v1.WalletService.CreateRechargeProduct:input_type -> hyapp.wallet.v1.CreateRechargeProductRequest - 85, // 108: hyapp.wallet.v1.WalletService.UpdateRechargeProduct:input_type -> hyapp.wallet.v1.UpdateRechargeProductRequest - 86, // 109: hyapp.wallet.v1.WalletService.DeleteRechargeProduct:input_type -> hyapp.wallet.v1.DeleteRechargeProductRequest - 90, // 110: hyapp.wallet.v1.WalletService.GetDiamondExchangeConfig:input_type -> hyapp.wallet.v1.GetDiamondExchangeConfigRequest - 93, // 111: hyapp.wallet.v1.WalletService.ListWalletTransactions:input_type -> hyapp.wallet.v1.ListWalletTransactionsRequest - 96, // 112: hyapp.wallet.v1.WalletService.ApplyWithdrawal:input_type -> hyapp.wallet.v1.ApplyWithdrawalRequest - 101, // 113: hyapp.wallet.v1.WalletService.ListVipPackages:input_type -> hyapp.wallet.v1.ListVipPackagesRequest - 103, // 114: hyapp.wallet.v1.WalletService.GetMyVip:input_type -> hyapp.wallet.v1.GetMyVipRequest - 105, // 115: hyapp.wallet.v1.WalletService.PurchaseVip:input_type -> hyapp.wallet.v1.PurchaseVipRequest - 107, // 116: hyapp.wallet.v1.WalletService.GrantVip:input_type -> hyapp.wallet.v1.GrantVipRequest - 110, // 117: hyapp.wallet.v1.WalletService.ListAdminVipLevels:input_type -> hyapp.wallet.v1.ListAdminVipLevelsRequest - 112, // 118: hyapp.wallet.v1.WalletService.UpdateAdminVipLevels:input_type -> hyapp.wallet.v1.UpdateAdminVipLevelsRequest - 114, // 119: hyapp.wallet.v1.WalletService.CreditTaskReward:input_type -> hyapp.wallet.v1.CreditTaskRewardRequest - 116, // 120: hyapp.wallet.v1.WalletService.CreditLuckyGiftReward:input_type -> hyapp.wallet.v1.CreditLuckyGiftRewardRequest - 118, // 121: hyapp.wallet.v1.WalletService.ApplyGameCoinChange:input_type -> hyapp.wallet.v1.ApplyGameCoinChangeRequest - 123, // 122: hyapp.wallet.v1.WalletService.GetRedPacketConfig:input_type -> hyapp.wallet.v1.GetRedPacketConfigRequest - 125, // 123: hyapp.wallet.v1.WalletService.UpdateRedPacketConfig:input_type -> hyapp.wallet.v1.UpdateRedPacketConfigRequest - 127, // 124: hyapp.wallet.v1.WalletService.CreateRedPacket:input_type -> hyapp.wallet.v1.CreateRedPacketRequest - 129, // 125: hyapp.wallet.v1.WalletService.ClaimRedPacket:input_type -> hyapp.wallet.v1.ClaimRedPacketRequest - 131, // 126: hyapp.wallet.v1.WalletService.ListRedPackets:input_type -> hyapp.wallet.v1.ListRedPacketsRequest - 133, // 127: hyapp.wallet.v1.WalletService.GetRedPacket:input_type -> hyapp.wallet.v1.GetRedPacketRequest - 135, // 128: hyapp.wallet.v1.WalletService.ExpireRedPackets:input_type -> hyapp.wallet.v1.ExpireRedPacketsRequest - 137, // 129: hyapp.wallet.v1.WalletService.RetryRedPacketRefund:input_type -> hyapp.wallet.v1.RetryRedPacketRefundRequest - 140, // 130: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryDailySettlementBatch:output_type -> hyapp.wallet.v1.CronBatchResponse - 140, // 131: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryHalfMonthSettlementBatch:output_type -> hyapp.wallet.v1.CronBatchResponse - 140, // 132: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryMonthEndBatch:output_type -> hyapp.wallet.v1.CronBatchResponse - 1, // 133: hyapp.wallet.v1.WalletService.DebitGift:output_type -> hyapp.wallet.v1.DebitGiftResponse - 4, // 134: hyapp.wallet.v1.WalletService.GetBalances:output_type -> hyapp.wallet.v1.GetBalancesResponse - 6, // 135: hyapp.wallet.v1.WalletService.AdminCreditAsset:output_type -> hyapp.wallet.v1.AdminCreditAssetResponse - 8, // 136: hyapp.wallet.v1.WalletService.AdminCreditCoinSellerStock:output_type -> hyapp.wallet.v1.AdminCreditCoinSellerStockResponse - 10, // 137: hyapp.wallet.v1.WalletService.TransferCoinFromSeller:output_type -> hyapp.wallet.v1.TransferCoinFromSellerResponse - 22, // 138: hyapp.wallet.v1.WalletService.ListResources:output_type -> hyapp.wallet.v1.ListResourcesResponse - 24, // 139: hyapp.wallet.v1.WalletService.GetResource:output_type -> hyapp.wallet.v1.GetResourceResponse - 28, // 140: hyapp.wallet.v1.WalletService.CreateResource:output_type -> hyapp.wallet.v1.ResourceResponse - 28, // 141: hyapp.wallet.v1.WalletService.UpdateResource:output_type -> hyapp.wallet.v1.ResourceResponse - 28, // 142: hyapp.wallet.v1.WalletService.SetResourceStatus:output_type -> hyapp.wallet.v1.ResourceResponse - 30, // 143: hyapp.wallet.v1.WalletService.ListResourceGroups:output_type -> hyapp.wallet.v1.ListResourceGroupsResponse - 32, // 144: hyapp.wallet.v1.WalletService.GetResourceGroup:output_type -> hyapp.wallet.v1.GetResourceGroupResponse - 36, // 145: hyapp.wallet.v1.WalletService.CreateResourceGroup:output_type -> hyapp.wallet.v1.ResourceGroupResponse - 36, // 146: hyapp.wallet.v1.WalletService.UpdateResourceGroup:output_type -> hyapp.wallet.v1.ResourceGroupResponse - 36, // 147: hyapp.wallet.v1.WalletService.SetResourceGroupStatus:output_type -> hyapp.wallet.v1.ResourceGroupResponse - 38, // 148: hyapp.wallet.v1.WalletService.ListGiftConfigs:output_type -> hyapp.wallet.v1.ListGiftConfigsResponse - 40, // 149: hyapp.wallet.v1.WalletService.ListGiftTypeConfigs:output_type -> hyapp.wallet.v1.ListGiftTypeConfigsResponse - 46, // 150: hyapp.wallet.v1.WalletService.CreateGiftConfig:output_type -> hyapp.wallet.v1.GiftConfigResponse - 46, // 151: hyapp.wallet.v1.WalletService.UpdateGiftConfig:output_type -> hyapp.wallet.v1.GiftConfigResponse - 46, // 152: hyapp.wallet.v1.WalletService.SetGiftConfigStatus:output_type -> hyapp.wallet.v1.GiftConfigResponse - 42, // 153: hyapp.wallet.v1.WalletService.UpsertGiftTypeConfig:output_type -> hyapp.wallet.v1.GiftTypeConfigResponse - 49, // 154: hyapp.wallet.v1.WalletService.GrantResource:output_type -> hyapp.wallet.v1.ResourceGrantResponse - 49, // 155: hyapp.wallet.v1.WalletService.GrantResourceGroup:output_type -> hyapp.wallet.v1.ResourceGrantResponse - 51, // 156: hyapp.wallet.v1.WalletService.ListUserResources:output_type -> hyapp.wallet.v1.ListUserResourcesResponse - 53, // 157: hyapp.wallet.v1.WalletService.EquipUserResource:output_type -> hyapp.wallet.v1.EquipUserResourceResponse - 55, // 158: hyapp.wallet.v1.WalletService.ListResourceGrants:output_type -> hyapp.wallet.v1.ListResourceGrantsResponse - 58, // 159: hyapp.wallet.v1.WalletService.ListResourceShopItems:output_type -> hyapp.wallet.v1.ListResourceShopItemsResponse - 60, // 160: hyapp.wallet.v1.WalletService.UpsertResourceShopItems:output_type -> hyapp.wallet.v1.UpsertResourceShopItemsResponse - 62, // 161: hyapp.wallet.v1.WalletService.SetResourceShopItemStatus:output_type -> hyapp.wallet.v1.ResourceShopItemResponse - 64, // 162: hyapp.wallet.v1.WalletService.PurchaseResourceShopItem:output_type -> hyapp.wallet.v1.PurchaseResourceShopItemResponse - 67, // 163: hyapp.wallet.v1.WalletService.ListRechargeBills:output_type -> hyapp.wallet.v1.ListRechargeBillsResponse - 70, // 164: hyapp.wallet.v1.WalletService.GetWalletOverview:output_type -> hyapp.wallet.v1.GetWalletOverviewResponse - 73, // 165: hyapp.wallet.v1.WalletService.GetWalletValueSummary:output_type -> hyapp.wallet.v1.GetWalletValueSummaryResponse - 76, // 166: hyapp.wallet.v1.WalletService.GetUserGiftWall:output_type -> hyapp.wallet.v1.GetUserGiftWallResponse - 79, // 167: hyapp.wallet.v1.WalletService.ListRechargeProducts:output_type -> hyapp.wallet.v1.ListRechargeProductsResponse - 81, // 168: hyapp.wallet.v1.WalletService.ConfirmGooglePayment:output_type -> hyapp.wallet.v1.ConfirmGooglePaymentResponse - 83, // 169: hyapp.wallet.v1.WalletService.ListAdminRechargeProducts:output_type -> hyapp.wallet.v1.ListAdminRechargeProductsResponse - 87, // 170: hyapp.wallet.v1.WalletService.CreateRechargeProduct:output_type -> hyapp.wallet.v1.RechargeProductResponse - 87, // 171: hyapp.wallet.v1.WalletService.UpdateRechargeProduct:output_type -> hyapp.wallet.v1.RechargeProductResponse - 88, // 172: hyapp.wallet.v1.WalletService.DeleteRechargeProduct:output_type -> hyapp.wallet.v1.DeleteRechargeProductResponse - 91, // 173: hyapp.wallet.v1.WalletService.GetDiamondExchangeConfig:output_type -> hyapp.wallet.v1.GetDiamondExchangeConfigResponse - 94, // 174: hyapp.wallet.v1.WalletService.ListWalletTransactions:output_type -> hyapp.wallet.v1.ListWalletTransactionsResponse - 97, // 175: hyapp.wallet.v1.WalletService.ApplyWithdrawal:output_type -> hyapp.wallet.v1.ApplyWithdrawalResponse - 102, // 176: hyapp.wallet.v1.WalletService.ListVipPackages:output_type -> hyapp.wallet.v1.ListVipPackagesResponse - 104, // 177: hyapp.wallet.v1.WalletService.GetMyVip:output_type -> hyapp.wallet.v1.GetMyVipResponse - 106, // 178: hyapp.wallet.v1.WalletService.PurchaseVip:output_type -> hyapp.wallet.v1.PurchaseVipResponse - 108, // 179: hyapp.wallet.v1.WalletService.GrantVip:output_type -> hyapp.wallet.v1.GrantVipResponse - 111, // 180: hyapp.wallet.v1.WalletService.ListAdminVipLevels:output_type -> hyapp.wallet.v1.ListAdminVipLevelsResponse - 113, // 181: hyapp.wallet.v1.WalletService.UpdateAdminVipLevels:output_type -> hyapp.wallet.v1.UpdateAdminVipLevelsResponse - 115, // 182: hyapp.wallet.v1.WalletService.CreditTaskReward:output_type -> hyapp.wallet.v1.CreditTaskRewardResponse - 117, // 183: hyapp.wallet.v1.WalletService.CreditLuckyGiftReward:output_type -> hyapp.wallet.v1.CreditLuckyGiftRewardResponse - 119, // 184: hyapp.wallet.v1.WalletService.ApplyGameCoinChange:output_type -> hyapp.wallet.v1.ApplyGameCoinChangeResponse - 124, // 185: hyapp.wallet.v1.WalletService.GetRedPacketConfig:output_type -> hyapp.wallet.v1.GetRedPacketConfigResponse - 126, // 186: hyapp.wallet.v1.WalletService.UpdateRedPacketConfig:output_type -> hyapp.wallet.v1.UpdateRedPacketConfigResponse - 128, // 187: hyapp.wallet.v1.WalletService.CreateRedPacket:output_type -> hyapp.wallet.v1.CreateRedPacketResponse - 130, // 188: hyapp.wallet.v1.WalletService.ClaimRedPacket:output_type -> hyapp.wallet.v1.ClaimRedPacketResponse - 132, // 189: hyapp.wallet.v1.WalletService.ListRedPackets:output_type -> hyapp.wallet.v1.ListRedPacketsResponse - 134, // 190: hyapp.wallet.v1.WalletService.GetRedPacket:output_type -> hyapp.wallet.v1.GetRedPacketResponse - 136, // 191: hyapp.wallet.v1.WalletService.ExpireRedPackets:output_type -> hyapp.wallet.v1.ExpireRedPacketsResponse - 138, // 192: hyapp.wallet.v1.WalletService.RetryRedPacketRefund:output_type -> hyapp.wallet.v1.RetryRedPacketRefundResponse - 130, // [130:193] is the sub-list for method output_type - 67, // [67:130] is the sub-list for method input_type - 67, // [67:67] is the sub-list for extension type_name - 67, // [67:67] is the sub-list for extension extendee - 0, // [0:67] is the sub-list for field type_name + 95, // 43: hyapp.wallet.v1.VipLevel.reward_items:type_name -> hyapp.wallet.v1.VipRewardItem + 97, // 44: hyapp.wallet.v1.ListVipPackagesResponse.current_vip:type_name -> hyapp.wallet.v1.UserVip + 96, // 45: hyapp.wallet.v1.ListVipPackagesResponse.packages:type_name -> hyapp.wallet.v1.VipLevel + 97, // 46: hyapp.wallet.v1.GetMyVipResponse.vip:type_name -> hyapp.wallet.v1.UserVip + 97, // 47: hyapp.wallet.v1.PurchaseVipResponse.vip:type_name -> hyapp.wallet.v1.UserVip + 95, // 48: hyapp.wallet.v1.PurchaseVipResponse.reward_items:type_name -> hyapp.wallet.v1.VipRewardItem + 97, // 49: hyapp.wallet.v1.GrantVipResponse.vip:type_name -> hyapp.wallet.v1.UserVip + 95, // 50: hyapp.wallet.v1.GrantVipResponse.reward_items:type_name -> hyapp.wallet.v1.VipRewardItem + 96, // 51: hyapp.wallet.v1.ListAdminVipLevelsResponse.levels:type_name -> hyapp.wallet.v1.VipLevel + 106, // 52: hyapp.wallet.v1.UpdateAdminVipLevelsRequest.levels:type_name -> hyapp.wallet.v1.AdminVipLevelInput + 96, // 53: hyapp.wallet.v1.UpdateAdminVipLevelsResponse.levels:type_name -> hyapp.wallet.v1.VipLevel + 2, // 54: hyapp.wallet.v1.CreditTaskRewardResponse.balance:type_name -> hyapp.wallet.v1.AssetBalance + 2, // 55: hyapp.wallet.v1.CreditLuckyGiftRewardResponse.balance:type_name -> hyapp.wallet.v1.AssetBalance + 118, // 56: hyapp.wallet.v1.RedPacket.claims:type_name -> hyapp.wallet.v1.RedPacketClaim + 117, // 57: hyapp.wallet.v1.GetRedPacketConfigResponse.config:type_name -> hyapp.wallet.v1.RedPacketConfig + 117, // 58: hyapp.wallet.v1.UpdateRedPacketConfigResponse.config:type_name -> hyapp.wallet.v1.RedPacketConfig + 119, // 59: hyapp.wallet.v1.CreateRedPacketResponse.packet:type_name -> hyapp.wallet.v1.RedPacket + 118, // 60: hyapp.wallet.v1.ClaimRedPacketResponse.claim:type_name -> hyapp.wallet.v1.RedPacketClaim + 119, // 61: hyapp.wallet.v1.ClaimRedPacketResponse.packet:type_name -> hyapp.wallet.v1.RedPacket + 119, // 62: hyapp.wallet.v1.ListRedPacketsResponse.packets:type_name -> hyapp.wallet.v1.RedPacket + 119, // 63: hyapp.wallet.v1.GetRedPacketResponse.packet:type_name -> hyapp.wallet.v1.RedPacket + 119, // 64: hyapp.wallet.v1.RetryRedPacketRefundResponse.packet:type_name -> hyapp.wallet.v1.RedPacket + 136, // 65: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryDailySettlementBatch:input_type -> hyapp.wallet.v1.CronBatchRequest + 136, // 66: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryHalfMonthSettlementBatch:input_type -> hyapp.wallet.v1.CronBatchRequest + 136, // 67: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryMonthEndBatch:input_type -> hyapp.wallet.v1.CronBatchRequest + 0, // 68: hyapp.wallet.v1.WalletService.DebitGift:input_type -> hyapp.wallet.v1.DebitGiftRequest + 3, // 69: hyapp.wallet.v1.WalletService.GetBalances:input_type -> hyapp.wallet.v1.GetBalancesRequest + 5, // 70: hyapp.wallet.v1.WalletService.AdminCreditAsset:input_type -> hyapp.wallet.v1.AdminCreditAssetRequest + 7, // 71: hyapp.wallet.v1.WalletService.AdminCreditCoinSellerStock:input_type -> hyapp.wallet.v1.AdminCreditCoinSellerStockRequest + 9, // 72: hyapp.wallet.v1.WalletService.TransferCoinFromSeller:input_type -> hyapp.wallet.v1.TransferCoinFromSellerRequest + 21, // 73: hyapp.wallet.v1.WalletService.ListResources:input_type -> hyapp.wallet.v1.ListResourcesRequest + 23, // 74: hyapp.wallet.v1.WalletService.GetResource:input_type -> hyapp.wallet.v1.GetResourceRequest + 25, // 75: hyapp.wallet.v1.WalletService.CreateResource:input_type -> hyapp.wallet.v1.CreateResourceRequest + 26, // 76: hyapp.wallet.v1.WalletService.UpdateResource:input_type -> hyapp.wallet.v1.UpdateResourceRequest + 27, // 77: hyapp.wallet.v1.WalletService.SetResourceStatus:input_type -> hyapp.wallet.v1.SetResourceStatusRequest + 29, // 78: hyapp.wallet.v1.WalletService.ListResourceGroups:input_type -> hyapp.wallet.v1.ListResourceGroupsRequest + 31, // 79: hyapp.wallet.v1.WalletService.GetResourceGroup:input_type -> hyapp.wallet.v1.GetResourceGroupRequest + 33, // 80: hyapp.wallet.v1.WalletService.CreateResourceGroup:input_type -> hyapp.wallet.v1.CreateResourceGroupRequest + 34, // 81: hyapp.wallet.v1.WalletService.UpdateResourceGroup:input_type -> hyapp.wallet.v1.UpdateResourceGroupRequest + 35, // 82: hyapp.wallet.v1.WalletService.SetResourceGroupStatus:input_type -> hyapp.wallet.v1.SetResourceGroupStatusRequest + 37, // 83: hyapp.wallet.v1.WalletService.ListGiftConfigs:input_type -> hyapp.wallet.v1.ListGiftConfigsRequest + 39, // 84: hyapp.wallet.v1.WalletService.ListGiftTypeConfigs:input_type -> hyapp.wallet.v1.ListGiftTypeConfigsRequest + 43, // 85: hyapp.wallet.v1.WalletService.CreateGiftConfig:input_type -> hyapp.wallet.v1.CreateGiftConfigRequest + 44, // 86: hyapp.wallet.v1.WalletService.UpdateGiftConfig:input_type -> hyapp.wallet.v1.UpdateGiftConfigRequest + 45, // 87: hyapp.wallet.v1.WalletService.SetGiftConfigStatus:input_type -> hyapp.wallet.v1.SetGiftConfigStatusRequest + 41, // 88: hyapp.wallet.v1.WalletService.UpsertGiftTypeConfig:input_type -> hyapp.wallet.v1.UpsertGiftTypeConfigRequest + 47, // 89: hyapp.wallet.v1.WalletService.GrantResource:input_type -> hyapp.wallet.v1.GrantResourceRequest + 48, // 90: hyapp.wallet.v1.WalletService.GrantResourceGroup:input_type -> hyapp.wallet.v1.GrantResourceGroupRequest + 50, // 91: hyapp.wallet.v1.WalletService.ListUserResources:input_type -> hyapp.wallet.v1.ListUserResourcesRequest + 52, // 92: hyapp.wallet.v1.WalletService.EquipUserResource:input_type -> hyapp.wallet.v1.EquipUserResourceRequest + 54, // 93: hyapp.wallet.v1.WalletService.ListResourceGrants:input_type -> hyapp.wallet.v1.ListResourceGrantsRequest + 57, // 94: hyapp.wallet.v1.WalletService.ListResourceShopItems:input_type -> hyapp.wallet.v1.ListResourceShopItemsRequest + 59, // 95: hyapp.wallet.v1.WalletService.UpsertResourceShopItems:input_type -> hyapp.wallet.v1.UpsertResourceShopItemsRequest + 61, // 96: hyapp.wallet.v1.WalletService.SetResourceShopItemStatus:input_type -> hyapp.wallet.v1.SetResourceShopItemStatusRequest + 63, // 97: hyapp.wallet.v1.WalletService.PurchaseResourceShopItem:input_type -> hyapp.wallet.v1.PurchaseResourceShopItemRequest + 66, // 98: hyapp.wallet.v1.WalletService.ListRechargeBills:input_type -> hyapp.wallet.v1.ListRechargeBillsRequest + 69, // 99: hyapp.wallet.v1.WalletService.GetWalletOverview:input_type -> hyapp.wallet.v1.GetWalletOverviewRequest + 72, // 100: hyapp.wallet.v1.WalletService.GetWalletValueSummary:input_type -> hyapp.wallet.v1.GetWalletValueSummaryRequest + 75, // 101: hyapp.wallet.v1.WalletService.GetUserGiftWall:input_type -> hyapp.wallet.v1.GetUserGiftWallRequest + 78, // 102: hyapp.wallet.v1.WalletService.ListRechargeProducts:input_type -> hyapp.wallet.v1.ListRechargeProductsRequest + 80, // 103: hyapp.wallet.v1.WalletService.ConfirmGooglePayment:input_type -> hyapp.wallet.v1.ConfirmGooglePaymentRequest + 82, // 104: hyapp.wallet.v1.WalletService.ListAdminRechargeProducts:input_type -> hyapp.wallet.v1.ListAdminRechargeProductsRequest + 84, // 105: hyapp.wallet.v1.WalletService.CreateRechargeProduct:input_type -> hyapp.wallet.v1.CreateRechargeProductRequest + 85, // 106: hyapp.wallet.v1.WalletService.UpdateRechargeProduct:input_type -> hyapp.wallet.v1.UpdateRechargeProductRequest + 86, // 107: hyapp.wallet.v1.WalletService.DeleteRechargeProduct:input_type -> hyapp.wallet.v1.DeleteRechargeProductRequest + 90, // 108: hyapp.wallet.v1.WalletService.GetDiamondExchangeConfig:input_type -> hyapp.wallet.v1.GetDiamondExchangeConfigRequest + 93, // 109: hyapp.wallet.v1.WalletService.ListWalletTransactions:input_type -> hyapp.wallet.v1.ListWalletTransactionsRequest + 98, // 110: hyapp.wallet.v1.WalletService.ListVipPackages:input_type -> hyapp.wallet.v1.ListVipPackagesRequest + 100, // 111: hyapp.wallet.v1.WalletService.GetMyVip:input_type -> hyapp.wallet.v1.GetMyVipRequest + 102, // 112: hyapp.wallet.v1.WalletService.PurchaseVip:input_type -> hyapp.wallet.v1.PurchaseVipRequest + 104, // 113: hyapp.wallet.v1.WalletService.GrantVip:input_type -> hyapp.wallet.v1.GrantVipRequest + 107, // 114: hyapp.wallet.v1.WalletService.ListAdminVipLevels:input_type -> hyapp.wallet.v1.ListAdminVipLevelsRequest + 109, // 115: hyapp.wallet.v1.WalletService.UpdateAdminVipLevels:input_type -> hyapp.wallet.v1.UpdateAdminVipLevelsRequest + 111, // 116: hyapp.wallet.v1.WalletService.CreditTaskReward:input_type -> hyapp.wallet.v1.CreditTaskRewardRequest + 113, // 117: hyapp.wallet.v1.WalletService.CreditLuckyGiftReward:input_type -> hyapp.wallet.v1.CreditLuckyGiftRewardRequest + 115, // 118: hyapp.wallet.v1.WalletService.ApplyGameCoinChange:input_type -> hyapp.wallet.v1.ApplyGameCoinChangeRequest + 120, // 119: hyapp.wallet.v1.WalletService.GetRedPacketConfig:input_type -> hyapp.wallet.v1.GetRedPacketConfigRequest + 122, // 120: hyapp.wallet.v1.WalletService.UpdateRedPacketConfig:input_type -> hyapp.wallet.v1.UpdateRedPacketConfigRequest + 124, // 121: hyapp.wallet.v1.WalletService.CreateRedPacket:input_type -> hyapp.wallet.v1.CreateRedPacketRequest + 126, // 122: hyapp.wallet.v1.WalletService.ClaimRedPacket:input_type -> hyapp.wallet.v1.ClaimRedPacketRequest + 128, // 123: hyapp.wallet.v1.WalletService.ListRedPackets:input_type -> hyapp.wallet.v1.ListRedPacketsRequest + 130, // 124: hyapp.wallet.v1.WalletService.GetRedPacket:input_type -> hyapp.wallet.v1.GetRedPacketRequest + 132, // 125: hyapp.wallet.v1.WalletService.ExpireRedPackets:input_type -> hyapp.wallet.v1.ExpireRedPacketsRequest + 134, // 126: hyapp.wallet.v1.WalletService.RetryRedPacketRefund:input_type -> hyapp.wallet.v1.RetryRedPacketRefundRequest + 137, // 127: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryDailySettlementBatch:output_type -> hyapp.wallet.v1.CronBatchResponse + 137, // 128: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryHalfMonthSettlementBatch:output_type -> hyapp.wallet.v1.CronBatchResponse + 137, // 129: hyapp.wallet.v1.WalletCronService.ProcessHostSalaryMonthEndBatch:output_type -> hyapp.wallet.v1.CronBatchResponse + 1, // 130: hyapp.wallet.v1.WalletService.DebitGift:output_type -> hyapp.wallet.v1.DebitGiftResponse + 4, // 131: hyapp.wallet.v1.WalletService.GetBalances:output_type -> hyapp.wallet.v1.GetBalancesResponse + 6, // 132: hyapp.wallet.v1.WalletService.AdminCreditAsset:output_type -> hyapp.wallet.v1.AdminCreditAssetResponse + 8, // 133: hyapp.wallet.v1.WalletService.AdminCreditCoinSellerStock:output_type -> hyapp.wallet.v1.AdminCreditCoinSellerStockResponse + 10, // 134: hyapp.wallet.v1.WalletService.TransferCoinFromSeller:output_type -> hyapp.wallet.v1.TransferCoinFromSellerResponse + 22, // 135: hyapp.wallet.v1.WalletService.ListResources:output_type -> hyapp.wallet.v1.ListResourcesResponse + 24, // 136: hyapp.wallet.v1.WalletService.GetResource:output_type -> hyapp.wallet.v1.GetResourceResponse + 28, // 137: hyapp.wallet.v1.WalletService.CreateResource:output_type -> hyapp.wallet.v1.ResourceResponse + 28, // 138: hyapp.wallet.v1.WalletService.UpdateResource:output_type -> hyapp.wallet.v1.ResourceResponse + 28, // 139: hyapp.wallet.v1.WalletService.SetResourceStatus:output_type -> hyapp.wallet.v1.ResourceResponse + 30, // 140: hyapp.wallet.v1.WalletService.ListResourceGroups:output_type -> hyapp.wallet.v1.ListResourceGroupsResponse + 32, // 141: hyapp.wallet.v1.WalletService.GetResourceGroup:output_type -> hyapp.wallet.v1.GetResourceGroupResponse + 36, // 142: hyapp.wallet.v1.WalletService.CreateResourceGroup:output_type -> hyapp.wallet.v1.ResourceGroupResponse + 36, // 143: hyapp.wallet.v1.WalletService.UpdateResourceGroup:output_type -> hyapp.wallet.v1.ResourceGroupResponse + 36, // 144: hyapp.wallet.v1.WalletService.SetResourceGroupStatus:output_type -> hyapp.wallet.v1.ResourceGroupResponse + 38, // 145: hyapp.wallet.v1.WalletService.ListGiftConfigs:output_type -> hyapp.wallet.v1.ListGiftConfigsResponse + 40, // 146: hyapp.wallet.v1.WalletService.ListGiftTypeConfigs:output_type -> hyapp.wallet.v1.ListGiftTypeConfigsResponse + 46, // 147: hyapp.wallet.v1.WalletService.CreateGiftConfig:output_type -> hyapp.wallet.v1.GiftConfigResponse + 46, // 148: hyapp.wallet.v1.WalletService.UpdateGiftConfig:output_type -> hyapp.wallet.v1.GiftConfigResponse + 46, // 149: hyapp.wallet.v1.WalletService.SetGiftConfigStatus:output_type -> hyapp.wallet.v1.GiftConfigResponse + 42, // 150: hyapp.wallet.v1.WalletService.UpsertGiftTypeConfig:output_type -> hyapp.wallet.v1.GiftTypeConfigResponse + 49, // 151: hyapp.wallet.v1.WalletService.GrantResource:output_type -> hyapp.wallet.v1.ResourceGrantResponse + 49, // 152: hyapp.wallet.v1.WalletService.GrantResourceGroup:output_type -> hyapp.wallet.v1.ResourceGrantResponse + 51, // 153: hyapp.wallet.v1.WalletService.ListUserResources:output_type -> hyapp.wallet.v1.ListUserResourcesResponse + 53, // 154: hyapp.wallet.v1.WalletService.EquipUserResource:output_type -> hyapp.wallet.v1.EquipUserResourceResponse + 55, // 155: hyapp.wallet.v1.WalletService.ListResourceGrants:output_type -> hyapp.wallet.v1.ListResourceGrantsResponse + 58, // 156: hyapp.wallet.v1.WalletService.ListResourceShopItems:output_type -> hyapp.wallet.v1.ListResourceShopItemsResponse + 60, // 157: hyapp.wallet.v1.WalletService.UpsertResourceShopItems:output_type -> hyapp.wallet.v1.UpsertResourceShopItemsResponse + 62, // 158: hyapp.wallet.v1.WalletService.SetResourceShopItemStatus:output_type -> hyapp.wallet.v1.ResourceShopItemResponse + 64, // 159: hyapp.wallet.v1.WalletService.PurchaseResourceShopItem:output_type -> hyapp.wallet.v1.PurchaseResourceShopItemResponse + 67, // 160: hyapp.wallet.v1.WalletService.ListRechargeBills:output_type -> hyapp.wallet.v1.ListRechargeBillsResponse + 70, // 161: hyapp.wallet.v1.WalletService.GetWalletOverview:output_type -> hyapp.wallet.v1.GetWalletOverviewResponse + 73, // 162: hyapp.wallet.v1.WalletService.GetWalletValueSummary:output_type -> hyapp.wallet.v1.GetWalletValueSummaryResponse + 76, // 163: hyapp.wallet.v1.WalletService.GetUserGiftWall:output_type -> hyapp.wallet.v1.GetUserGiftWallResponse + 79, // 164: hyapp.wallet.v1.WalletService.ListRechargeProducts:output_type -> hyapp.wallet.v1.ListRechargeProductsResponse + 81, // 165: hyapp.wallet.v1.WalletService.ConfirmGooglePayment:output_type -> hyapp.wallet.v1.ConfirmGooglePaymentResponse + 83, // 166: hyapp.wallet.v1.WalletService.ListAdminRechargeProducts:output_type -> hyapp.wallet.v1.ListAdminRechargeProductsResponse + 87, // 167: hyapp.wallet.v1.WalletService.CreateRechargeProduct:output_type -> hyapp.wallet.v1.RechargeProductResponse + 87, // 168: hyapp.wallet.v1.WalletService.UpdateRechargeProduct:output_type -> hyapp.wallet.v1.RechargeProductResponse + 88, // 169: hyapp.wallet.v1.WalletService.DeleteRechargeProduct:output_type -> hyapp.wallet.v1.DeleteRechargeProductResponse + 91, // 170: hyapp.wallet.v1.WalletService.GetDiamondExchangeConfig:output_type -> hyapp.wallet.v1.GetDiamondExchangeConfigResponse + 94, // 171: hyapp.wallet.v1.WalletService.ListWalletTransactions:output_type -> hyapp.wallet.v1.ListWalletTransactionsResponse + 99, // 172: hyapp.wallet.v1.WalletService.ListVipPackages:output_type -> hyapp.wallet.v1.ListVipPackagesResponse + 101, // 173: hyapp.wallet.v1.WalletService.GetMyVip:output_type -> hyapp.wallet.v1.GetMyVipResponse + 103, // 174: hyapp.wallet.v1.WalletService.PurchaseVip:output_type -> hyapp.wallet.v1.PurchaseVipResponse + 105, // 175: hyapp.wallet.v1.WalletService.GrantVip:output_type -> hyapp.wallet.v1.GrantVipResponse + 108, // 176: hyapp.wallet.v1.WalletService.ListAdminVipLevels:output_type -> hyapp.wallet.v1.ListAdminVipLevelsResponse + 110, // 177: hyapp.wallet.v1.WalletService.UpdateAdminVipLevels:output_type -> hyapp.wallet.v1.UpdateAdminVipLevelsResponse + 112, // 178: hyapp.wallet.v1.WalletService.CreditTaskReward:output_type -> hyapp.wallet.v1.CreditTaskRewardResponse + 114, // 179: hyapp.wallet.v1.WalletService.CreditLuckyGiftReward:output_type -> hyapp.wallet.v1.CreditLuckyGiftRewardResponse + 116, // 180: hyapp.wallet.v1.WalletService.ApplyGameCoinChange:output_type -> hyapp.wallet.v1.ApplyGameCoinChangeResponse + 121, // 181: hyapp.wallet.v1.WalletService.GetRedPacketConfig:output_type -> hyapp.wallet.v1.GetRedPacketConfigResponse + 123, // 182: hyapp.wallet.v1.WalletService.UpdateRedPacketConfig:output_type -> hyapp.wallet.v1.UpdateRedPacketConfigResponse + 125, // 183: hyapp.wallet.v1.WalletService.CreateRedPacket:output_type -> hyapp.wallet.v1.CreateRedPacketResponse + 127, // 184: hyapp.wallet.v1.WalletService.ClaimRedPacket:output_type -> hyapp.wallet.v1.ClaimRedPacketResponse + 129, // 185: hyapp.wallet.v1.WalletService.ListRedPackets:output_type -> hyapp.wallet.v1.ListRedPacketsResponse + 131, // 186: hyapp.wallet.v1.WalletService.GetRedPacket:output_type -> hyapp.wallet.v1.GetRedPacketResponse + 133, // 187: hyapp.wallet.v1.WalletService.ExpireRedPackets:output_type -> hyapp.wallet.v1.ExpireRedPacketsResponse + 135, // 188: hyapp.wallet.v1.WalletService.RetryRedPacketRefund:output_type -> hyapp.wallet.v1.RetryRedPacketRefundResponse + 127, // [127:189] is the sub-list for method output_type + 65, // [65:127] is the sub-list for method input_type + 65, // [65:65] is the sub-list for extension type_name + 65, // [65:65] is the sub-list for extension extendee + 0, // [0:65] is the sub-list for field type_name } func init() { file_proto_wallet_v1_wallet_proto_init() } @@ -14262,7 +13977,7 @@ func file_proto_wallet_v1_wallet_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_proto_wallet_v1_wallet_proto_rawDesc), len(file_proto_wallet_v1_wallet_proto_rawDesc)), NumEnums: 0, - NumMessages: 141, + NumMessages: 138, NumExtensions: 0, NumServices: 2, }, diff --git a/api/proto/wallet/v1/wallet.proto b/api/proto/wallet/v1/wallet.proto index 662bd61d..1d1b83a2 100644 --- a/api/proto/wallet/v1/wallet.proto +++ b/api/proto/wallet/v1/wallet.proto @@ -734,7 +734,6 @@ message ListRechargeBillsResponse { message WalletFeatureFlags { bool recharge_enabled = 1; bool diamond_exchange_enabled = 2; - bool withdraw_enabled = 3; } message GetWalletOverviewRequest { @@ -976,32 +975,6 @@ message ListWalletTransactionsResponse { int64 total = 2; } -message WithdrawalRequest { - string withdrawal_id = 1; - int64 user_id = 2; - string asset_type = 3; - int64 amount = 4; - string status = 5; - string payout_account = 6; - string reason = 7; - int64 created_at_ms = 8; - int64 updated_at_ms = 9; -} - -message ApplyWithdrawalRequest { - string command_id = 1; - string app_code = 2; - int64 user_id = 3; - int64 amount = 4; - string payout_account = 5; - string reason = 6; -} - -message ApplyWithdrawalResponse { - WithdrawalRequest withdrawal = 1; - AssetBalance balance = 2; -} - message VipRewardItem { int64 resource_id = 1; string resource_code = 2; @@ -1437,7 +1410,6 @@ service WalletService { rpc DeleteRechargeProduct(DeleteRechargeProductRequest) returns (DeleteRechargeProductResponse); rpc GetDiamondExchangeConfig(GetDiamondExchangeConfigRequest) returns (GetDiamondExchangeConfigResponse); rpc ListWalletTransactions(ListWalletTransactionsRequest) returns (ListWalletTransactionsResponse); - rpc ApplyWithdrawal(ApplyWithdrawalRequest) returns (ApplyWithdrawalResponse); rpc ListVipPackages(ListVipPackagesRequest) returns (ListVipPackagesResponse); rpc GetMyVip(GetMyVipRequest) returns (GetMyVipResponse); rpc PurchaseVip(PurchaseVipRequest) returns (PurchaseVipResponse); diff --git a/api/proto/wallet/v1/wallet_grpc.pb.go b/api/proto/wallet/v1/wallet_grpc.pb.go index 97346b9c..ffcca4dc 100644 --- a/api/proto/wallet/v1/wallet_grpc.pb.go +++ b/api/proto/wallet/v1/wallet_grpc.pb.go @@ -243,7 +243,6 @@ const ( WalletService_DeleteRechargeProduct_FullMethodName = "/hyapp.wallet.v1.WalletService/DeleteRechargeProduct" WalletService_GetDiamondExchangeConfig_FullMethodName = "/hyapp.wallet.v1.WalletService/GetDiamondExchangeConfig" WalletService_ListWalletTransactions_FullMethodName = "/hyapp.wallet.v1.WalletService/ListWalletTransactions" - WalletService_ApplyWithdrawal_FullMethodName = "/hyapp.wallet.v1.WalletService/ApplyWithdrawal" WalletService_ListVipPackages_FullMethodName = "/hyapp.wallet.v1.WalletService/ListVipPackages" WalletService_GetMyVip_FullMethodName = "/hyapp.wallet.v1.WalletService/GetMyVip" WalletService_PurchaseVip_FullMethodName = "/hyapp.wallet.v1.WalletService/PurchaseVip" @@ -311,7 +310,6 @@ type WalletServiceClient interface { DeleteRechargeProduct(ctx context.Context, in *DeleteRechargeProductRequest, opts ...grpc.CallOption) (*DeleteRechargeProductResponse, error) GetDiamondExchangeConfig(ctx context.Context, in *GetDiamondExchangeConfigRequest, opts ...grpc.CallOption) (*GetDiamondExchangeConfigResponse, error) ListWalletTransactions(ctx context.Context, in *ListWalletTransactionsRequest, opts ...grpc.CallOption) (*ListWalletTransactionsResponse, error) - ApplyWithdrawal(ctx context.Context, in *ApplyWithdrawalRequest, opts ...grpc.CallOption) (*ApplyWithdrawalResponse, error) ListVipPackages(ctx context.Context, in *ListVipPackagesRequest, opts ...grpc.CallOption) (*ListVipPackagesResponse, error) GetMyVip(ctx context.Context, in *GetMyVipRequest, opts ...grpc.CallOption) (*GetMyVipResponse, error) PurchaseVip(ctx context.Context, in *PurchaseVipRequest, opts ...grpc.CallOption) (*PurchaseVipResponse, error) @@ -759,16 +757,6 @@ func (c *walletServiceClient) ListWalletTransactions(ctx context.Context, in *Li return out, nil } -func (c *walletServiceClient) ApplyWithdrawal(ctx context.Context, in *ApplyWithdrawalRequest, opts ...grpc.CallOption) (*ApplyWithdrawalResponse, error) { - cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) - out := new(ApplyWithdrawalResponse) - err := c.cc.Invoke(ctx, WalletService_ApplyWithdrawal_FullMethodName, in, out, cOpts...) - if err != nil { - return nil, err - } - return out, nil -} - func (c *walletServiceClient) ListVipPackages(ctx context.Context, in *ListVipPackagesRequest, opts ...grpc.CallOption) (*ListVipPackagesResponse, error) { cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...) out := new(ListVipPackagesResponse) @@ -987,7 +975,6 @@ type WalletServiceServer interface { DeleteRechargeProduct(context.Context, *DeleteRechargeProductRequest) (*DeleteRechargeProductResponse, error) GetDiamondExchangeConfig(context.Context, *GetDiamondExchangeConfigRequest) (*GetDiamondExchangeConfigResponse, error) ListWalletTransactions(context.Context, *ListWalletTransactionsRequest) (*ListWalletTransactionsResponse, error) - ApplyWithdrawal(context.Context, *ApplyWithdrawalRequest) (*ApplyWithdrawalResponse, error) ListVipPackages(context.Context, *ListVipPackagesRequest) (*ListVipPackagesResponse, error) GetMyVip(context.Context, *GetMyVipRequest) (*GetMyVipResponse, error) PurchaseVip(context.Context, *PurchaseVipRequest) (*PurchaseVipResponse, error) @@ -1141,9 +1128,6 @@ func (UnimplementedWalletServiceServer) GetDiamondExchangeConfig(context.Context func (UnimplementedWalletServiceServer) ListWalletTransactions(context.Context, *ListWalletTransactionsRequest) (*ListWalletTransactionsResponse, error) { return nil, status.Error(codes.Unimplemented, "method ListWalletTransactions not implemented") } -func (UnimplementedWalletServiceServer) ApplyWithdrawal(context.Context, *ApplyWithdrawalRequest) (*ApplyWithdrawalResponse, error) { - return nil, status.Error(codes.Unimplemented, "method ApplyWithdrawal not implemented") -} func (UnimplementedWalletServiceServer) ListVipPackages(context.Context, *ListVipPackagesRequest) (*ListVipPackagesResponse, error) { return nil, status.Error(codes.Unimplemented, "method ListVipPackages not implemented") } @@ -1972,24 +1956,6 @@ func _WalletService_ListWalletTransactions_Handler(srv interface{}, ctx context. return interceptor(ctx, in, info, handler) } -func _WalletService_ApplyWithdrawal_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(ApplyWithdrawalRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(WalletServiceServer).ApplyWithdrawal(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: WalletService_ApplyWithdrawal_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(WalletServiceServer).ApplyWithdrawal(ctx, req.(*ApplyWithdrawalRequest)) - } - return interceptor(ctx, in, info, handler) -} - func _WalletService_ListVipPackages_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ListVipPackagesRequest) if err := dec(in); err != nil { @@ -2471,10 +2437,6 @@ var WalletService_ServiceDesc = grpc.ServiceDesc{ MethodName: "ListWalletTransactions", Handler: _WalletService_ListWalletTransactions_Handler, }, - { - MethodName: "ApplyWithdrawal", - Handler: _WalletService_ApplyWithdrawal_Handler, - }, { MethodName: "ListVipPackages", Handler: _WalletService_ListVipPackages_Handler, diff --git a/docs/flutter对接/Flutter App 通知与钱包余额对接.md b/docs/flutter对接/Flutter App 通知与钱包余额对接.md index 4b1fe947..d0eeb65f 100644 --- a/docs/flutter对接/Flutter App 通知与钱包余额对接.md +++ b/docs/flutter对接/Flutter App 通知与钱包余额对接.md @@ -138,7 +138,7 @@ GET /api/v1/wallet/me/balances 示例: ```text -GET /api/v1/wallet/me/balances?asset_type=COIN&asset_type=DIAMOND&asset_type=USD_BALANCE +GET /api/v1/wallet/me/balances?asset_type=COIN&asset_type=DIAMOND&asset_type=HOST_SALARY_USD&asset_type=AGENCY_SALARY_USD&asset_type=BD_SALARY_USD&asset_type=ADMIN_SALARY_USD ``` ### 返回值 `data` @@ -158,7 +158,7 @@ GET /api/v1/wallet/me/balances?asset_type=COIN&asset_type=DIAMOND&asset_type=USD | 字段 | 类型 | 说明 | | ------------------ | ------ | ------------------------------------------------- | -| `asset_type` | string | `COIN` / `DIAMOND` / `USD_BALANCE` / `GIFT_POINT` | +| `asset_type` | string | `COIN` / `DIAMOND` / `HOST_SALARY_USD` / `AGENCY_SALARY_USD` / `BD_SALARY_USD` / `ADMIN_SALARY_USD` / `GIFT_POINT` | | `available_amount` | int64 | 可用余额 | | `frozen_amount` | int64 | 冻结余额 | | `version` | int64 | 该资产余额版本,用于和 IM 通知去重/防乱序 | @@ -201,7 +201,7 @@ GET /api/v1/wallet/me/overview "version": 4 }, { - "asset_type": "USD_BALANCE", + "asset_type": "HOST_SALARY_USD", "available_amount": 1500, "frozen_amount": 0, "version": 2 @@ -209,8 +209,7 @@ GET /api/v1/wallet/me/overview ], "feature_flags": { "recharge_enabled": true, - "diamond_exchange_enabled": true, - "withdraw_enabled": true + "diamond_exchange_enabled": true } } ``` @@ -220,7 +219,6 @@ GET /api/v1/wallet/me/overview | `balances` | array | 钱包首页需要展示的资产余额 | | `feature_flags.recharge_enabled` | bool | 是否允许充值 | | `feature_flags.diamond_exchange_enabled` | bool | 是否允许钻石兑换 | -| `feature_flags.withdraw_enabled` | bool | 是否允许提现 | ### 可能错误 diff --git a/docs/主播公会BD后台架构.md b/docs/主播公会BD后台架构.md index 9b2d9ea9..b3fa03d8 100644 --- a/docs/主播公会BD后台架构.md +++ b/docs/主播公会BD后台架构.md @@ -2,7 +2,7 @@ 本文只定义后台/Admin 侧实现:政策配置、工资周期、工资单、审核、钱包入账、调整单、后台审计和运营干预。App 侧的主播申请、Agency 成员、BD 邀请和用户可见查询见 [Host Agency BD App Architecture](./主播公会BD架构.md)。 -这里的工资统一指发放到主播侧 `USD_BALANCE` 的业务奖励。提现审核和人工打款仍由 `wallet-service` 拥有,Admin 只负责把审核通过的工资单入账到工资余额,不直接处理线下打款。 +这里的工资统一指发放到主播侧 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` 的业务奖励。提现审核和人工打款仍由 `wallet-service` 拥有,Admin 只负责把审核通过的工资单入账到工资余额,不直接处理线下打款。 本文不新增独立 `host-service` 微服务。host、Agency、BD、政策和工资后台能力属于 user-services,代码落在当前仓库的 `services/user-service` host domain。 @@ -11,7 +11,7 @@ - 后台可以配置 host、agency、bd 三类工资政策,并按区域生效。 - 后台可以选择日结、周结、半月结、月结,不把结算周期写死在代码里。 - 后台可以生成工资周期,查看每个 host/Agency/BD/BD Leader 的明细来源。 -- 后台审批后,`user-service` host domain 以幂等方式调用 `wallet-service` 给 `USD_BALANCE` 入账。 +- 后台审批后,`user-service` host domain 以幂等方式调用 `wallet-service` 给 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` 入账。 - 后台可以对迟到事件、人工修正、争议处理创建调整单,不能直接修改已入账工资项。 - 后台可以创建或停用 BD Leader、BD、Agency,也可以关闭 Agency;后台可以查看和新增币商 `coin_seller`;所有动作必须有审计记录。 @@ -49,7 +49,7 @@ graph LR | `hyapp-admin-server` | Admin HTTP 入口、后台鉴权、request envelope、后台操作审计;使用独立 `hyapp_admin` 库 | | `user-service` | 用户、区域、账号状态查询;host/Agency/BD/coin_seller 政策、周期、工资单、关系管理、统计聚合、幂等结果、领域 outbox;App/客户端不能提交区域,后台关系命令的 `region_id` 只能来自 `hyapp-admin-server` 鉴权审计入口 | | `room-service` | 只产出上麦和礼物事件,不接收后台工资命令 | -| `wallet-service` | `COIN`、`COIN_SELLER_COIN`、`USD_BALANCE` 入账、提现冻结、提现审核状态和钱包流水 | +| `wallet-service` | `COIN`、`COIN_SELLER_COIN`、`HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` 入账、提现冻结、提现审核状态和钱包流水 | ## Admin Permission Model @@ -188,7 +188,7 @@ flowchart LR E --> F F --> G["approve"] G --> H["wallet CreditSalaryBalance"] - H --> I["USD_BALANCE"] + H --> I["identity salary wallet"] ``` ```sql @@ -353,7 +353,7 @@ Leader 直接拥有 Agency 下线时,推荐快照同时设置 `bd_user_id = le 1. Admin 审批 cycle。 2. `user-service` host domain 查询所有 `approved` salary items。 3. 对每个 item 调用 `wallet-service CreditSalaryBalance`,幂等键为 `salary:{salary_item_id}`。 -4. `wallet-service` credit `USD_BALANCE` 并返回 `wallet_transaction_id`。 +4. `wallet-service` credit `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` 并返回 `wallet_transaction_id`。 5. `user-service` host domain 保存 `wallet_transaction_id`,把 item 标记为 `posted`。 6. 如果中途失败,只重试未 posted item,幂等键保持不变。 @@ -488,7 +488,7 @@ Outbox consumers can update App message inbox, BI, risk systems, and export jobs | Host changes Agency during cycle | Salary uses `host_daily_stats` relation snapshot and can split across agencies | | Late room event after posted cycle | Create adjustment item; do not mutate posted salary item | | Wallet posting partially fails | Retry unposted items with same idempotency key | -| Admin accidentally posts twice | Wallet idempotency must prevent duplicate `USD_BALANCE` credit | +| Admin accidentally posts twice | Wallet idempotency must prevent duplicate `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` credit | | Agency closed mid-cycle | Work before close remains attributable; future App joins/search stop immediately | | User region changed | Existing cycle uses event snapshots; new policy/cycle matching follows stats region | | Negative adjustment exceeds balance | Move to manual handling; do not force wallet negative unless wallet explicitly supports debt | @@ -507,7 +507,7 @@ Outbox consumers can update App message inbox, BI, risk systems, and export jobs | Agency salary generated | Base uses host salary items under that Agency only | | BD Leader owns direct Agency | Source host salary counted once for the leader | | BD under Leader owns Agency | Host salary contributes to BD and leader according to snapshot | -| Cycle posted twice | Wallet idempotency prevents duplicate `USD_BALANCE` credit | +| Cycle posted twice | Wallet idempotency prevents duplicate `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` credit | | Posting fails after partial success | Retry posts only unposted items | | Posted item needs correction | Adjustment item created; original item remains immutable | | Admin closes Agency | Agency hidden from App search; existing facts remain auditable | @@ -515,7 +515,7 @@ Outbox consumers can update App message inbox, BI, risk systems, and export jobs ## Critical Rules - Admin owns policies and salary cycles; App owns user-initiated relationship flows. -- Wallet is the only owner of `USD_BALANCE` and withdrawal state. +- Wallet is the only owner of `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` and withdrawal state. - Posted salary items are immutable. - BD/BD Leader base is downstream host salary only. - Leader direct Agency salary source must be de-duplicated. diff --git a/docs/主播公会BD实施顺序.md b/docs/主播公会BD实施顺序.md index 80ce03d8..0881713b 100644 --- a/docs/主播公会BD实施顺序.md +++ b/docs/主播公会BD实施顺序.md @@ -142,7 +142,7 @@ - Agency salary:基于下属 host salary item 或明确配置的 agency 指标。 - BD/BD Leader salary:基于 downstream host salary sum,且按 source host salary item 去重。 - 后台审核工资周期。 -- 调用 `wallet-service` 给 `USD_BALANCE` 入账,幂等键为 `salary:{salary_item_id}`。 +- 调用 `wallet-service` 给 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` 入账,幂等键为 `salary:{salary_item_id}`。 - 支持调整单:迟到事件、人工修正、争议处理都走补差或冲正。 - Salary posted 和 adjustment posted 事件接入 App message inbox,通知接收人查看收益明细;通知失败不影响钱包入账事实。 @@ -182,7 +182,7 @@ | M3 | Phase 3 | 用户申请、审核、踢出、重新申请、邀请链路完整跑通 | | M3.5 | Phase 3.5 | 申请、邀请、后台创建关系结果能进入 App 系统消息 | | M4 | Phase 4 | 有效上麦和礼物统计按关系快照落库 | -| M5 | Phase 5 | 后台生成工资单,审批后入账 `USD_BALANCE` | +| M5 | Phase 5 | 后台生成工资单,审批后入账 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` | | M6 | Phase 6 | 失败补偿、导出、重建和监控可用 | ## Stop Conditions @@ -191,7 +191,7 @@ - Phase 2 没有完成前,不做 App Agency 搜索上线,因为没有可信组织种子数据。 - Phase 3 没有完成前,不做工资发放,因为 host/Agency/BD 归属还不稳定。 - Phase 4 没有完成前,不做真实工资入账,因为缺少可审计统计输入。 -- Phase 5 没有完成审批和幂等 posting 前,不允许写 `USD_BALANCE`。 +- Phase 5 没有完成审批和幂等 posting 前,不允许写 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`。 ## Verification Commands diff --git a/docs/主播公会BD架构.md b/docs/主播公会BD架构.md index a8f01cb8..146e7735 100644 --- a/docs/主播公会BD架构.md +++ b/docs/主播公会BD架构.md @@ -16,7 +16,7 @@ - BD 默认不是主播;BD 可以加入别的 Agency 成为主播,也可以在未成为主播时邀请自己成为自己的 Agency。 - `coin_seller` 是独立币商身份,可以和 Agency、BD、BD Leader 身份并存;币商拥有专用金币账户,可以给玩家转普通金币。 - App 侧可以展示 host 统计、Agency 成员、申请、邀请和后台已经生成的收益结果。 -- App 侧不能创建政策、计算工资周期、审核工资单或直接给 `USD_BALANCE` 入账。 +- App 侧不能创建政策、计算工资周期、审核工资单或直接给 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` 入账。 ## Non-Goals @@ -67,7 +67,7 @@ graph LR | `gateway-service` | HTTP 入口、鉴权、request envelope、调用内部 gRPC | | `user-service` | 用户主数据、国家、区域、账号状态;host 身份、Agency、BD、coin_seller 层级、申请邀请、关系快照、App 查询读模型 | | `room-service` | 房间事件:上麦、确认发流、下麦、送礼、离房 | -| `wallet-service` | `COIN`、`COIN_SELLER_COIN`、`USD_BALANCE`、收益余额、提现冻结/审核/出账 | +| `wallet-service` | `COIN`、`COIN_SELLER_COIN`、`HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`、收益余额、提现冻结/审核/出账 | `user-service` host domain 读取 `room-service` 和 `wallet-service` 事件,但不反向修改房间状态。App 查询只读取当前身份、关系、申请、邀请、统计和后台已生成的收益结果;结算写入链路见 Admin 文档。 diff --git a/docs/币商库存授信架构.md b/docs/币商库存授信架构.md index ae45f19b..4f8be6d1 100644 --- a/docs/币商库存授信架构.md +++ b/docs/币商库存授信架构.md @@ -14,7 +14,7 @@ - `USDT进货`:平台收到币商线下 USDT 后,后台给币商发放 `COIN_SELLER_COIN` 库存;这笔记录计入币商进货/充值统计。 - `金币补偿`:平台因为异常、活动、人工修正等原因给币商补库存;没有充值金额,不计入币商进货/充值统计。 -- 两种类型都不能给币商发放 `USD_BALANCE`,也不能直接影响玩家普通 `COIN`。 +- 两种类型都不能给币商发放 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`,也不能直接影响玩家普通 `COIN`。 ## 服务边界 diff --git a/docs/我的页概览接口.md b/docs/我的页概览接口.md index 25f4def5..643f6dd2 100644 --- a/docs/我的页概览接口.md +++ b/docs/我的页概览接口.md @@ -134,8 +134,8 @@ Authorization: Bearer | --- | --- | --- | | 消息 tab、系统消息、活动消息 | 我的页设计稿不展示消息红点 | 消息 tab 页面接口 | | 邀请码入口和邀请统计 | 截图首屏没有邀请码入口 | 邀请页或活动入口 | -| `wallet.recharge_enabled` / `withdraw_enabled` / `diamond_exchange_enabled` | 首屏卡片不需要操作开关 | `GET /api/v1/wallet/me/overview` | -| `DIAMOND` / `USD_BALANCE` | 首屏钱包卡片只展示金币 | 钱包二级页余额接口 | +| `wallet.recharge_enabled` / `diamond_exchange_enabled` | 首屏卡片不需要操作开关 | `GET /api/v1/wallet/me/overview` | +| `DIAMOND` / `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` | 首屏钱包卡片只展示金币 | 钱包二级页余额接口 | | 邀请用户列表、钱包流水、工资明细、团队成员、背包完整列表、任务列表 | 都需要分页或聚合 | 对应二级页接口 | ## Performance Budget @@ -180,7 +180,6 @@ sequenceDiagram | `GET /api/v1/wallet/me/overview` | 钱包二级页余额和操作开关 | | `GET /api/v1/wallet/recharge/products` | 当前区域充值渠道和档位 | | `GET /api/v1/wallet/diamond-exchange/config` | 钻石兑换金币/余额配置 | -| `POST /api/v1/wallet/withdrawals/apply` | 创建待审核提现申请并冻结 `USD_BALANCE` | | `GET /api/v1/wallet/transactions` | 钱包流水分页 | | `GET /api/v1/vip/me` | 当前 VIP 状态 | | `GET /api/v1/vip/packages` | 可购买 VIP 包 | diff --git a/docs/接口清单.md b/docs/接口清单.md index 1850992b..e581dd27 100644 --- a/docs/接口清单.md +++ b/docs/接口清单.md @@ -99,7 +99,6 @@ | GET | `/api/v1/wallet/me/balances` | wallet | `getMyBalances` | 查询当前用户钱包余额 | | GET | `/api/v1/wallet/recharge/products` | wallet | `listRechargeProducts` | 查询充值商品和渠道 | | GET | `/api/v1/wallet/diamond-exchange/config` | wallet | `getDiamondExchangeConfig` | 查询钻石兑换配置 | -| POST | `/api/v1/wallet/withdrawals/apply` | wallet | `applyWithdrawal` | 提交美元余额提现申请 | | GET | `/api/v1/wallet/coin-transactions` | wallet | `listCoinTransactions` | 分页查询当前用户金币流水 | | GET | `/api/v1/wallet/transactions` | wallet | `listWalletTransactions` | 分页查询钱包流水 | | POST | `/api/v1/wallet/coin-seller/transfer` | wallet | `transferCoinFromSeller` | 币商给玩家转金币 | diff --git a/docs/钱包服务架构.md b/docs/钱包服务架构.md index 52a39796..e284f1e7 100644 --- a/docs/钱包服务架构.md +++ b/docs/钱包服务架构.md @@ -21,9 +21,9 @@ | `COIN_SELLER_COIN` | 币商专用金币库存,只能转给玩家形成普通 `COIN` | yes, seller transfer only | no | wallet-service | | `DIAMOND` | 钻石,不可直接消费,只能按政策兑换金币或美元余额 | no | no | wallet-service | | `GIFT_POINT` | 主播礼物积分,达到政策后结算美元奖励 | no | no | wallet-service | -| `USD_BALANCE` | 主播可提现美元余额,建议单位为 cent 或 micro cent | no | yes | wallet-service | +| `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` | 主播可提现美元余额,建议单位为 cent 或 micro cent | no | yes | wallet-service | -钻石和积分都不是直接消费资产。钻石兑换金币或美元余额时必须落兑换订单,记录政策版本、汇率和结果。主播积分达到政策后,由结算任务发起美元余额奖励入账,用户提现只能提现 `USD_BALANCE`。 +钻石和积分都不是直接消费资产。钻石兑换金币或美元余额时必须落兑换订单,记录政策版本、汇率和结果。主播积分达到政策后,由结算任务发起美元余额奖励入账,用户提现只能提现 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`。 资源组可以通过资源域的 `wallet_asset` 组成员直接给用户发放 `COIN` 或 `DIAMOND`,但这仍然是钱包入账流水,不写用户资源权益;钻石后续兑换仍必须走独立兑换订单。 @@ -40,7 +40,7 @@ | 充值 | `PARTIAL` | 币商转账已写 `wallet_recharge_records`,provider order 未实现 | Apple、Google、线下订单和 provider 校验仍需补齐 | | 币商转金币 | `DONE` | `TransferCoinFromSeller` 扣 `COIN_SELLER_COIN`、加玩家 `COIN`,并按区域充值政策记录美元充值金额 | 限额、线下订单和风控审计仍需补齐 | | 钻石兑换 | `TODO` | 无 diamond exchange order | 需要政策快照、兑换状态机和原子出入账 | -| 主播积分/奖励 | `PARTIAL` | 送礼实时给收礼人加 `GIFT_POINT` | 周期结算任务和 `USD_BALANCE` 奖励入账未落地 | +| 主播积分/奖励 | `PARTIAL` | 送礼实时给收礼人加 `GIFT_POINT` | 周期结算任务和 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` 奖励入账未落地 | | 提现 | `TODO` | 无 withdraw request | 需要冻结、审核、人工打款、失败回滚 | | 钱包 outbox | `PARTIAL` | `wallet_outbox` 已和交易同事务写入 `WalletBalanceChanged/WalletGiftDebited/WalletCoinSellerTransferred/WalletRechargeRecorded` | outbox worker 和 MQ 投递适配未落地 | @@ -83,8 +83,8 @@ ### P4: Anchor Reward And Withdraw - 送礼实时加主播 `GIFT_POINT`,但美元奖励由结算任务按政策转换,不能写死在送礼链路。 -- 奖励结算生成 `anchor_reward_settlements`,确认后加主播 `USD_BALANCE`。 -- 提现申请必须先冻结 `USD_BALANCE`,审核拒绝解冻,审核通过后进入人工打款流程。 +- 奖励结算生成 `anchor_reward_settlements`,确认后加主播 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`。 +- 提现申请必须先冻结 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`,审核拒绝解冻,审核通过后进入人工打款流程。 - 人工打款完成后从冻结余额出账;打款失败回到可重试状态,不能自动解冻后丢失审核上下文。 ## Component Diagram @@ -239,7 +239,7 @@ wallet_recharge_records( ); ``` -`wallet_recharge_records.usd_minor_amount` 是用户充值额的权威统计口径;用户不会因此获得 `USD_BALANCE`。政策字段必须保存快照,后续修改区域汇率不能重算历史充值。 +`wallet_recharge_records.usd_minor_amount` 是用户充值额的权威统计口径;用户不会因此获得 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`。政策字段必须保存快照,后续修改区域汇率不能重算历史充值。 ## Send Gift Flow @@ -321,7 +321,7 @@ stateDiagram-v2 flowchart LR A["User DIAMOND account"] -->|"debit diamonds"| X["diamond_exchange_order"] X -->|"policy: diamond to coin"| C["User COIN account"] - X -->|"policy: diamond to USD"| U["User USD_BALANCE account"] + X -->|"policy: diamond to USD"| U["User identity salary wallet account"] ``` 钻石兑换必须冻结政策版本。订单里至少记录 `from_diamond_amount`、`to_asset_type`、`to_amount`、`policy_id`、`rate_snapshot` 和 `status`。兑换成功后写分录和 outbox;兑换失败不能出现钻石扣了但目标资产没到账。 @@ -332,8 +332,8 @@ flowchart LR 1. 送礼时钱包给主播增加 `GIFT_POINT`。 2. 结算任务读取积分和政策,生成 `anchor_reward_settlements`。 -3. 结算单确认后调用钱包 `CreditRewardBalance`,增加主播 `USD_BALANCE`。 -4. 主播提现时先冻结 `USD_BALANCE`,审核拒绝解冻,审核通过后等待人工转账。 +3. 结算单确认后调用钱包 `CreditRewardBalance`,增加主播 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`。 +4. 主播提现时先冻结 `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD`,审核拒绝解冻,审核通过后等待人工转账。 5. 人工转账完成后把冻结余额出账,状态改为 `paid`。 提现状态机: @@ -499,7 +499,7 @@ stateDiagram-v2 提现: -- 提现申请成功后 `USD_BALANCE.available_amount` 减少,`frozen_amount` 增加。 +- 提现申请成功后 `identity salary wallet.available_amount` 减少,`frozen_amount` 增加。 - 审核拒绝后冻结金额回到 available。 - 打款完成后 frozen 减少并写出账分录。 - 打款失败后状态可重试,不丢失冻结关系和审核上下文。 @@ -533,7 +533,7 @@ docker compose config - 幂等键必须覆盖业务语义,同一个 command_id 带不同 payload 必须返回冲突。 - Apple/Google 充值以 provider 真实交易号为最终幂等源,不能只信客户端 request id。 - 币商充值分两段:平台给币商发 `COIN_SELLER_COIN` 库存,币商再把库存转成用户 `COIN`;必须有币商金币余额、充值政策快照、限额和审计。 -- `USD_BALANCE` 是可提现负债,调账和奖励发放需要更高权限和审计。 +- `HOST_SALARY_USD`, `AGENCY_SALARY_USD`, `BD_SALARY_USD`, `ADMIN_SALARY_USD` 是可提现负债,调账和奖励发放需要更高权限和审计。 - 兑换汇率和奖励政策必须记录快照,不能只存当前 policy id。 - 提现人工打款前必须冻结余额,打款失败要回到可重新处理状态。 - 钱包事件投递使用 outbox,MQ 投递失败不回滚账务事实。 diff --git a/scripts/mysql/034_remove_usd_balance_withdrawal_requests.sql b/scripts/mysql/034_remove_usd_balance_withdrawal_requests.sql new file mode 100644 index 00000000..cec71604 --- /dev/null +++ b/scripts/mysql/034_remove_usd_balance_withdrawal_requests.sql @@ -0,0 +1,55 @@ +-- Remove the obsolete generic USD withdrawal request table from the wallet database. +-- Salary settlement now writes role-specific wallets only: +-- HOST_SALARY_USD, AGENCY_SALARY_USD, BD_SALARY_USD, ADMIN_SALARY_USD. +-- Keep an archive copy before dropping the source table so production history is not lost. + +SET @source_exists := ( + SELECT COUNT(*) + FROM information_schema.TABLES + WHERE TABLE_SCHEMA = DATABASE() + AND TABLE_NAME = 'wallet_withdrawal_requests' +); + +SET @archive_exists := ( + SELECT COUNT(*) + FROM information_schema.TABLES + WHERE TABLE_SCHEMA = DATABASE() + AND TABLE_NAME = 'wallet_withdrawal_requests_removed_20260602' +); + +SET @sql := IF( + @source_exists = 1 AND @archive_exists = 0, + 'CREATE TABLE wallet_withdrawal_requests_removed_20260602 LIKE wallet_withdrawal_requests', + 'SELECT 1' +); +PREPARE stmt FROM @sql; +EXECUTE stmt; +DEALLOCATE PREPARE stmt; + +SET @sql := IF( + @source_exists = 1, + 'INSERT IGNORE INTO wallet_withdrawal_requests_removed_20260602 SELECT * FROM wallet_withdrawal_requests', + 'SELECT 1' +); +PREPARE stmt FROM @sql; +EXECUTE stmt; +DEALLOCATE PREPARE stmt; + +SET @sql := IF( + @source_exists = 1, + 'DROP TABLE wallet_withdrawal_requests', + 'SELECT 1' +); +PREPARE stmt FROM @sql; +EXECUTE stmt; +DEALLOCATE PREPARE stmt; + +SELECT + SUM(TABLE_NAME = 'wallet_withdrawal_requests') AS source_table_exists, + SUM(TABLE_NAME = 'wallet_withdrawal_requests_removed_20260602') AS archive_table_exists +FROM information_schema.TABLES +WHERE TABLE_SCHEMA = DATABASE() + AND TABLE_NAME IN ( + 'wallet_withdrawal_requests', + 'wallet_withdrawal_requests_removed_20260602' + ); diff --git a/server/admin/internal/modules/teamsalarysettlement/service.go b/server/admin/internal/modules/teamsalarysettlement/service.go index 005a3805..07af8ce9 100644 --- a/server/admin/internal/modules/teamsalarysettlement/service.go +++ b/server/admin/internal/modules/teamsalarysettlement/service.go @@ -23,8 +23,9 @@ const ( policyTypeAdmin = "admin" triggerAutomatic = "automatic" triggerManual = "manual" - // assetUSDBalance 必须与 wallet-service 钱包资产类型保持一致,BD/Admin 工资直接入美元余额账户。 - assetUSDBalance = "USD_BALANCE" + // BD/Admin 工资钱包资产类型必须与 wallet-service ledger 常量保持一致;admin-server 是独立 module,不能直接复用根 module 常量。 + assetBDSalaryUSD = "BD_SALARY_USD" + assetAdminSalaryUSD = "ADMIN_SALARY_USD" bizTypeTeamSettlement = "team_salary_settlement" statusSucceeded = "succeeded" ) @@ -97,6 +98,7 @@ type settlementMetadata struct { LevelNo int `json:"level_no"` IncomeUSDMinor int64 `json:"income_usd_minor"` SalaryUSDMinorDelta int64 `json:"salary_usd_minor_delta"` + SalaryAssetType string `json:"salary_asset_type"` SettledLevelNo int `json:"settled_level_no"` SettledSalaryUSDMinor int64 `json:"settled_salary_usd_minor"` ProcessedAtMS int64 `json:"processed_at_ms"` @@ -490,6 +492,10 @@ func (s *Service) settleCandidate(ctx context.Context, appCode string, operatorA MonthClosedAtMS: nowMS, Version: progress.Version, } + salaryAssetType := teamSalaryAssetType(candidate.PolicyType) + if salaryAssetType == "" { + return recordDTO{}, false, fmt.Errorf("team salary asset type is invalid: %s", candidate.PolicyType) + } metadata := settlementMetadata{ AppCode: appCode, PolicyType: candidate.PolicyType, @@ -502,6 +508,7 @@ func (s *Service) settleCandidate(ctx context.Context, appCode string, operatorA LevelNo: candidate.Level.LevelNo, IncomeUSDMinor: candidate.IncomeUSDMinor, SalaryUSDMinorDelta: salaryDelta, + SalaryAssetType: salaryAssetType, SettledLevelNo: nextProgress.SettledLevelNo, SettledSalaryUSDMinor: nextProgress.SettledSalaryUSDMinor, ProcessedAtMS: nowMS, @@ -513,11 +520,11 @@ func (s *Service) settleCandidate(ctx context.Context, appCode string, operatorA if err := s.insertWalletTransaction(ctx, tx, appCode, transactionID, commandID, metadata, nowMS); err != nil { return recordDTO{}, false, err } - balanceAfter, version, err := s.creditWallet(ctx, tx, appCode, transactionID, candidate.UserID, salaryDelta, nowMS) + balanceAfter, version, err := s.creditWallet(ctx, tx, appCode, transactionID, candidate.UserID, metadata.SalaryAssetType, salaryDelta, nowMS) if err != nil { return recordDTO{}, false, err } - if err := s.insertWalletOutbox(ctx, tx, appCode, transactionID, commandID, candidate.UserID, salaryDelta, balanceAfter, version, metadata, nowMS); err != nil { + if err := s.insertWalletOutbox(ctx, tx, appCode, transactionID, commandID, candidate.UserID, metadata.SalaryAssetType, salaryDelta, balanceAfter, version, metadata, nowMS); err != nil { return recordDTO{}, false, err } if err := s.insertRecord(ctx, tx, appCode, transactionID, commandID, metadata, nowMS); err != nil { @@ -840,12 +847,12 @@ func (s *Service) insertWalletTransaction(ctx context.Context, tx *sql.Tx, appCo return err } -// creditWallet 锁定美元账户并追加 wallet_entries,使余额、流水和版本在同一事务内一致。 -func (s *Service) creditWallet(ctx context.Context, tx *sql.Tx, appCode string, transactionID string, userID int64, amount int64, nowMS int64) (int64, int64, error) { +// creditWallet 锁定对应角色工资钱包并追加 wallet_entries,使余额、流水和版本在同一事务内一致。 +func (s *Service) creditWallet(ctx context.Context, tx *sql.Tx, appCode string, transactionID string, userID int64, assetType string, amount int64, nowMS int64) (int64, int64, error) { if _, err := tx.ExecContext(ctx, ` INSERT IGNORE INTO wallet_accounts ( app_code, user_id, asset_type, available_amount, frozen_amount, version, created_at_ms, updated_at_ms - ) VALUES (?, ?, ?, 0, 0, 1, ?, ?)`, appCode, userID, assetUSDBalance, nowMS, nowMS); err != nil { + ) VALUES (?, ?, ?, 0, 0, 1, ?, ?)`, appCode, userID, assetType, nowMS, nowMS); err != nil { return 0, 0, err } var available int64 @@ -855,7 +862,7 @@ func (s *Service) creditWallet(ctx context.Context, tx *sql.Tx, appCode string, SELECT available_amount, frozen_amount, version FROM wallet_accounts WHERE app_code = ? AND user_id = ? AND asset_type = ? - FOR UPDATE`, appCode, userID, assetUSDBalance, + FOR UPDATE`, appCode, userID, assetType, ).Scan(&available, &frozen, &version); err != nil { return 0, 0, err } @@ -868,7 +875,7 @@ func (s *Service) creditWallet(ctx context.Context, tx *sql.Tx, appCode string, UPDATE wallet_accounts SET available_amount = ?, version = version + 1, updated_at_ms = ? WHERE app_code = ? AND user_id = ? AND asset_type = ? AND version = ?`, - after, nowMS, appCode, userID, assetUSDBalance, version, + after, nowMS, appCode, userID, assetType, version, ); err != nil { return 0, 0, err } @@ -877,7 +884,7 @@ func (s *Service) creditWallet(ctx context.Context, tx *sql.Tx, appCode string, app_code, transaction_id, user_id, asset_type, available_delta, frozen_delta, available_after, frozen_after, counterparty_user_id, room_id, created_at_ms ) VALUES (?, ?, ?, ?, ?, 0, ?, ?, 0, '', ?)`, - appCode, transactionID, userID, assetUSDBalance, amount, after, frozen, nowMS, + appCode, transactionID, userID, assetType, amount, after, frozen, nowMS, ); err != nil { return 0, 0, err } @@ -885,12 +892,12 @@ func (s *Service) creditWallet(ctx context.Context, tx *sql.Tx, appCode string, } // insertWalletOutbox 投递余额变更事件,供后续 MQ/通知链路异步消费。 -func (s *Service) insertWalletOutbox(ctx context.Context, tx *sql.Tx, appCode string, transactionID string, commandID string, userID int64, amount int64, balanceAfter int64, version int64, metadata settlementMetadata, nowMS int64) error { +func (s *Service) insertWalletOutbox(ctx context.Context, tx *sql.Tx, appCode string, transactionID string, commandID string, userID int64, assetType string, amount int64, balanceAfter int64, version int64, metadata settlementMetadata, nowMS int64) error { payload, err := json.Marshal(map[string]any{ "transaction_id": transactionID, "command_id": commandID, "user_id": userID, - "asset_type": assetUSDBalance, + "asset_type": assetType, "available_delta": amount, "available_after": balanceAfter, "version": version, @@ -905,7 +912,7 @@ func (s *Service) insertWalletOutbox(ctx context.Context, tx *sql.Tx, appCode st app_code, event_id, event_type, transaction_id, command_id, user_id, asset_type, available_delta, frozen_delta, payload, status, created_at_ms, updated_at_ms ) VALUES (?, ?, 'WalletBalanceChanged', ?, ?, ?, ?, ?, 0, ?, 'pending', ?, ?)`, - appCode, transactionID+":"+assetUSDBalance, transactionID, commandID, userID, assetUSDBalance, amount, string(payload), nowMS, nowMS, + appCode, transactionID+":"+assetType, transactionID, commandID, userID, assetType, amount, string(payload), nowMS, nowMS, ) return err } @@ -1233,6 +1240,18 @@ func normalizeTriggerMode(value string) string { } } +func teamSalaryAssetType(policyType string) string { + // 用户可以同时拥有 BD/Admin 等多重身份,工资资产必须按本次结算角色拆分,不能混入其它身份钱包。 + switch normalizePolicyType(policyType) { + case policyTypeBD: + return assetBDSalaryUSD + case policyTypeAdmin: + return assetAdminSalaryUSD + default: + return "" + } +} + // normalizeStatus 只允许记录表定义的状态值,避免前端筛选拼接任意 SQL 条件。 func normalizeStatus(value string) string { switch strings.ToLower(strings.TrimSpace(value)) { diff --git a/server/admin/internal/modules/teamsalarysettlement/service_integration_test.go b/server/admin/internal/modules/teamsalarysettlement/service_integration_test.go index 6dfd45ef..98488f07 100644 --- a/server/admin/internal/modules/teamsalarysettlement/service_integration_test.go +++ b/server/admin/internal/modules/teamsalarysettlement/service_integration_test.go @@ -72,8 +72,8 @@ func TestRealMySQLTeamSalaryFullFlow(t *testing.T) { if totalRecords != 2 || len(records) != 2 { t.Fatalf("record count mismatch: total=%d len=%d records=%+v", totalRecords, len(records), records) } - assertWalletBalance(t, walletDB, 4001, 100_000) - assertWalletBalance(t, walletDB, 5001, 20_000) + assertWalletBalance(t, walletDB, 4001, assetBDSalaryUSD, 100_000) + assertWalletBalance(t, walletDB, 5001, assetAdminSalaryUSD, 20_000) assertScalar(t, walletDB, `SELECT COUNT(*) FROM team_salary_settlement_records`, int64(2)) assertScalar(t, walletDB, `SELECT COUNT(*) FROM wallet_transactions WHERE biz_type = 'team_salary_settlement'`, int64(2)) @@ -354,14 +354,14 @@ func execAll(t *testing.T, db *sql.DB, statements ...string) { } } -func assertWalletBalance(t *testing.T, db *sql.DB, userID int64, expected int64) { +func assertWalletBalance(t *testing.T, db *sql.DB, userID int64, assetType string, expected int64) { t.Helper() var amount int64 - if err := db.QueryRow(`SELECT available_amount FROM wallet_accounts WHERE app_code = 'lalu' AND user_id = ? AND asset_type = 'USD_BALANCE'`, userID).Scan(&amount); err != nil { + if err := db.QueryRow(`SELECT available_amount FROM wallet_accounts WHERE app_code = 'lalu' AND user_id = ? AND asset_type = ?`, userID, assetType).Scan(&amount); err != nil { t.Fatalf("query wallet balance failed: %v", err) } if amount != expected { - t.Fatalf("wallet balance mismatch for user %d: got=%d want=%d", userID, amount, expected) + t.Fatalf("wallet balance mismatch for user %d asset %s: got=%d want=%d", userID, assetType, amount, expected) } } diff --git a/services/gateway-service/internal/client/wallet_client.go b/services/gateway-service/internal/client/wallet_client.go index a1a608d8..1176233d 100644 --- a/services/gateway-service/internal/client/wallet_client.go +++ b/services/gateway-service/internal/client/wallet_client.go @@ -18,7 +18,6 @@ type WalletClient interface { ConfirmGooglePayment(ctx context.Context, req *walletv1.ConfirmGooglePaymentRequest) (*walletv1.ConfirmGooglePaymentResponse, error) GetDiamondExchangeConfig(ctx context.Context, req *walletv1.GetDiamondExchangeConfigRequest) (*walletv1.GetDiamondExchangeConfigResponse, error) ListWalletTransactions(ctx context.Context, req *walletv1.ListWalletTransactionsRequest) (*walletv1.ListWalletTransactionsResponse, error) - ApplyWithdrawal(ctx context.Context, req *walletv1.ApplyWithdrawalRequest) (*walletv1.ApplyWithdrawalResponse, error) ListVipPackages(ctx context.Context, req *walletv1.ListVipPackagesRequest) (*walletv1.ListVipPackagesResponse, error) GetMyVip(ctx context.Context, req *walletv1.GetMyVipRequest) (*walletv1.GetMyVipResponse, error) PurchaseVip(ctx context.Context, req *walletv1.PurchaseVipRequest) (*walletv1.PurchaseVipResponse, error) @@ -81,10 +80,6 @@ func (c *grpcWalletClient) ListWalletTransactions(ctx context.Context, req *wall return c.client.ListWalletTransactions(ctx, req) } -func (c *grpcWalletClient) ApplyWithdrawal(ctx context.Context, req *walletv1.ApplyWithdrawalRequest) (*walletv1.ApplyWithdrawalResponse, error) { - return c.client.ApplyWithdrawal(ctx, req) -} - func (c *grpcWalletClient) ListVipPackages(ctx context.Context, req *walletv1.ListVipPackagesRequest) (*walletv1.ListVipPackagesResponse, error) { return c.client.ListVipPackages(ctx, req) } diff --git a/services/gateway-service/internal/transport/http/httproutes/router.go b/services/gateway-service/internal/transport/http/httproutes/router.go index 62629a84..3fc3b3e8 100644 --- a/services/gateway-service/internal/transport/http/httproutes/router.go +++ b/services/gateway-service/internal/transport/http/httproutes/router.go @@ -167,7 +167,6 @@ type WalletHandlers struct { ListRechargeProducts http.HandlerFunc ConfirmGooglePayment http.HandlerFunc GetDiamondExchangeConfig http.HandlerFunc - ApplyWithdrawal http.HandlerFunc ListCoinTransactions http.HandlerFunc ListWalletTransactions http.HandlerFunc ListCoinSellers http.HandlerFunc @@ -396,7 +395,6 @@ func (r routes) registerWalletRoutes() { r.profile("/wallet/recharge/products", http.MethodGet, h.ListRechargeProducts) r.profile("/wallet/payments/google/confirm", http.MethodPost, h.ConfirmGooglePayment) r.profile("/wallet/diamond-exchange/config", http.MethodGet, h.GetDiamondExchangeConfig) - r.profile("/wallet/withdrawals/apply", http.MethodPost, h.ApplyWithdrawal) r.profile("/wallet/coin-transactions", http.MethodGet, h.ListCoinTransactions) r.profile("/wallet/transactions", http.MethodGet, h.ListWalletTransactions) r.profile("/wallet/coin-sellers", http.MethodGet, h.ListCoinSellers) diff --git a/services/gateway-service/internal/transport/http/response_test.go b/services/gateway-service/internal/transport/http/response_test.go index 596b6087..3861ca26 100644 --- a/services/gateway-service/internal/transport/http/response_test.go +++ b/services/gateway-service/internal/transport/http/response_test.go @@ -429,8 +429,6 @@ type fakeWalletClient struct { diamondExchangeResp *walletv1.GetDiamondExchangeConfigResponse lastTransactions *walletv1.ListWalletTransactionsRequest transactionsResp *walletv1.ListWalletTransactionsResponse - lastWithdrawal *walletv1.ApplyWithdrawalRequest - withdrawalResp *walletv1.ApplyWithdrawalResponse lastVipPackages *walletv1.ListVipPackagesRequest vipPackagesResp *walletv1.ListVipPackagesResponse lastMyVip *walletv1.GetMyVipRequest @@ -1147,7 +1145,6 @@ func (f *fakeWalletClient) GetWalletOverview(_ context.Context, req *walletv1.Ge FeatureFlags: &walletv1.WalletFeatureFlags{ RechargeEnabled: true, DiamondExchangeEnabled: true, - WithdrawEnabled: true, }, }, nil } @@ -1230,17 +1227,6 @@ func (f *fakeWalletClient) ListWalletTransactions(_ context.Context, req *wallet return &walletv1.ListWalletTransactionsResponse{}, nil } -func (f *fakeWalletClient) ApplyWithdrawal(_ context.Context, req *walletv1.ApplyWithdrawalRequest) (*walletv1.ApplyWithdrawalResponse, error) { - f.lastWithdrawal = req - if f.err != nil { - return nil, f.err - } - if f.withdrawalResp != nil { - return f.withdrawalResp, nil - } - return &walletv1.ApplyWithdrawalResponse{}, nil -} - func (f *fakeWalletClient) ListVipPackages(_ context.Context, req *walletv1.ListVipPackagesRequest) (*walletv1.ListVipPackagesResponse, error) { f.lastVipPackages = req if f.vipErr != nil { diff --git a/services/gateway-service/internal/transport/http/walletapi/app_wallet_handler.go b/services/gateway-service/internal/transport/http/walletapi/app_wallet_handler.go index e763ca0a..65c80704 100644 --- a/services/gateway-service/internal/transport/http/walletapi/app_wallet_handler.go +++ b/services/gateway-service/internal/transport/http/walletapi/app_wallet_handler.go @@ -47,7 +47,6 @@ type walletOverviewData struct { type walletFeatureFlagsData struct { RechargeEnabled bool `json:"recharge_enabled"` DiamondExchangeEnabled bool `json:"diamond_exchange_enabled"` - WithdrawEnabled bool `json:"withdraw_enabled"` } type walletTransactionData struct { @@ -96,15 +95,6 @@ type giftWallItemData struct { SortOrder int32 `json:"sort_order"` } -type withdrawalApplyRequestBody struct { - CommandID string `json:"command_id"` - CommandIDAlt string `json:"commandId"` - Amount int64 `json:"amount"` - PayoutAccount string `json:"payout_account"` - PayoutAlt string `json:"payoutAccount"` - Reason string `json:"reason"` -} - type googlePaymentConfirmRequestBody struct { CommandID string `json:"command_id"` CommandIDAlt string `json:"commandId"` @@ -134,18 +124,6 @@ type googlePaymentConfirmData struct { ConsumeState string `json:"consume_state"` } -type withdrawalData struct { - WithdrawalID string `json:"withdrawal_id"` - UserID int64 `json:"user_id"` - AssetType string `json:"asset_type"` - Amount int64 `json:"amount"` - Status string `json:"status"` - PayoutAccount string `json:"payout_account"` - Reason string `json:"reason"` - CreatedAtMS int64 `json:"created_at_ms"` - UpdatedAtMS int64 `json:"updated_at_ms"` -} - type vipPurchaseRequestBody struct { CommandID string `json:"command_id"` CommandIDAlt string `json:"commandId"` @@ -387,46 +365,6 @@ func (h *Handler) listWalletTransactionsByAsset(writer http.ResponseWriter, requ httpkit.WriteOK(writer, request, map[string]any{"items": items, "total": resp.GetTotal(), "page": page, "page_size": pageSize}) } -// applyWithdrawal 创建待人工审核的提现申请。 -func (h *Handler) applyWithdrawal(writer http.ResponseWriter, request *http.Request) { - if h.walletClient == nil { - httpkit.WriteError(writer, request, http.StatusBadGateway, httpkit.CodeUpstreamError, "upstream service error") - return - } - var body withdrawalApplyRequestBody - if !httpkit.Decode(writer, request, &body) { - return - } - commandID := strings.TrimSpace(body.CommandID) - if commandID == "" { - commandID = strings.TrimSpace(body.CommandIDAlt) - } - payoutAccount := strings.TrimSpace(body.PayoutAccount) - if payoutAccount == "" { - payoutAccount = strings.TrimSpace(body.PayoutAlt) - } - if commandID == "" || body.Amount <= 0 || payoutAccount == "" { - httpkit.WriteError(writer, request, http.StatusBadRequest, httpkit.CodeInvalidArgument, "invalid argument") - return - } - resp, err := h.walletClient.ApplyWithdrawal(request.Context(), &walletv1.ApplyWithdrawalRequest{ - CommandId: commandID, - AppCode: appcode.FromContext(request.Context()), - UserId: auth.UserIDFromContext(request.Context()), - Amount: body.Amount, - PayoutAccount: payoutAccount, - Reason: strings.TrimSpace(body.Reason), - }) - if err != nil { - httpkit.WriteRPCError(writer, request, err) - return - } - httpkit.WriteOK(writer, request, map[string]any{ - "withdrawal": withdrawalFromProto(resp.GetWithdrawal()), - "balance": balanceFromProto(resp.GetBalance()), - }) -} - func rechargeProductFromProto(product *walletv1.RechargeProduct) rechargeProductData { if product == nil { return rechargeProductData{} @@ -496,7 +434,6 @@ func walletOverviewFromProto(resp *walletv1.GetWalletOverviewResponse) walletOve FeatureFlags: walletFeatureFlagsData{ RechargeEnabled: flags.GetRechargeEnabled(), DiamondExchangeEnabled: flags.GetDiamondExchangeEnabled(), - WithdrawEnabled: flags.GetWithdrawEnabled(), }, } } @@ -566,23 +503,6 @@ func giftWallItemFromProto(item *walletv1.GiftWallItem) giftWallItemData { } } -func withdrawalFromProto(item *walletv1.WithdrawalRequest) withdrawalData { - if item == nil { - return withdrawalData{} - } - return withdrawalData{ - WithdrawalID: item.GetWithdrawalId(), - UserID: item.GetUserId(), - AssetType: item.GetAssetType(), - Amount: item.GetAmount(), - Status: item.GetStatus(), - PayoutAccount: item.GetPayoutAccount(), - Reason: item.GetReason(), - CreatedAtMS: item.GetCreatedAtMs(), - UpdatedAtMS: item.GetUpdatedAtMs(), - } -} - func balanceFromProto(balance *walletv1.AssetBalance) assetBalanceData { if balance == nil { return assetBalanceData{} diff --git a/services/gateway-service/internal/transport/http/walletapi/handler.go b/services/gateway-service/internal/transport/http/walletapi/handler.go index c1be1e32..a83a1caa 100644 --- a/services/gateway-service/internal/transport/http/walletapi/handler.go +++ b/services/gateway-service/internal/transport/http/walletapi/handler.go @@ -48,7 +48,6 @@ func (h *Handler) WalletHandlers() httproutes.WalletHandlers { ListRechargeProducts: h.listRechargeProducts, ConfirmGooglePayment: h.confirmGooglePayment, GetDiamondExchangeConfig: h.getDiamondExchangeConfig, - ApplyWithdrawal: h.applyWithdrawal, ListCoinTransactions: h.listCoinTransactions, ListWalletTransactions: h.listWalletTransactions, ListCoinSellers: h.listCoinSellers, diff --git a/services/wallet-service/deploy/mysql/initdb/001_wallet_service.sql b/services/wallet-service/deploy/mysql/initdb/001_wallet_service.sql index a3b1a777..82eb0ae3 100644 --- a/services/wallet-service/deploy/mysql/initdb/001_wallet_service.sql +++ b/services/wallet-service/deploy/mysql/initdb/001_wallet_service.sql @@ -1046,28 +1046,6 @@ CREATE TABLE IF NOT EXISTS red_packet_user_daily_counters ( PRIMARY KEY (app_code, user_id, send_day) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='红包用户每日发送计数表'; -CREATE TABLE IF NOT EXISTS wallet_withdrawal_requests ( - app_code VARCHAR(32) NOT NULL DEFAULT 'lalu' COMMENT '应用编码,用于多租户隔离', - withdrawal_id VARCHAR(96) NOT NULL COMMENT '提现 ID', - command_id VARCHAR(128) NOT NULL COMMENT '业务命令幂等 ID', - user_id BIGINT NOT NULL COMMENT '用户 ID', - asset_type VARCHAR(32) NOT NULL COMMENT '钱包资产类型', - amount BIGINT NOT NULL COMMENT '金额或数量', - status VARCHAR(32) NOT NULL COMMENT '业务状态', - payout_account VARCHAR(256) NOT NULL COMMENT '出款账户', - reason VARCHAR(512) NOT NULL DEFAULT '' COMMENT '原因', - wallet_transaction_id VARCHAR(96) NOT NULL COMMENT '钱包交易 ID', - reviewed_by_user_id BIGINT NULL COMMENT '审核用户 ID', - review_reason VARCHAR(512) NOT NULL DEFAULT '' COMMENT '审核原因', - reviewed_at_ms BIGINT NULL COMMENT '审核时间,UTC epoch ms', - created_at_ms BIGINT NOT NULL COMMENT '创建时间,UTC epoch ms', - updated_at_ms BIGINT NOT NULL COMMENT '更新时间,UTC epoch ms', - PRIMARY KEY (app_code, withdrawal_id), - UNIQUE KEY uk_withdrawal_command (app_code, command_id), - KEY idx_withdrawal_user_time (app_code, user_id, created_at_ms), - KEY idx_withdrawal_status_time (app_code, status, created_at_ms) -) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='钱包提现申请表'; - CREATE TABLE IF NOT EXISTS vip_levels ( app_code VARCHAR(32) NOT NULL DEFAULT 'lalu' COMMENT '应用编码,用于多租户隔离', level INT NOT NULL COMMENT '等级', diff --git a/services/wallet-service/internal/domain/ledger/ledger.go b/services/wallet-service/internal/domain/ledger/ledger.go index 6af43c6a..05b54dba 100644 --- a/services/wallet-service/internal/domain/ledger/ledger.go +++ b/services/wallet-service/internal/domain/ledger/ledger.go @@ -11,8 +11,14 @@ const ( AssetGiftPoint = "GIFT_POINT" // AssetHostPeriodDiamond 是主播工资周期钻石投影,只参与工资等级结算,不进入通用钱包余额。 AssetHostPeriodDiamond = "HOST_PERIOD_DIAMOND" - // AssetUSDBalance 是主播可提现美元余额,单位由后续提现策略固定。 - AssetUSDBalance = "USD_BALANCE" + // AssetHostSalaryUSD 是主播工资美元钱包,只接收主播工资和月底剩余钻石折美元。 + AssetHostSalaryUSD = "HOST_SALARY_USD" + // AssetAgencySalaryUSD 是代理工资美元钱包,只接收主播结算同时产生的代理工资。 + AssetAgencySalaryUSD = "AGENCY_SALARY_USD" + // AssetBDSalaryUSD 是 BD 工资美元钱包,只接收 BD 政策结算工资。 + AssetBDSalaryUSD = "BD_SALARY_USD" + // AssetAdminSalaryUSD 是 Admin 工资美元钱包,只接收 Admin 政策结算工资。 + AssetAdminSalaryUSD = "ADMIN_SALARY_USD" // StockTypeUSDTPurchase 表示币商线下 USDT 进货后发放专用金币库存。 StockTypeUSDTPurchase = "usdt_purchase" @@ -43,9 +49,6 @@ const ( // GooglePurchaseStatePurchased 是 Google Play 已支付完成状态。 GooglePurchaseStatePurchased = "PURCHASED" - // WithdrawalStatusPending 表示主播美元余额提现已提交,等待后台人工审核和线下转账。 - WithdrawalStatusPending = "pending" - // HostSalarySettlementModeDaily 表示主播工资按日结算等级增量。 HostSalarySettlementModeDaily = "daily" // HostSalarySettlementModeHalfMonth 表示主播工资按半月周期结算等级增量。 @@ -279,7 +282,6 @@ type ListRechargeBillsQuery struct { type WalletFeatureFlags struct { RechargeEnabled bool DiamondExchangeEnabled bool - WithdrawEnabled bool } // WalletOverview 是我的页和钱包首页共同使用的轻量摘要。 @@ -473,29 +475,6 @@ type ListWalletTransactionsQuery struct { PageSize int32 } -// WithdrawalCommand 是主播余额提现申请命令。人工审核和线下转账不在 App 主链路完成。 -type WithdrawalCommand struct { - AppCode string - CommandID string - UserID int64 - Amount int64 - PayoutAccount string - Reason string -} - -// WithdrawalRequest 是提现申请事实。 -type WithdrawalRequest struct { - WithdrawalID string - UserID int64 - AssetType string - Amount int64 - Status string - PayoutAccount string - Reason string - CreatedAtMS int64 - UpdatedAtMS int64 -} - // VipRewardItem 是 VIP 资源组权益的轻量展示投影。 type VipRewardItem struct { ResourceID int64 @@ -786,7 +765,7 @@ type RedPacketExpireResult struct { // ValidAssetType 限定账本允许落账的资产类型,避免写入任意字符串资产。 func ValidAssetType(assetType string) bool { switch assetType { - case AssetCoin, AssetCoinSellerCoin, AssetGiftPoint, AssetUSDBalance: + case AssetCoin, AssetCoinSellerCoin, AssetGiftPoint, AssetHostSalaryUSD, AssetAgencySalaryUSD, AssetBDSalaryUSD, AssetAdminSalaryUSD: return true default: return false diff --git a/services/wallet-service/internal/service/wallet/service.go b/services/wallet-service/internal/service/wallet/service.go index 5309c5d5..03b767d6 100644 --- a/services/wallet-service/internal/service/wallet/service.go +++ b/services/wallet-service/internal/service/wallet/service.go @@ -48,7 +48,6 @@ type Repository interface { DeleteRechargeProduct(ctx context.Context, appCode string, productID int64) error GetDiamondExchangeConfig(ctx context.Context, userID int64) ([]ledger.DiamondExchangeRule, error) ListWalletTransactions(ctx context.Context, query ledger.ListWalletTransactionsQuery) ([]ledger.WalletTransaction, int64, error) - ApplyWithdrawal(ctx context.Context, command ledger.WithdrawalCommand) (ledger.WithdrawalRequest, ledger.AssetBalance, error) ListVipPackages(ctx context.Context, userID int64) (ledger.UserVip, []ledger.VipLevel, error) GetMyVip(ctx context.Context, userID int64) (ledger.UserVip, error) PurchaseVip(ctx context.Context, command ledger.PurchaseVipCommand) (ledger.PurchaseVipReceipt, error) @@ -738,24 +737,6 @@ func (s *Service) ListWalletTransactions(ctx context.Context, query ledger.ListW return s.repository.ListWalletTransactions(ctx, query) } -// ApplyWithdrawal 冻结主播美元余额并创建待人工审核提现申请。 -func (s *Service) ApplyWithdrawal(ctx context.Context, command ledger.WithdrawalCommand) (ledger.WithdrawalRequest, ledger.AssetBalance, error) { - if command.CommandID == "" || command.UserID <= 0 || command.Amount <= 0 { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, xerr.New(xerr.InvalidArgument, "withdrawal command is incomplete") - } - command.PayoutAccount = strings.TrimSpace(command.PayoutAccount) - command.Reason = strings.TrimSpace(command.Reason) - if command.PayoutAccount == "" || len(command.PayoutAccount) > 256 || len(command.Reason) > 512 { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, xerr.New(xerr.InvalidArgument, "withdrawal payout account is invalid") - } - if s.repository == nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, xerr.New(xerr.Unavailable, "wallet repository is not configured") - } - command.AppCode = appcode.Normalize(command.AppCode) - ctx = appcode.WithContext(ctx, command.AppCode) - return s.repository.ApplyWithdrawal(ctx, command) -} - // ListVipPackages 返回可购买 VIP 包和当前会员状态。 func (s *Service) ListVipPackages(ctx context.Context, userID int64) (ledger.UserVip, []ledger.VipLevel, error) { if userID <= 0 { diff --git a/services/wallet-service/internal/service/wallet/service_test.go b/services/wallet-service/internal/service/wallet/service_test.go index 7203fbdd..047de1ae 100644 --- a/services/wallet-service/internal/service/wallet/service_test.go +++ b/services/wallet-service/internal/service/wallet/service_test.go @@ -264,9 +264,9 @@ func TestHostSalarySettlementCreditsIncrementalRewards(t *testing.T) { if result.ProcessedCount != 1 || result.SuccessCount != 1 || result.FailureCount != 0 { t.Fatalf("first settlement result mismatch: %+v", result) } - assertBalance(t, svc, 10002, ledger.AssetUSDBalance, 150) + assertBalance(t, svc, 10002, ledger.AssetHostSalaryUSD, 150) assertBalance(t, svc, 10002, ledger.AssetCoin, 90) - assertBalance(t, svc, 30001, ledger.AssetUSDBalance, 50) + assertBalance(t, svc, 30001, ledger.AssetAgencySalaryUSD, 50) second, err := svc.DebitGift(context.Background(), ledger.DebitGiftCommand{ CommandID: "cmd-salary-gift-2", @@ -301,9 +301,9 @@ func TestHostSalarySettlementCreditsIncrementalRewards(t *testing.T) { if result.ProcessedCount != 1 || result.SuccessCount != 1 || result.FailureCount != 0 { t.Fatalf("second settlement result mismatch: %+v", result) } - assertBalance(t, svc, 10002, ledger.AssetUSDBalance, 300) + assertBalance(t, svc, 10002, ledger.AssetHostSalaryUSD, 300) assertBalance(t, svc, 10002, ledger.AssetCoin, 198) - assertBalance(t, svc, 30001, ledger.AssetUSDBalance, 80) + assertBalance(t, svc, 30001, ledger.AssetAgencySalaryUSD, 80) if got := repository.CountRows("host_salary_settlement_records", "user_id = ? AND cycle_key = ?", int64(10002), first.HostPeriodCycleKey); got != 2 { t.Fatalf("salary settlement records mismatch, got %d", got) } @@ -391,8 +391,8 @@ func TestHostSalaryManualPolicyRequiresManualTrigger(t *testing.T) { if result.ProcessedCount != 1 || result.SuccessCount != 1 { t.Fatalf("manual settlement result mismatch: %+v", result) } - assertBalance(t, svc, 10002, ledger.AssetUSDBalance, 150) - assertBalance(t, svc, 30001, ledger.AssetUSDBalance, 50) + assertBalance(t, svc, 10002, ledger.AssetHostSalaryUSD, 150) + assertBalance(t, svc, 30001, ledger.AssetAgencySalaryUSD, 50) } // TestHostSalaryMonthEndCreditsResidualAndClearsCycle 验证月底结算补发剩余钻石折美元,并逻辑关闭当月周期。 @@ -455,7 +455,7 @@ func TestHostSalaryMonthEndCreditsResidualAndClearsCycle(t *testing.T) { if result.ProcessedCount != 1 || result.SuccessCount != 1 || result.FailureCount != 0 { t.Fatalf("month-end settlement result mismatch: %+v", result) } - assertBalance(t, svc, 10002, ledger.AssetUSDBalance, 400) + assertBalance(t, svc, 10002, ledger.AssetHostSalaryUSD, 400) if got := repository.CountRows("host_salary_settlement_progress", "user_id = ? AND cycle_key = ? AND residual_usd_minor = ? AND month_end_cleared_at_ms > 0", int64(10002), receipt.HostPeriodCycleKey, int64(250)); got != 1 { t.Fatalf("month-end progress should store residual and cleared marker, got %d", got) } @@ -534,9 +534,9 @@ func TestHostSalaryFullLifecycleFromPublishedPolicyToNextCycle(t *testing.T) { if result.ProcessedCount != 1 || result.SuccessCount != 1 || result.FailureCount != 0 { t.Fatalf("level 1 daily settlement result mismatch: %+v", result) } - assertBalance(t, svc, 10002, ledger.AssetUSDBalance, 150) + assertBalance(t, svc, 10002, ledger.AssetHostSalaryUSD, 150) assertBalance(t, svc, 10002, ledger.AssetCoin, 90) - assertBalance(t, svc, 30001, ledger.AssetUSDBalance, 50) + assertBalance(t, svc, 30001, ledger.AssetAgencySalaryUSD, 50) previousIDs := repository.HostSalarySettlementIDs(10002, previousCycle) if len(previousIDs) != 1 || previousIDs[0] == "" { t.Fatalf("level 1 settlement id missing: %v", previousIDs) @@ -598,9 +598,9 @@ func TestHostSalaryFullLifecycleFromPublishedPolicyToNextCycle(t *testing.T) { t.Fatalf("level 2 daily settlement result mismatch: %+v", result) } // 第二次只补发累计 2 级与已发 1 级之间的差额,最终余额等于 2 级累计权益。 - assertBalance(t, svc, 10002, ledger.AssetUSDBalance, 300) + assertBalance(t, svc, 10002, ledger.AssetHostSalaryUSD, 300) assertBalance(t, svc, 10002, ledger.AssetCoin, 198) - assertBalance(t, svc, 30001, ledger.AssetUSDBalance, 80) + assertBalance(t, svc, 30001, ledger.AssetAgencySalaryUSD, 80) previousIDs = repository.HostSalarySettlementIDs(10002, previousCycle) if len(previousIDs) != 2 { t.Fatalf("level 2 settlement should create second record: %v", previousIDs) @@ -623,7 +623,7 @@ func TestHostSalaryFullLifecycleFromPublishedPolicyToNextCycle(t *testing.T) { t.Fatalf("month-end lifecycle result mismatch: %+v", result) } // 480 钻石达到 2 级后剩余 80 钻石,按 0.01 USD/diamond 折算为 80 美分并标记周期已清算。 - assertBalance(t, svc, 10002, ledger.AssetUSDBalance, 380) + assertBalance(t, svc, 10002, ledger.AssetHostSalaryUSD, 380) if got := repository.CountRows("host_salary_settlement_progress", "user_id = ? AND cycle_key = ? AND last_settled_total_diamonds = ? AND residual_usd_minor = ? AND month_end_cleared_at_ms > 0", int64(10002), previousCycle, int64(480), int64(80)); got != 1 { t.Fatalf("month-end progress should store residual and clear marker, got %d", got) } @@ -683,9 +683,9 @@ func TestHostSalaryFullLifecycleFromPublishedPolicyToNextCycle(t *testing.T) { t.Fatalf("next-cycle daily result mismatch: %+v", result) } // 新 cycle_key 使用独立进度,因此月末清算后的下一周期从 1 级累计权益重新开始发放。 - assertBalance(t, svc, 10002, ledger.AssetUSDBalance, 530) + assertBalance(t, svc, 10002, ledger.AssetHostSalaryUSD, 530) assertBalance(t, svc, 10002, ledger.AssetCoin, 288) - assertBalance(t, svc, 30001, ledger.AssetUSDBalance, 130) + assertBalance(t, svc, 30001, ledger.AssetAgencySalaryUSD, 130) nextIDs := repository.HostSalarySettlementIDs(10002, third.HostPeriodCycleKey) if len(nextIDs) != 1 || nextIDs[0] == "" { t.Fatalf("next-cycle settlement id missing: %v", nextIDs) @@ -757,9 +757,9 @@ func TestHostSalaryHalfMonthSettlementUsesPolicyMode(t *testing.T) { if result.ProcessedCount != 1 || result.SuccessCount != 1 || result.FailureCount != 0 { t.Fatalf("half-month settlement result mismatch: %+v", result) } - assertBalance(t, svc, 10003, ledger.AssetUSDBalance, 150) + assertBalance(t, svc, 10003, ledger.AssetHostSalaryUSD, 150) assertBalance(t, svc, 10003, ledger.AssetCoin, 90) - assertBalance(t, svc, 30002, ledger.AssetUSDBalance, 50) + assertBalance(t, svc, 30002, ledger.AssetAgencySalaryUSD, 50) if ids := repository.HostSalarySettlementIDs(10003, receipt.HostPeriodCycleKey); len(ids) != 1 || ids[0] == "" { t.Fatalf("half-month settlement id missing: %v", ids) } @@ -2499,36 +2499,6 @@ func TestEquipUserResourceRequiresActiveEquipableEntitlement(t *testing.T) { } } -// TestApplyWithdrawalFreezesUSDBalance 验证提现申请只创建待审核事实,并把可提现美元余额转入冻结。 -func TestApplyWithdrawalFreezesUSDBalance(t *testing.T) { - repository := mysqltest.NewRepository(t) - repository.SetAssetBalance(50001, ledger.AssetUSDBalance, 3000) - svc := walletservice.New(repository) - - withdrawal, balance, err := svc.ApplyWithdrawal(context.Background(), ledger.WithdrawalCommand{ - CommandID: "cmd-withdraw-usd", - UserID: 50001, - Amount: 1200, - PayoutAccount: "paypal:host@example.com", - Reason: "host payout", - }) - if err != nil { - t.Fatalf("ApplyWithdrawal failed: %v", err) - } - if withdrawal.WithdrawalID == "" || withdrawal.Status != ledger.WithdrawalStatusPending || withdrawal.Amount != 1200 { - t.Fatalf("withdrawal response mismatch: %+v", withdrawal) - } - if balance.AvailableAmount != 1800 || balance.FrozenAmount != 1200 { - t.Fatalf("withdrawal balance mismatch: %+v", balance) - } - if got := repository.CountRows("wallet_withdrawal_requests", "user_id = ? AND status = ?", int64(50001), ledger.WithdrawalStatusPending); got != 1 { - t.Fatalf("withdrawal request should be persisted once, got %d", got) - } - if got := repository.CountRows("wallet_transactions", "command_id = ? AND biz_type = ?", "cmd-withdraw-usd", "withdrawal_apply"); got != 1 { - t.Fatalf("withdrawal should write one transaction, got %d", got) - } -} - // TestPurchaseVipDebitsCoinAndGrantsReward 验证 VIP 购买在同一账务事务中扣金币、更新会员和发权益。 func TestPurchaseVipDebitsCoinAndGrantsReward(t *testing.T) { repository := mysqltest.NewRepository(t) @@ -2845,7 +2815,7 @@ func TestWalletOverviewDisablesDiamondExchange(t *testing.T) { if err != nil { t.Fatalf("GetWalletOverview failed: %v", err) } - if !overview.FeatureFlags.RechargeEnabled || overview.FeatureFlags.DiamondExchangeEnabled || !overview.FeatureFlags.WithdrawEnabled { + if !overview.FeatureFlags.RechargeEnabled || overview.FeatureFlags.DiamondExchangeEnabled { t.Fatalf("wallet feature flags mismatch: %+v", overview.FeatureFlags) } if balanceAmount(overview.Balances, ledger.AssetCoin) != 700 || balanceAmount(overview.Balances, "DIAMOND") != 0 { diff --git a/services/wallet-service/internal/storage/mysql/app_wallet_repository.go b/services/wallet-service/internal/storage/mysql/app_wallet_repository.go index 100bece9..ed0e1620 100644 --- a/services/wallet-service/internal/storage/mysql/app_wallet_repository.go +++ b/services/wallet-service/internal/storage/mysql/app_wallet_repository.go @@ -16,15 +16,21 @@ import ( ) const ( - bizTypeWithdrawalApply = "withdrawal_apply" - bizTypeVIPPurchase = "vip_purchase" - bizTypeVIPGrant = "vip_grant" - vipOutboxAsset = "VIP" + bizTypeVIPPurchase = "vip_purchase" + bizTypeVIPGrant = "vip_grant" + vipOutboxAsset = "VIP" ) // GetWalletOverview 返回钱包首页摘要;开关放在 wallet-service 内,避免 gateway 硬编码账务能力。 func (r *Repository) GetWalletOverview(ctx context.Context, userID int64) (ledger.WalletOverview, error) { - balances, err := r.GetBalances(ctx, userID, []string{ledger.AssetCoin, ledger.AssetUSDBalance}) + // 钱包首页返回所有可展示的资金口袋;工资钱包按身份拆分,0 余额也返回,便于客户端固定布局。 + balances, err := r.GetBalances(ctx, userID, []string{ + ledger.AssetCoin, + ledger.AssetHostSalaryUSD, + ledger.AssetAgencySalaryUSD, + ledger.AssetBDSalaryUSD, + ledger.AssetAdminSalaryUSD, + }) if err != nil { return ledger.WalletOverview{}, err } @@ -33,7 +39,6 @@ func (r *Repository) GetWalletOverview(ctx context.Context, userID int64) (ledge FeatureFlags: ledger.WalletFeatureFlags{ RechargeEnabled: true, DiamondExchangeEnabled: false, - WithdrawEnabled: true, }, }, nil } @@ -196,124 +201,6 @@ func (r *Repository) ListWalletTransactions(ctx context.Context, query ledger.Li return items, total, rows.Err() } -// ApplyWithdrawal 冻结 USD_BALANCE 并写待审核提现申请。后台审核和人工转账是后续独立命令。 -func (r *Repository) ApplyWithdrawal(ctx context.Context, command ledger.WithdrawalCommand) (ledger.WithdrawalRequest, ledger.AssetBalance, error) { - if r == nil || r.db == nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, xerr.New(xerr.Unavailable, "mysql repository is not configured") - } - ctx = contextWithCommandApp(ctx, command.AppCode) - command.AppCode = appcode.FromContext(ctx) - - tx, err := r.db.BeginTx(ctx, nil) - if err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - defer func() { _ = tx.Rollback() }() - - requestHash := stableHash(fmt.Sprintf("withdrawal|%s|%d|%d|%s", command.AppCode, command.UserID, command.Amount, command.PayoutAccount)) - if txRow, exists, err := r.lookupTransaction(ctx, tx, command.CommandID, requestHash, bizTypeWithdrawalApply); err != nil || exists { - if err != nil || !exists { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - withdrawal, balance, receiptErr := r.withdrawalReceiptForTransaction(ctx, tx, txRow.TransactionID, command.UserID) - return withdrawal, balance, receiptErr - } - - nowMs := time.Now().UnixMilli() - account, err := r.lockAccount(ctx, tx, command.UserID, ledger.AssetUSDBalance, false, nowMs) - if err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - if account.AvailableAmount < command.Amount { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, xerr.New(xerr.InsufficientBalance, "insufficient balance") - } - transactionID := transactionID(command.AppCode, command.CommandID) - withdrawalID := "wdr_" + stableHash(command.AppCode+"|"+command.CommandID) - availableAfter := account.AvailableAmount - command.Amount - frozenAfter := account.FrozenAmount + command.Amount - metadata := map[string]any{ - "app_code": command.AppCode, - "withdrawal_id": withdrawalID, - "user_id": command.UserID, - "asset_type": ledger.AssetUSDBalance, - "amount": command.Amount, - "payout_account": command.PayoutAccount, - "reason": command.Reason, - } - if err := r.insertTransaction(ctx, tx, transactionID, command.CommandID, bizTypeWithdrawalApply, requestHash, withdrawalID, metadata, nowMs); err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - if err := r.applyAccountDelta(ctx, tx, account, -command.Amount, command.Amount, nowMs); err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - if err := r.insertEntry(ctx, tx, walletEntry{ - TransactionID: transactionID, - UserID: command.UserID, - AssetType: ledger.AssetUSDBalance, - AvailableDelta: -command.Amount, - FrozenDelta: command.Amount, - AvailableAfter: availableAfter, - FrozenAfter: frozenAfter, - CreatedAtMS: nowMs, - }); err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - withdrawal := ledger.WithdrawalRequest{ - WithdrawalID: withdrawalID, - UserID: command.UserID, - AssetType: ledger.AssetUSDBalance, - Amount: command.Amount, - Status: ledger.WithdrawalStatusPending, - PayoutAccount: command.PayoutAccount, - Reason: command.Reason, - CreatedAtMS: nowMs, - UpdatedAtMS: nowMs, - } - if _, err := tx.ExecContext(ctx, ` - INSERT INTO wallet_withdrawal_requests ( - app_code, withdrawal_id, command_id, user_id, asset_type, amount, status, - payout_account, reason, wallet_transaction_id, created_at_ms, updated_at_ms - ) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`, - command.AppCode, withdrawal.WithdrawalID, command.CommandID, command.UserID, withdrawal.AssetType, - withdrawal.Amount, withdrawal.Status, withdrawal.PayoutAccount, withdrawal.Reason, transactionID, nowMs, nowMs, - ); err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - if err := r.insertWalletOutbox(ctx, tx, []walletOutboxEvent{ - balanceChangedEvent(transactionID, command.CommandID, command.UserID, ledger.AssetUSDBalance, -command.Amount, command.Amount, availableAfter, frozenAfter, account.Version+1, metadata, nowMs), - }); err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - if err := tx.Commit(); err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - - return withdrawal, ledger.AssetBalance{ - AppCode: command.AppCode, - UserID: command.UserID, - AssetType: ledger.AssetUSDBalance, - AvailableAmount: availableAfter, - FrozenAmount: frozenAfter, - Version: account.Version + 1, - UpdatedAtMs: nowMs, - }, nil -} - -func (r *Repository) withdrawalReceiptForTransaction(ctx context.Context, tx *sql.Tx, transactionID string, userID int64) (ledger.WithdrawalRequest, ledger.AssetBalance, error) { - row := tx.QueryRowContext(ctx, ` - SELECT withdrawal_id, user_id, asset_type, amount, status, payout_account, reason, created_at_ms, updated_at_ms - FROM wallet_withdrawal_requests - WHERE app_code = ? AND wallet_transaction_id = ?`, - appcode.FromContext(ctx), transactionID, - ) - var withdrawal ledger.WithdrawalRequest - if err := row.Scan(&withdrawal.WithdrawalID, &withdrawal.UserID, &withdrawal.AssetType, &withdrawal.Amount, &withdrawal.Status, &withdrawal.PayoutAccount, &withdrawal.Reason, &withdrawal.CreatedAtMS, &withdrawal.UpdatedAtMS); err != nil { - return ledger.WithdrawalRequest{}, ledger.AssetBalance{}, err - } - balance, err := r.balanceAfterTransaction(ctx, tx, transactionID, userID, ledger.AssetUSDBalance) - return withdrawal, balance, err -} - // GetMyVip 返回用户当前 VIP 状态;过期只影响 active 投影,不直接修改历史事实。 func (r *Repository) GetMyVip(ctx context.Context, userID int64) (ledger.UserVip, error) { if r == nil || r.db == nil { diff --git a/services/wallet-service/internal/storage/mysql/host_salary_settlement.go b/services/wallet-service/internal/storage/mysql/host_salary_settlement.go index 0b444a34..ff3603ff 100644 --- a/services/wallet-service/internal/storage/mysql/host_salary_settlement.go +++ b/services/wallet-service/internal/storage/mysql/host_salary_settlement.go @@ -57,6 +57,8 @@ type hostSalarySettlementMetadata struct { HostUSDBalanceAfter int64 `json:"host_usd_balance_after"` HostCoinBalanceAfter int64 `json:"host_coin_balance_after"` AgencyUSDBalanceAfter int64 `json:"agency_usd_balance_after"` + HostSalaryAssetType string `json:"host_salary_asset_type"` + AgencySalaryAssetType string `json:"agency_salary_asset_type"` SettledLevelNo int `json:"settled_level_no"` SettledHostSalaryUSDMinor int64 `json:"settled_host_salary_usd_minor"` SettledHostCoinReward int64 `json:"settled_host_coin_reward"` @@ -262,6 +264,8 @@ func (r *Repository) processHostSalaryCandidate(ctx context.Context, command led HostCoinRewardDelta: hostCoinDelta, AgencySalaryUSDMinorDelta: agencyPaidDelta, ResidualUSDMinorDelta: residualDelta, + HostSalaryAssetType: ledger.AssetHostSalaryUSD, + AgencySalaryAssetType: ledger.AssetAgencySalaryUSD, SettledLevelNo: nextProgress.SettledLevelNo, SettledHostSalaryUSDMinor: nextProgress.SettledHostSalaryUSDMinor, SettledHostCoinReward: nextProgress.SettledHostCoinReward, @@ -407,12 +411,13 @@ func (r *Repository) applyHostSalaryCredits(ctx context.Context, tx *sql.Tx, tra // 主播美元、主播金币、代理美元共用同一 transaction_id,确保账务上可视为一次工资结算。 events := make([]walletOutboxEvent, 0, 3) if hostUSDDelta > 0 { - balanceAfter, version, err := r.creditSettlementAsset(ctx, tx, transactionID, metadata.HostUserID, ledger.AssetUSDBalance, hostUSDDelta, 0, nowMs) + // 主播工资和月底剩余钻石折美元只进入主播工资钱包,不混入代理或团队工资钱包。 + balanceAfter, version, err := r.creditSettlementAsset(ctx, tx, transactionID, metadata.HostUserID, ledger.AssetHostSalaryUSD, hostUSDDelta, 0, nowMs) if err != nil { return nil, err } metadata.HostUSDBalanceAfter = balanceAfter - events = append(events, balanceChangedEvent(transactionID, commandID, metadata.HostUserID, ledger.AssetUSDBalance, hostUSDDelta, 0, balanceAfter, 0, version, metadata, nowMs)) + events = append(events, balanceChangedEvent(transactionID, commandID, metadata.HostUserID, ledger.AssetHostSalaryUSD, hostUSDDelta, 0, balanceAfter, 0, version, metadata, nowMs)) } if hostCoinDelta > 0 { balanceAfter, version, err := r.creditSettlementAsset(ctx, tx, transactionID, metadata.HostUserID, ledger.AssetCoin, hostCoinDelta, 0, nowMs) @@ -423,12 +428,13 @@ func (r *Repository) applyHostSalaryCredits(ctx context.Context, tx *sql.Tx, tra events = append(events, balanceChangedEvent(transactionID, commandID, metadata.HostUserID, ledger.AssetCoin, hostCoinDelta, 0, balanceAfter, 0, version, metadata, nowMs)) } if agencyUSDDelta > 0 { - balanceAfter, version, err := r.creditSettlementAsset(ctx, tx, transactionID, metadata.AgencyOwnerUserID, ledger.AssetUSDBalance, agencyUSDDelta, metadata.HostUserID, nowMs) + // 代理工资进入代理工资钱包,同一用户若同时是主播也不会和主播工资钱包合并。 + balanceAfter, version, err := r.creditSettlementAsset(ctx, tx, transactionID, metadata.AgencyOwnerUserID, ledger.AssetAgencySalaryUSD, agencyUSDDelta, metadata.HostUserID, nowMs) if err != nil { return nil, err } metadata.AgencyUSDBalanceAfter = balanceAfter - events = append(events, balanceChangedEvent(transactionID, commandID, metadata.AgencyOwnerUserID, ledger.AssetUSDBalance, agencyUSDDelta, 0, balanceAfter, 0, version, metadata, nowMs)) + events = append(events, balanceChangedEvent(transactionID, commandID, metadata.AgencyOwnerUserID, ledger.AssetAgencySalaryUSD, agencyUSDDelta, 0, balanceAfter, 0, version, metadata, nowMs)) } return events, nil } diff --git a/services/wallet-service/internal/testutil/mysqltest/mysqltest.go b/services/wallet-service/internal/testutil/mysqltest/mysqltest.go index 7e14b9a7..5f9c3340 100644 --- a/services/wallet-service/internal/testutil/mysqltest/mysqltest.go +++ b/services/wallet-service/internal/testutil/mysqltest/mysqltest.go @@ -534,7 +534,7 @@ func validateTableName(table string) string { case "wallet_transactions", "wallet_entries", "wallet_outbox", "wallet_accounts", "wallet_recharge_records", "host_period_diamond_accounts", "host_period_diamond_entries", "host_agency_salary_policies", "host_agency_salary_policy_levels", "host_salary_settlement_progress", "host_salary_settlement_records", - "coin_seller_stock_records", "gift_diamond_ratio_configs", "wallet_diamond_exchange_rules", "wallet_withdrawal_requests", + "coin_seller_stock_records", "gift_diamond_ratio_configs", "wallet_diamond_exchange_rules", "vip_levels", "user_vip_memberships", "vip_purchase_orders", "user_vip_history", "resources", "resource_groups", "resource_group_items", "resource_shop_items", "resource_shop_purchase_orders", "gift_type_configs", "gift_configs", "gift_config_regions", "user_gift_wall", "wallet_projection_events", "resource_grants", "resource_grant_items", "user_resource_entitlements", "user_resource_equipment": diff --git a/services/wallet-service/internal/transport/grpc/server.go b/services/wallet-service/internal/transport/grpc/server.go index 205167bf..0f4263f4 100644 --- a/services/wallet-service/internal/transport/grpc/server.go +++ b/services/wallet-service/internal/transport/grpc/server.go @@ -329,26 +329,6 @@ func (s *Server) ListWalletTransactions(ctx context.Context, req *walletv1.ListW return resp, nil } -// ApplyWithdrawal 创建提现申请并冻结美元余额。 -func (s *Server) ApplyWithdrawal(ctx context.Context, req *walletv1.ApplyWithdrawalRequest) (*walletv1.ApplyWithdrawalResponse, error) { - ctx = appcode.WithContext(ctx, req.GetAppCode()) - withdrawal, balance, err := s.svc.ApplyWithdrawal(ctx, ledger.WithdrawalCommand{ - AppCode: req.GetAppCode(), - CommandID: req.GetCommandId(), - UserID: req.GetUserId(), - Amount: req.GetAmount(), - PayoutAccount: req.GetPayoutAccount(), - Reason: req.GetReason(), - }) - if err != nil { - return nil, xerr.ToGRPCError(err) - } - return &walletv1.ApplyWithdrawalResponse{ - Withdrawal: withdrawalToProto(withdrawal), - Balance: balanceToProto(balance), - }, nil -} - // ListVipPackages 返回当前 VIP 和可购买包列表。 func (s *Server) ListVipPackages(ctx context.Context, req *walletv1.ListVipPackagesRequest) (*walletv1.ListVipPackagesResponse, error) { ctx = appcode.WithContext(ctx, req.GetAppCode()) @@ -562,21 +542,6 @@ func walletFeatureFlagsToProto(flags ledger.WalletFeatureFlags) *walletv1.Wallet return &walletv1.WalletFeatureFlags{ RechargeEnabled: flags.RechargeEnabled, DiamondExchangeEnabled: flags.DiamondExchangeEnabled, - WithdrawEnabled: flags.WithdrawEnabled, - } -} - -func withdrawalToProto(withdrawal ledger.WithdrawalRequest) *walletv1.WithdrawalRequest { - return &walletv1.WithdrawalRequest{ - WithdrawalId: withdrawal.WithdrawalID, - UserId: withdrawal.UserID, - AssetType: withdrawal.AssetType, - Amount: withdrawal.Amount, - Status: withdrawal.Status, - PayoutAccount: withdrawal.PayoutAccount, - Reason: withdrawal.Reason, - CreatedAtMs: withdrawal.CreatedAtMS, - UpdatedAtMs: withdrawal.UpdatedAtMS, } }