Compare commits
No commits in common. "9fbd72fa16eb60ef76e7bf9100a8df71d76a3216" and "3957f3b5b90100af06d7714de8a11d1a104dce41" have entirely different histories.
9fbd72fa16
...
3957f3b5b9
@ -19,7 +19,7 @@ func setupMockServer(path string, method string, response string, t *testing.T)
|
|||||||
}
|
}
|
||||||
|
|
||||||
func newClientWithServer(ts *httptest.Server) *wps.WeiPinShangClient {
|
func newClientWithServer(ts *httptest.Server) *wps.WeiPinShangClient {
|
||||||
return wps.NewWeiPinShangClient(wps.WpsConfig{
|
return wps.NewWeiPinShangClient(wps.Config{
|
||||||
BaseURL: wps.DevHost,
|
BaseURL: wps.DevHost,
|
||||||
ChannelType: "AILEHUI",
|
ChannelType: "AILEHUI",
|
||||||
Key: "f654ea5bde7635c3f46191191e5c4c8e",
|
Key: "f654ea5bde7635c3f46191191e5c4c8e",
|
||||||
|
@ -112,7 +112,7 @@ type GetGoodsdeptRes struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Goodsdept struct {
|
type Goodsdept struct {
|
||||||
PageIndex interface{} `json:"pageIndex"`
|
PageIndex string `json:"pageIndex"`
|
||||||
PageCount int `json:"pageCount"`
|
PageCount int `json:"pageCount"`
|
||||||
DataCount int `json:"dataCount"`
|
DataCount int `json:"dataCount"`
|
||||||
List []Goods `json:"list"`
|
List []Goods `json:"list"`
|
||||||
|
@ -32,7 +32,7 @@ const (
|
|||||||
)
|
)
|
||||||
|
|
||||||
// Config 客户端配置
|
// Config 客户端配置
|
||||||
type WpsConfig struct {
|
type Config struct {
|
||||||
ChannelType string
|
ChannelType string
|
||||||
Key string
|
Key string
|
||||||
BaseURL string
|
BaseURL string
|
||||||
@ -48,7 +48,7 @@ type WeiPinShangClient struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// NewWeiPinShangClient 创建客户端
|
// NewWeiPinShangClient 创建客户端
|
||||||
func NewWeiPinShangClient(cfg WpsConfig) *WeiPinShangClient {
|
func NewWeiPinShangClient(cfg Config) *WeiPinShangClient {
|
||||||
if cfg.ChannelType == "" {
|
if cfg.ChannelType == "" {
|
||||||
cfg.ChannelType = "AILEHUI"
|
cfg.ChannelType = "AILEHUI"
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user