diff --git a/build/rpc.json b/build/rpc.json index 2829272..48e45d1 100644 --- a/build/rpc.json +++ b/build/rpc.json @@ -14634,7 +14634,7 @@ }, { "name": "CountUserAccountsRequest", - "code": "message CountUserAccountsRequest {\n\tstring keyword = 1;\n}", + "code": "message CountUserAccountsRequest {\n\tstring keyword = 1; // 关键词\n}", "doc": "计算账户数量" }, { @@ -15489,7 +15489,7 @@ }, { "name": "CreateReverseProxyResponse", - "code": "message CreateReverseProxyResponse {\n\tint64 reverseProxyId = 1;\n}", + "code": "message CreateReverseProxyResponse {\n\tint64 reverseProxyId = 1; // 反向代理ID\n}", "doc": "" }, { @@ -18369,22 +18369,22 @@ }, { "name": "FindEnabledReverseProxyConfigRequest", - "code": "message FindEnabledReverseProxyConfigRequest {\n\tint64 reverseProxyId = 1;\n}", + "code": "message FindEnabledReverseProxyConfigRequest {\n\tint64 reverseProxyId = 1; // 反向代理ID\n}", "doc": "查找反向代理配置" }, { "name": "FindEnabledReverseProxyConfigResponse", - "code": "message FindEnabledReverseProxyConfigResponse {\n\tbytes reverseProxyJSON = 1;\n}", + "code": "message FindEnabledReverseProxyConfigResponse {\n\tbytes reverseProxyJSON = 1; // 反向代理配置\n}", "doc": "" }, { "name": "FindEnabledReverseProxyRequest", - "code": "message FindEnabledReverseProxyRequest {\n\tint64 reverseProxyId = 1;\n}", + "code": "message FindEnabledReverseProxyRequest {\n\tint64 reverseProxyId = 1; // 反向代理ID\n}", "doc": "查找反向代理" }, { "name": "FindEnabledReverseProxyResponse", - "code": "message FindEnabledReverseProxyResponse {\n\tReverseProxy reverseProxy = 1;\n}", + "code": "message FindEnabledReverseProxyResponse {\n\tReverseProxy reverseProxy = 1; // 反向代理信息\n}", "doc": "" }, { @@ -18499,22 +18499,22 @@ }, { "name": "FindEnabledUserAccountRequest", - "code": "message FindEnabledUserAccountRequest {\n\tint64 userAccountId = 1;\n}", + "code": "message FindEnabledUserAccountRequest {\n\tint64 userAccountId = 1; // 用户账户ID\n}", "doc": "查找单个账户" }, { "name": "FindEnabledUserAccountResponse", - "code": "message FindEnabledUserAccountResponse {\n\tUserAccount userAccount = 1;\n}", + "code": "message FindEnabledUserAccountResponse {\n\tUserAccount userAccount = 1; // 用户账户\n}", "doc": "" }, { "name": "FindEnabledUserAccountWithUserIdRequest", - "code": "message FindEnabledUserAccountWithUserIdRequest {\n\tint64 userId = 1;\n}", + "code": "message FindEnabledUserAccountWithUserIdRequest {\n\tint64 userId = 1; // 用户ID\n}", "doc": "根据用户ID查找单个账户" }, { "name": "FindEnabledUserAccountWithUserIdResponse", - "code": "message FindEnabledUserAccountWithUserIdResponse {\n\tUserAccount userAccount = 1;\n}", + "code": "message FindEnabledUserAccountWithUserIdResponse {\n\tUserAccount userAccount = 1; // 用户账户\n}", "doc": "" }, { @@ -20699,12 +20699,12 @@ }, { "name": "ListUserAccountsRequest", - "code": "message ListUserAccountsRequest {\n\tstring keyword = 1;\n\tint64 offset = 2;\n\tint64 size = 3;\n}", + "code": "message ListUserAccountsRequest {\n\tstring keyword = 1; // 关键词\n\tint64 offset = 2;\n\tint64 size = 3;\n}", "doc": "列出单页账户" }, { "name": "ListUserAccountsResponse", - "code": "message ListUserAccountsResponse {\n\trepeated UserAccount userAccounts = 1;\n}", + "code": "message ListUserAccountsResponse {\n\trepeated UserAccount userAccounts = 1; // 用户账户列表\n}", "doc": "" }, { @@ -22539,12 +22539,12 @@ }, { "name": "UpdateReverseProxyBackupOriginsRequest", - "code": "message UpdateReverseProxyBackupOriginsRequest {\n\tint64 reverseProxyId = 1;\n\tbytes originsJSON = 2;\n}", + "code": "message UpdateReverseProxyBackupOriginsRequest {\n\tint64 reverseProxyId = 1; // 反向代理ID\n\tbytes originsJSON = 2; // 源站配置 @link json:origin_refs\n}", "doc": "修改备用源站信息" }, { "name": "UpdateReverseProxyPrimaryOriginsRequest", - "code": "message UpdateReverseProxyPrimaryOriginsRequest {\n\tint64 reverseProxyId = 1;\n\tbytes originsJSON = 2;\n}", + "code": "message UpdateReverseProxyPrimaryOriginsRequest {\n\tint64 reverseProxyId = 1; // 反向代理ID\n\tbytes originsJSON = 2; // 源站配置 @link json:origin_refs\n}", "doc": "修改主要源站信息" }, { @@ -22554,7 +22554,7 @@ }, { "name": "UpdateReverseProxySchedulingRequest", - "code": "message UpdateReverseProxySchedulingRequest {\n\tint64 reverseProxyId = 1;\n\tbytes schedulingJSON = 2;\n}", + "code": "message UpdateReverseProxySchedulingRequest {\n\tint64 reverseProxyId = 1; // 反向代理ID\n\tbytes schedulingJSON = 2; // 调度配置 @link json:scheduling\n}", "doc": "修改反向代理调度算法" }, { @@ -22729,7 +22729,7 @@ }, { "name": "UpdateUserAccountRequest", - "code": "message UpdateUserAccountRequest {\n\tint64 userAccountId = 1;\n\tdouble delta = 2;\n\tstring eventType = 3;\n\tstring description = 4;\n\tbytes paramsJSON = 5;\n}", + "code": "message UpdateUserAccountRequest {\n\tint64 userAccountId = 1; // 用户账户ID(非用户ID)\n\tdouble delta = 2; // 操作的数值,正值表示增加,负值表示减少\n\tstring eventType = 3; // 事件类型:charge, award, buyPlan, payBill, refund, withdraw, buyNSPlan, buyTrafficPackage, buyAntiDDoSPackage, renewAntiDDoSPackage\n\tstring description = 4; // 描述\n\tbytes paramsJSON = 5; // 相关参数\n}", "doc": "修改用户账户" }, { @@ -22844,7 +22844,7 @@ }, { "name": "User", - "code": "message User {\n\tint64 id = 1; // 用户ID\n\tstring username = 2; // 用户名\n\tstring fullname = 3; // 全称\n\tstring mobile = 4; // 手机号码\n\tstring tel = 5; // 联系电话\n\tstring email = 6; // 联系邮箱\n\tstring verifiedEmail = 20; // 已验证邮箱\n\tstring verifiedMobile = 23; // 已验证手机号码\n\tstring remark = 7;\n\tbool isOn = 8;\n\tint64 createdAt = 9;\n\tstring registeredIP = 12;\n\tbool isVerified = 13;\n\tbool isRejected = 14;\n\tstring rejectReason = 15;\n\tbool isDeleted = 16;\n\tbool isIndividualIdentified = 17; // 是否已通过个人验证\n\tbool isEnterpriseIdentified = 18; // 是否已通过企业验证\n\tstring bandwidthAlgo = 21; // 带宽算法\n\tstring lang = 22; // 语言代号\n\n\tLogin otpLogin = 19; // OTP认证\n\n\tNodeCluster nodeCluster = 10;\n\trepeated UserFeature features = 11;\n}", + "code": "message User {\n\tint64 id = 1; // 用户ID\n\tstring username = 2; // 用户名\n\tstring fullname = 3; // 全称\n\tstring mobile = 4; // 手机号码\n\tstring tel = 5; // 联系电话\n\tstring email = 6; // 联系邮箱\n\tstring verifiedEmail = 20; // 已验证邮箱\n\tstring verifiedMobile = 23; // 已验证手机号码\n\tstring remark = 7; // 备注\n\tbool isOn = 8; // 是否启用\n\tint64 createdAt = 9; // 创建时间\n\tstring registeredIP = 12; // 注册IP\n\tbool isVerified = 13; // 是否已实名认证\n\tbool isRejected = 14; // 实名认证是否已拒绝\n\tstring rejectReason = 15; // 实名认证拒绝理由\n\tbool isDeleted = 16; // 是否已删除\n\tbool isIndividualIdentified = 17; // 是否已通过个人验证\n\tbool isEnterpriseIdentified = 18; // 是否已通过企业验证\n\tstring bandwidthAlgo = 21; // 带宽算法\n\tstring lang = 22; // 语言代号\n\n\tLogin otpLogin = 19; // OTP认证\n\n\tNodeCluster nodeCluster = 10; // 集群信息\n\trepeated UserFeature features = 11; // 开通功能\n}", "doc": "" }, { @@ -22859,7 +22859,7 @@ }, { "name": "UserAccount", - "code": "message UserAccount {\n\tint64 id = 1;\n\tint64 userId = 2;\n\tdouble total = 3;\n\tdouble totalFrozen = 4;\n\n\tUser user = 30;\n}", + "code": "message UserAccount {\n\tint64 id = 1; // 账户ID\n\tint64 userId = 2; // 用户ID\n\tdouble total = 3; // 总可用余额\n\tdouble totalFrozen = 4; // 总冻结余额\n\n\tUser user = 30; // 用户信息\n}", "doc": "" }, { diff --git a/pkg/rpc/pb/model_user.pb.go b/pkg/rpc/pb/model_user.pb.go index 7313c2c..3b700ea 100644 --- a/pkg/rpc/pb/model_user.pb.go +++ b/pkg/rpc/pb/model_user.pb.go @@ -25,29 +25,29 @@ type User struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // 用户ID - Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"` // 用户名 - Fullname string `protobuf:"bytes,3,opt,name=fullname,proto3" json:"fullname,omitempty"` // 全称 - Mobile string `protobuf:"bytes,4,opt,name=mobile,proto3" json:"mobile,omitempty"` // 手机号码 - Tel string `protobuf:"bytes,5,opt,name=tel,proto3" json:"tel,omitempty"` // 联系电话 - Email string `protobuf:"bytes,6,opt,name=email,proto3" json:"email,omitempty"` // 联系邮箱 - VerifiedEmail string `protobuf:"bytes,20,opt,name=verifiedEmail,proto3" json:"verifiedEmail,omitempty"` // 已验证邮箱 - VerifiedMobile string `protobuf:"bytes,23,opt,name=verifiedMobile,proto3" json:"verifiedMobile,omitempty"` // 已验证手机号码 - Remark string `protobuf:"bytes,7,opt,name=remark,proto3" json:"remark,omitempty"` - IsOn bool `protobuf:"varint,8,opt,name=isOn,proto3" json:"isOn,omitempty"` - CreatedAt int64 `protobuf:"varint,9,opt,name=createdAt,proto3" json:"createdAt,omitempty"` - RegisteredIP string `protobuf:"bytes,12,opt,name=registeredIP,proto3" json:"registeredIP,omitempty"` - IsVerified bool `protobuf:"varint,13,opt,name=isVerified,proto3" json:"isVerified,omitempty"` - IsRejected bool `protobuf:"varint,14,opt,name=isRejected,proto3" json:"isRejected,omitempty"` - RejectReason string `protobuf:"bytes,15,opt,name=rejectReason,proto3" json:"rejectReason,omitempty"` - IsDeleted bool `protobuf:"varint,16,opt,name=isDeleted,proto3" json:"isDeleted,omitempty"` + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // 用户ID + Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"` // 用户名 + Fullname string `protobuf:"bytes,3,opt,name=fullname,proto3" json:"fullname,omitempty"` // 全称 + Mobile string `protobuf:"bytes,4,opt,name=mobile,proto3" json:"mobile,omitempty"` // 手机号码 + Tel string `protobuf:"bytes,5,opt,name=tel,proto3" json:"tel,omitempty"` // 联系电话 + Email string `protobuf:"bytes,6,opt,name=email,proto3" json:"email,omitempty"` // 联系邮箱 + VerifiedEmail string `protobuf:"bytes,20,opt,name=verifiedEmail,proto3" json:"verifiedEmail,omitempty"` // 已验证邮箱 + VerifiedMobile string `protobuf:"bytes,23,opt,name=verifiedMobile,proto3" json:"verifiedMobile,omitempty"` // 已验证手机号码 + Remark string `protobuf:"bytes,7,opt,name=remark,proto3" json:"remark,omitempty"` // 备注 + IsOn bool `protobuf:"varint,8,opt,name=isOn,proto3" json:"isOn,omitempty"` // 是否启用 + CreatedAt int64 `protobuf:"varint,9,opt,name=createdAt,proto3" json:"createdAt,omitempty"` // 创建时间 + RegisteredIP string `protobuf:"bytes,12,opt,name=registeredIP,proto3" json:"registeredIP,omitempty"` // 注册IP + IsVerified bool `protobuf:"varint,13,opt,name=isVerified,proto3" json:"isVerified,omitempty"` // 是否已实名认证 + IsRejected bool `protobuf:"varint,14,opt,name=isRejected,proto3" json:"isRejected,omitempty"` // 实名认证是否已拒绝 + RejectReason string `protobuf:"bytes,15,opt,name=rejectReason,proto3" json:"rejectReason,omitempty"` // 实名认证拒绝理由 + IsDeleted bool `protobuf:"varint,16,opt,name=isDeleted,proto3" json:"isDeleted,omitempty"` // 是否已删除 IsIndividualIdentified bool `protobuf:"varint,17,opt,name=isIndividualIdentified,proto3" json:"isIndividualIdentified,omitempty"` // 是否已通过个人验证 IsEnterpriseIdentified bool `protobuf:"varint,18,opt,name=isEnterpriseIdentified,proto3" json:"isEnterpriseIdentified,omitempty"` // 是否已通过企业验证 BandwidthAlgo string `protobuf:"bytes,21,opt,name=bandwidthAlgo,proto3" json:"bandwidthAlgo,omitempty"` // 带宽算法 Lang string `protobuf:"bytes,22,opt,name=lang,proto3" json:"lang,omitempty"` // 语言代号 OtpLogin *Login `protobuf:"bytes,19,opt,name=otpLogin,proto3" json:"otpLogin,omitempty"` // OTP认证 - NodeCluster *NodeCluster `protobuf:"bytes,10,opt,name=nodeCluster,proto3" json:"nodeCluster,omitempty"` - Features []*UserFeature `protobuf:"bytes,11,rep,name=features,proto3" json:"features,omitempty"` + NodeCluster *NodeCluster `protobuf:"bytes,10,opt,name=nodeCluster,proto3" json:"nodeCluster,omitempty"` // 集群信息 + Features []*UserFeature `protobuf:"bytes,11,rep,name=features,proto3" json:"features,omitempty"` // 开通功能 } func (x *User) Reset() { diff --git a/pkg/rpc/pb/model_user_account.pb.go b/pkg/rpc/pb/model_user_account.pb.go index a669af1..2856df3 100644 --- a/pkg/rpc/pb/model_user_account.pb.go +++ b/pkg/rpc/pb/model_user_account.pb.go @@ -25,11 +25,11 @@ type UserAccount struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` - UserId int64 `protobuf:"varint,2,opt,name=userId,proto3" json:"userId,omitempty"` - Total float64 `protobuf:"fixed64,3,opt,name=total,proto3" json:"total,omitempty"` - TotalFrozen float64 `protobuf:"fixed64,4,opt,name=totalFrozen,proto3" json:"totalFrozen,omitempty"` - User *User `protobuf:"bytes,30,opt,name=user,proto3" json:"user,omitempty"` + Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // 账户ID + UserId int64 `protobuf:"varint,2,opt,name=userId,proto3" json:"userId,omitempty"` // 用户ID + Total float64 `protobuf:"fixed64,3,opt,name=total,proto3" json:"total,omitempty"` // 总可用余额 + TotalFrozen float64 `protobuf:"fixed64,4,opt,name=totalFrozen,proto3" json:"totalFrozen,omitempty"` // 总冻结余额 + User *User `protobuf:"bytes,30,opt,name=user,proto3" json:"user,omitempty"` // 用户信息 } func (x *UserAccount) Reset() { diff --git a/pkg/rpc/pb/service_reverse_proxy.pb.go b/pkg/rpc/pb/service_reverse_proxy.pb.go index cd5cae6..cea1dae 100644 --- a/pkg/rpc/pb/service_reverse_proxy.pb.go +++ b/pkg/rpc/pb/service_reverse_proxy.pb.go @@ -89,7 +89,7 @@ type CreateReverseProxyResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` + ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` // 反向代理ID } func (x *CreateReverseProxyResponse) Reset() { @@ -137,7 +137,7 @@ type FindEnabledReverseProxyRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` + ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` // 反向代理ID } func (x *FindEnabledReverseProxyRequest) Reset() { @@ -184,7 +184,7 @@ type FindEnabledReverseProxyResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReverseProxy *ReverseProxy `protobuf:"bytes,1,opt,name=reverseProxy,proto3" json:"reverseProxy,omitempty"` + ReverseProxy *ReverseProxy `protobuf:"bytes,1,opt,name=reverseProxy,proto3" json:"reverseProxy,omitempty"` // 反向代理信息 } func (x *FindEnabledReverseProxyResponse) Reset() { @@ -232,7 +232,7 @@ type FindEnabledReverseProxyConfigRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` + ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` // 反向代理ID } func (x *FindEnabledReverseProxyConfigRequest) Reset() { @@ -279,7 +279,7 @@ type FindEnabledReverseProxyConfigResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReverseProxyJSON []byte `protobuf:"bytes,1,opt,name=reverseProxyJSON,proto3" json:"reverseProxyJSON,omitempty"` + ReverseProxyJSON []byte `protobuf:"bytes,1,opt,name=reverseProxyJSON,proto3" json:"reverseProxyJSON,omitempty"` // 反向代理配置 } func (x *FindEnabledReverseProxyConfigResponse) Reset() { @@ -327,8 +327,8 @@ type UpdateReverseProxySchedulingRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` - SchedulingJSON []byte `protobuf:"bytes,2,opt,name=schedulingJSON,proto3" json:"schedulingJSON,omitempty"` + ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` // 反向代理ID + SchedulingJSON []byte `protobuf:"bytes,2,opt,name=schedulingJSON,proto3" json:"schedulingJSON,omitempty"` // 调度配置 @link json:scheduling } func (x *UpdateReverseProxySchedulingRequest) Reset() { @@ -383,8 +383,8 @@ type UpdateReverseProxyPrimaryOriginsRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` - OriginsJSON []byte `protobuf:"bytes,2,opt,name=originsJSON,proto3" json:"originsJSON,omitempty"` + ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` // 反向代理ID + OriginsJSON []byte `protobuf:"bytes,2,opt,name=originsJSON,proto3" json:"originsJSON,omitempty"` // 源站配置 @link json:origin_refs } func (x *UpdateReverseProxyPrimaryOriginsRequest) Reset() { @@ -439,8 +439,8 @@ type UpdateReverseProxyBackupOriginsRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` - OriginsJSON []byte `protobuf:"bytes,2,opt,name=originsJSON,proto3" json:"originsJSON,omitempty"` + ReverseProxyId int64 `protobuf:"varint,1,opt,name=reverseProxyId,proto3" json:"reverseProxyId,omitempty"` // 反向代理ID + OriginsJSON []byte `protobuf:"bytes,2,opt,name=originsJSON,proto3" json:"originsJSON,omitempty"` // 源站配置 @link json:origin_refs } func (x *UpdateReverseProxyBackupOriginsRequest) Reset() { diff --git a/pkg/rpc/pb/service_user_account.pb.go b/pkg/rpc/pb/service_user_account.pb.go index cf79184..a4badc3 100644 --- a/pkg/rpc/pb/service_user_account.pb.go +++ b/pkg/rpc/pb/service_user_account.pb.go @@ -26,7 +26,7 @@ type CountUserAccountsRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Keyword string `protobuf:"bytes,1,opt,name=keyword,proto3" json:"keyword,omitempty"` + Keyword string `protobuf:"bytes,1,opt,name=keyword,proto3" json:"keyword,omitempty"` // 关键词 } func (x *CountUserAccountsRequest) Reset() { @@ -74,7 +74,7 @@ type ListUserAccountsRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Keyword string `protobuf:"bytes,1,opt,name=keyword,proto3" json:"keyword,omitempty"` + Keyword string `protobuf:"bytes,1,opt,name=keyword,proto3" json:"keyword,omitempty"` // 关键词 Offset int64 `protobuf:"varint,2,opt,name=offset,proto3" json:"offset,omitempty"` Size int64 `protobuf:"varint,3,opt,name=size,proto3" json:"size,omitempty"` } @@ -137,7 +137,7 @@ type ListUserAccountsResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - UserAccounts []*UserAccount `protobuf:"bytes,1,rep,name=userAccounts,proto3" json:"userAccounts,omitempty"` + UserAccounts []*UserAccount `protobuf:"bytes,1,rep,name=userAccounts,proto3" json:"userAccounts,omitempty"` // 用户账户列表 } func (x *ListUserAccountsResponse) Reset() { @@ -185,7 +185,7 @@ type FindEnabledUserAccountWithUserIdRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - UserId int64 `protobuf:"varint,1,opt,name=userId,proto3" json:"userId,omitempty"` + UserId int64 `protobuf:"varint,1,opt,name=userId,proto3" json:"userId,omitempty"` // 用户ID } func (x *FindEnabledUserAccountWithUserIdRequest) Reset() { @@ -232,7 +232,7 @@ type FindEnabledUserAccountWithUserIdResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - UserAccount *UserAccount `protobuf:"bytes,1,opt,name=userAccount,proto3" json:"userAccount,omitempty"` + UserAccount *UserAccount `protobuf:"bytes,1,opt,name=userAccount,proto3" json:"userAccount,omitempty"` // 用户账户 } func (x *FindEnabledUserAccountWithUserIdResponse) Reset() { @@ -280,7 +280,7 @@ type FindEnabledUserAccountRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - UserAccountId int64 `protobuf:"varint,1,opt,name=userAccountId,proto3" json:"userAccountId,omitempty"` + UserAccountId int64 `protobuf:"varint,1,opt,name=userAccountId,proto3" json:"userAccountId,omitempty"` // 用户账户ID } func (x *FindEnabledUserAccountRequest) Reset() { @@ -327,7 +327,7 @@ type FindEnabledUserAccountResponse struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - UserAccount *UserAccount `protobuf:"bytes,1,opt,name=userAccount,proto3" json:"userAccount,omitempty"` + UserAccount *UserAccount `protobuf:"bytes,1,opt,name=userAccount,proto3" json:"userAccount,omitempty"` // 用户账户 } func (x *FindEnabledUserAccountResponse) Reset() { @@ -375,11 +375,11 @@ type UpdateUserAccountRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - UserAccountId int64 `protobuf:"varint,1,opt,name=userAccountId,proto3" json:"userAccountId,omitempty"` - Delta float64 `protobuf:"fixed64,2,opt,name=delta,proto3" json:"delta,omitempty"` - EventType string `protobuf:"bytes,3,opt,name=eventType,proto3" json:"eventType,omitempty"` - Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description,omitempty"` - ParamsJSON []byte `protobuf:"bytes,5,opt,name=paramsJSON,proto3" json:"paramsJSON,omitempty"` + UserAccountId int64 `protobuf:"varint,1,opt,name=userAccountId,proto3" json:"userAccountId,omitempty"` // 用户账户ID(非用户ID) + Delta float64 `protobuf:"fixed64,2,opt,name=delta,proto3" json:"delta,omitempty"` // 操作的数值,正值表示增加,负值表示减少 + EventType string `protobuf:"bytes,3,opt,name=eventType,proto3" json:"eventType,omitempty"` // 事件类型:charge, award, buyPlan, payBill, refund, withdraw, buyNSPlan, buyTrafficPackage, buyAntiDDoSPackage, renewAntiDDoSPackage + Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description,omitempty"` // 描述 + ParamsJSON []byte `protobuf:"bytes,5,opt,name=paramsJSON,proto3" json:"paramsJSON,omitempty"` // 相关参数 } func (x *UpdateUserAccountRequest) Reset() { diff --git a/pkg/rpc/protos/models/model_user.proto b/pkg/rpc/protos/models/model_user.proto index e960ce6..16d729d 100644 --- a/pkg/rpc/protos/models/model_user.proto +++ b/pkg/rpc/protos/models/model_user.proto @@ -16,14 +16,14 @@ message User { string email = 6; // 联系邮箱 string verifiedEmail = 20; // 已验证邮箱 string verifiedMobile = 23; // 已验证手机号码 - string remark = 7; - bool isOn = 8; - int64 createdAt = 9; - string registeredIP = 12; - bool isVerified = 13; - bool isRejected = 14; - string rejectReason = 15; - bool isDeleted = 16; + string remark = 7; // 备注 + bool isOn = 8; // 是否启用 + int64 createdAt = 9; // 创建时间 + string registeredIP = 12; // 注册IP + bool isVerified = 13; // 是否已实名认证 + bool isRejected = 14; // 实名认证是否已拒绝 + string rejectReason = 15; // 实名认证拒绝理由 + bool isDeleted = 16; // 是否已删除 bool isIndividualIdentified = 17; // 是否已通过个人验证 bool isEnterpriseIdentified = 18; // 是否已通过企业验证 string bandwidthAlgo = 21; // 带宽算法 @@ -31,6 +31,6 @@ message User { Login otpLogin = 19; // OTP认证 - NodeCluster nodeCluster = 10; - repeated UserFeature features = 11; + NodeCluster nodeCluster = 10; // 集群信息 + repeated UserFeature features = 11; // 开通功能 } \ No newline at end of file diff --git a/pkg/rpc/protos/models/model_user_account.proto b/pkg/rpc/protos/models/model_user_account.proto index 1590fcb..d0b57ac 100644 --- a/pkg/rpc/protos/models/model_user_account.proto +++ b/pkg/rpc/protos/models/model_user_account.proto @@ -6,10 +6,10 @@ package pb; import "models/model_user.proto"; message UserAccount { - int64 id = 1; - int64 userId = 2; - double total = 3; - double totalFrozen = 4; + int64 id = 1; // 账户ID + int64 userId = 2; // 用户ID + double total = 3; // 总可用余额 + double totalFrozen = 4; // 总冻结余额 - User user = 30; + User user = 30; // 用户信息 } \ No newline at end of file diff --git a/pkg/rpc/protos/service_reverse_proxy.proto b/pkg/rpc/protos/service_reverse_proxy.proto index 842f702..4fe7919 100644 --- a/pkg/rpc/protos/service_reverse_proxy.proto +++ b/pkg/rpc/protos/service_reverse_proxy.proto @@ -38,43 +38,43 @@ message CreateReverseProxyRequest { } message CreateReverseProxyResponse { - int64 reverseProxyId = 1; + int64 reverseProxyId = 1; // 反向代理ID } // 查找反向代理 message FindEnabledReverseProxyRequest { - int64 reverseProxyId = 1; + int64 reverseProxyId = 1; // 反向代理ID } message FindEnabledReverseProxyResponse { - ReverseProxy reverseProxy = 1; + ReverseProxy reverseProxy = 1; // 反向代理信息 } // 查找反向代理配置 message FindEnabledReverseProxyConfigRequest { - int64 reverseProxyId = 1; + int64 reverseProxyId = 1; // 反向代理ID } message FindEnabledReverseProxyConfigResponse { - bytes reverseProxyJSON = 1; + bytes reverseProxyJSON = 1; // 反向代理配置 } // 修改反向代理调度算法 message UpdateReverseProxySchedulingRequest { - int64 reverseProxyId = 1; - bytes schedulingJSON = 2; + int64 reverseProxyId = 1; // 反向代理ID + bytes schedulingJSON = 2; // 调度配置 @link json:scheduling } // 修改主要源站信息 message UpdateReverseProxyPrimaryOriginsRequest { - int64 reverseProxyId = 1; - bytes originsJSON = 2; + int64 reverseProxyId = 1; // 反向代理ID + bytes originsJSON = 2; // 源站配置 @link json:origin_refs } // 修改备用源站信息 message UpdateReverseProxyBackupOriginsRequest { - int64 reverseProxyId = 1; - bytes originsJSON = 2; + int64 reverseProxyId = 1; // 反向代理ID + bytes originsJSON = 2; // 源站配置 @link json:origin_refs } // 修改反向代理设置 diff --git a/pkg/rpc/protos/service_user_account.proto b/pkg/rpc/protos/service_user_account.proto index 72b75f5..e0b5193 100644 --- a/pkg/rpc/protos/service_user_account.proto +++ b/pkg/rpc/protos/service_user_account.proto @@ -26,43 +26,43 @@ service UserAccountService { // 计算账户数量 message CountUserAccountsRequest { - string keyword = 1; + string keyword = 1; // 关键词 } // 列出单页账户 message ListUserAccountsRequest { - string keyword = 1; + string keyword = 1; // 关键词 int64 offset = 2; int64 size = 3; } message ListUserAccountsResponse { - repeated UserAccount userAccounts = 1; + repeated UserAccount userAccounts = 1; // 用户账户列表 } // 根据用户ID查找单个账户 message FindEnabledUserAccountWithUserIdRequest { - int64 userId = 1; + int64 userId = 1; // 用户ID } message FindEnabledUserAccountWithUserIdResponse { - UserAccount userAccount = 1; + UserAccount userAccount = 1; // 用户账户 } // 查找单个账户 message FindEnabledUserAccountRequest { - int64 userAccountId = 1; + int64 userAccountId = 1; // 用户账户ID } message FindEnabledUserAccountResponse { - UserAccount userAccount = 1; + UserAccount userAccount = 1; // 用户账户 } // 修改用户账户 message UpdateUserAccountRequest { - int64 userAccountId = 1; - double delta = 2; - string eventType = 3; - string description = 4; - bytes paramsJSON = 5; + int64 userAccountId = 1; // 用户账户ID(非用户ID) + double delta = 2; // 操作的数值,正值表示增加,负值表示减少 + string eventType = 3; // 事件类型:charge, award, buyPlan, payBill, refund, withdraw, buyNSPlan, buyTrafficPackage, buyAntiDDoSPackage, renewAntiDDoSPackage + string description = 4; // 描述 + bytes paramsJSON = 5; // 相关参数 } \ No newline at end of file