18 lines
278 B
Go
18 lines
278 B
Go
package constant
|
|
|
|
import "strconv"
|
|
|
|
type RetBase struct {
|
|
RetCode int `json:"retCode"`
|
|
RetMsg string `json:"retMsg"`
|
|
}
|
|
|
|
func (r *RetBase) Error() string {
|
|
return strconv.Itoa(r.RetCode) + "-" + r.RetMsg
|
|
}
|
|
|
|
type RetData struct {
|
|
RetBase
|
|
Data interface{} `json:"data"`
|
|
}
|