ipsegment

package
v0.0.1-beta3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 7, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ListReq

type ListReq struct {
	Status  string `url:"status,omitempty"`   // 状态搜索
	Node    string `url:"node,omitempty"`     // 节点id(v2.2.2+)
	IpGroup string `url:"ip_group,omitempty"` // IP分组id(v2.2.2+)
	IpName  string `url:"ip_name,omitempty"`  // 搜索名称
	Area    string `url:"area,omitempty"`     // 区域id(v2.4.3+)
	Rid     string `url:"rid,omitempty"`      // 资源包ID(前台用户)

	Page    string `url:"page,omitempty"`     // 分页数,指定当前第几页
	PerPage string `url:"per_page,omitempty"` // 指定当前页面显示条数
	Orderby string `url:"orderby,omitempty"`  // 排序
	Sort    string `url:"sort,omitempty"`     // 指定当前页面显示条数
}

func (*ListReq) Body

func (r *ListReq) Body() any

func (*ListReq) Form

func (r *ListReq) Form() (form url.Values)

func (*ListReq) Header

func (r *ListReq) Header() http.Header

func (*ListReq) Method

func (r *ListReq) Method() string

func (*ListReq) Url

func (r *ListReq) Url() string

func (*ListReq) Values

func (r *ListReq) Values() (values url.Values)

type ListResp

type ListResp struct {
	Data []struct {
		Id         int    `json:"id"`
		IpName     string `json:"ip_name"`
		Gateway    string `json:"gateway"`
		SubnetMask string `json:"subnet_mask"`
		Dns1       string `json:"dns1"`
		Dns2       string `json:"dns2"`
		CreateTime string `json:"create_time"`
		Status     int    `json:"status"`
		NodeIds    string `json:"node_ids"`
		GroupId    int    `json:"group_id"`
		GroupName  string `json:"group_name"`
		Count      struct {
			Free  int `json:"free"`
			Used  int `json:"used"`
			Total int `json:"total"`
			Lock  int `json:"lock"`
		} `json:"count"`
		Node []struct {
			Id   int    `json:"id"`
			Name string `json:"name"`
		} `json:"node"`
	} `json:"data"`
	Meta struct {
		Total     int `json:"total"`
		TotalPage int `json:"total_page"`
		PerPage   int `json:"per_page"`
		Page      int `json:"page"`
	} `json:"meta"`
}

func List

func List(ctx *cloudplatform.Context, req *ListReq) (*ListResp, error)

List 实例列表

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL