2025-03-07 17:23:50 +08:00

45 lines
2.1 KiB
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package requests
type PlatformRequest struct {
GetPlatformPage // 获取列表-分页
GetPlatformList // 获取列表
PutPlatformStatus // 操作状态
AddPlatform // 新增
PutPlatform // 修改
}
// GetPlatformPage 获取列表-分页
type GetPlatformPage struct {
Page int `json:"page" form:"page" label:"页码"`
PageSize int `json:"page_size" form:"page_size" label:"每页个数"`
PlatformName string `json:"platform_name" form:"platform_name" label:"平台名称"`
PlatformStatus *int `json:"platform_status" form:"platform_status" label:"状态1:正常 2:禁用)" validate:"omitempty,oneof=1 2"`
}
// GetPlatformList 获取列表
type GetPlatformList struct {
PlatformName string `json:"platform_name" form:"platform_name" label:"平台名称"`
PlatformStatus *int `json:"platform_status" form:"platform_status" label:"状态1:正常 2:禁用)" validate:"omitempty,oneof=1 2"`
}
// PutPlatform 修改
type PutPlatform struct {
PlatformName string `json:"platform_name" form:"platform_name" label:"平台名称" validate:"required"`
PlatformStatus int `json:"platform_status" form:"platform_status" label:"平台状态" validate:"required,oneof=1 2"`
PlatformKey string `json:"platform_key" form:"platform_key" label:"平台标识" validate:"required"`
PlatformSecret string `json:"platform_secret" form:"platform_secret" label:"平台密钥" validate:"required"`
}
// PutPlatformStatus 操作状态
type PutPlatformStatus struct {
PlatformStatus int `json:"platform_status" form:"platform_status" label:"状态1:正常 2:禁用)" validate:"omitempty,oneof=1 2"`
}
// AddPlatform 新增
type AddPlatform struct {
PlatformName string `json:"platform_name" form:"platform_name" label:"平台名称" validate:"required"`
PlatformStatus int `json:"platform_status" form:"platform_status" label:"状态1:正常 2:禁用)" validate:"required,oneof=1 2"`
PlatformKey string `json:"platform_key" form:"platform_key" label:"平台标识" validate:"required"`
PlatformSecret string `json:"platform_secret" form:"platform_secret" label:"平台密钥" validate:"required"`
}