f
This commit is contained in:
@@ -34,6 +34,7 @@ type QueryWhitelistEntryResponse struct {
|
||||
APICodes []string `json:"api_codes"`
|
||||
Status string `json:"status"`
|
||||
Remark string `json:"remark"`
|
||||
OperationIP string `json:"operation_ip,omitempty"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
}
|
||||
@@ -51,6 +52,19 @@ type QueryWhitelistImportLegacyResponse struct {
|
||||
Total int `json:"total"`
|
||||
}
|
||||
|
||||
// QueryWhitelistPublicEncryptedRequest 公开接口外层请求(data 为 AES 密文)
|
||||
type QueryWhitelistPublicEncryptedRequest struct {
|
||||
Data string `json:"data" binding:"required"`
|
||||
}
|
||||
|
||||
// QueryWhitelistPublicPayload 公开接口解密后的业务参数(不含 key/access_id,身份由请求头 + 解密成功证明)
|
||||
type QueryWhitelistPublicPayload struct {
|
||||
Name string `json:"name"`
|
||||
IDCard string `json:"id_card"`
|
||||
APICodes []string `json:"api_codes"`
|
||||
Remark string `json:"remark"`
|
||||
}
|
||||
|
||||
func NewQueryWhitelistEntryResponse(entry *entities.QueryWhitelistEntry) QueryWhitelistEntryResponse {
|
||||
apiCodes := []string(entry.APICodes)
|
||||
if apiCodes == nil {
|
||||
@@ -65,6 +79,7 @@ func NewQueryWhitelistEntryResponse(entry *entities.QueryWhitelistEntry) QueryWh
|
||||
APICodes: apiCodes,
|
||||
Status: entry.Status,
|
||||
Remark: entry.Remark,
|
||||
OperationIP: entry.OperationIP,
|
||||
CreatedAt: entry.CreatedAt,
|
||||
UpdatedAt: entry.UpdatedAt,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user