7
0

完善pay项目微信工单图片上传接口、回复接口、完成接口

This commit is contained in:
明炜 卢 2024-06-04 11:24:58 +08:00
parent de3c82cbff
commit e710c3050a
2 changed files with 11 additions and 5 deletions

View File

@ -10,12 +10,12 @@ const (
) )
var HOST requests.Host = requests.Host{ var HOST requests.Host = requests.Host{
Default: "pay.gaore.com", Default: "pay.uu89.com",
Func: func(s string) string { Func: func(s string) string {
var a = map[string]string{ var a = map[string]string{
requests.RELEASE: "pay.gaore.com", requests.RELEASE: "pay.uu89.com",
requests.PRE: "pay.gaore.com", requests.PRE: "pay.uu89.com",
requests.TEST: "pay.gaore.com", requests.TEST: "pay.uu89.com",
} }
return a[s] return a[s]
}, },
@ -25,6 +25,12 @@ type Client struct {
sdk.Client sdk.Client
} }
func NewClient() (client *Client, err error) {
client = new(Client)
err = client.Init()
return
}
func NewClientWithAccessKey(accesskey, secrect, source string) (client *Client, err error) { func NewClientWithAccessKey(accesskey, secrect, source string) (client *Client, err error) {
client = &Client{} client = &Client{}
err = client.InitWithAccessKey(accesskey, secrect, source) err = client.InitWithAccessKey(accesskey, secrect, source)

View File

@ -8,7 +8,7 @@ import (
func TestClient_GetUserInfo(t *testing.T) { func TestClient_GetUserInfo(t *testing.T) {
c, err := NewClientWithAliAppcode("", "") c, err := NewClient()
if err != nil { if err != nil {
t.Error(err) t.Error(err)
} }