-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
IndexDoge
authored and
IndexDoge
committed
Mar 21, 2022
1 parent
c03133e
commit 3be6250
Showing
6 changed files
with
120 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,7 +26,7 @@ jobs: | |
- name: Set up Go | ||
uses: actions/[email protected] | ||
with: | ||
go-version: '1.16' | ||
go-version: '1.18' | ||
id: go | ||
|
||
- name: Check out code into the Go module directory | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
package types | ||
|
||
type NodeModal struct { | ||
Id int64 `json:"id"` | ||
Name string `json:"name"` | ||
Type bool `json:"type"` | ||
Server string `json:"server"` | ||
Info string `json:"info"` | ||
Status string `json:"status"` | ||
Sort int `json:"sort"` | ||
TrafficRate float64 `json:"traffic_rate"` | ||
Class int64 `json:"node_class"` | ||
SpeedLimit int64 `json:"node_speedlimit"` | ||
Connector int64 `json:"node_connector"` | ||
Bandwidth int64 `json:"node_bandwidth"` | ||
BandwidthLimit int64 `json:"node_bandwidth_limit"` | ||
BandwidthResetDay int `json:"bandwidthlimit_resetday"` | ||
Heartbeat int `json:"node_heartbeat"` | ||
IP string `json:"node_ip"` | ||
Group int64 `json:"node_group"` | ||
MuType int `json:"mu_only"` | ||
Online int `json:"online"` | ||
GFWBlock int `json:"gfw_block"` | ||
|
||
// String stored JSON | ||
CustomConfig string `json:"custom_config"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package types | ||
|
||
const ( | ||
StatusFailure int = 0 | ||
StatusOk = 1 | ||
) | ||
|
||
type ApiResponse struct { | ||
StatusCode int `json:"ret"` | ||
Msg string `json:"msg"` | ||
} | ||
|
||
type ReadNodeInfoResponse struct { | ||
ApiResponse | ||
Node NodeModal `json:"node"` | ||
} |