38 lines
826 B
Go
38 lines
826 B
Go
|
package client
|
||
|
|
||
|
import (
|
||
|
"gitlab.com/wpetit/goweb/cli/format"
|
||
|
)
|
||
|
|
||
|
func playerHints(outputMode format.OutputMode) format.Hints {
|
||
|
return format.Hints{
|
||
|
OutputMode: outputMode,
|
||
|
Props: []format.Prop{
|
||
|
format.NewProp("ID", "ID"),
|
||
|
format.NewProp("IPs", "IPs"),
|
||
|
format.NewProp("Port", "Port"),
|
||
|
},
|
||
|
}
|
||
|
}
|
||
|
|
||
|
type wrappedStatus struct {
|
||
|
ID string `json:"id"`
|
||
|
Status string `json:"status"`
|
||
|
URL string `json:"url"`
|
||
|
Title string `json:"title"`
|
||
|
Address string `json:"address"`
|
||
|
}
|
||
|
|
||
|
func wrappedStatusHints(outputMode format.OutputMode) format.Hints {
|
||
|
return format.Hints{
|
||
|
OutputMode: outputMode,
|
||
|
Props: []format.Prop{
|
||
|
format.NewProp("ID", "ID"),
|
||
|
format.NewProp("Address", "Address"),
|
||
|
format.NewProp("Status", "Status"),
|
||
|
format.NewProp("Title", "Title"),
|
||
|
format.NewProp("URL", "URL"),
|
||
|
},
|
||
|
}
|
||
|
}
|