feat: 设备编号从 00000001 顺序分配
This commit is contained in:
@@ -46,13 +46,13 @@ type Endpoint struct {
|
||||
Found bool
|
||||
}
|
||||
|
||||
func (c *Client) CreateEndpoint(ctx context.Context, name string) (Endpoint, error) {
|
||||
func (c *Client) CreateEndpoint(ctx context.Context, id, name string) (Endpoint, error) {
|
||||
var out struct {
|
||||
ID string `json:"id"`
|
||||
LoginPassword string `json:"login_password"`
|
||||
}
|
||||
err := c.call(ctx, http.MethodPost, "/api/admin/endpoints", map[string]any{
|
||||
"id": "",
|
||||
"id": id,
|
||||
"name": name,
|
||||
"remark": "",
|
||||
"login_password": "",
|
||||
|
||||
Reference in New Issue
Block a user