This commit is contained in:
邹宗楠
2025-06-30 10:13:46 +08:00
parent 0599a21bce
commit f08b6e11b3
6 changed files with 13 additions and 5 deletions

View File

@@ -49,7 +49,9 @@ func New(appID, serialNo, sM4Key, clientId, clientSecret, incomingToken, changeT
// AccessAPI form表单格式
func (a *API) AccessAPI(baseUrl, action, method string, pathParam string, bizParams map[string]interface{}) (retVal map[string]interface{}, err error) {
a.CheckToken()
if method != TokenActive {
a.CheckToken()
}
err = platformapi.AccessPlatformAPIWithRetry(a.client,
func() *http.Request {
var request *http.Request

View File

@@ -40,7 +40,7 @@ func TestModifiedToken(t *testing.T) {
// TestOrganization 获取城市组织代码
func TestOrganization(t *testing.T) {
// 6510 成都市 6515 金牛
organizationList, err := api.GetOrganizationCode("6510")
organizationList, err := api.GetOrganizationCode("1")
if err != nil {
globals.SugarLogger.Debugf("err := %v", err)
} else {