1
This commit is contained in:
@@ -7,7 +7,6 @@ import (
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
"git.rosy.net.cn/jx-callback/globals"
|
||||
"net/http"
|
||||
"reflect"
|
||||
"sort"
|
||||
@@ -205,12 +204,9 @@ func (a *API) AccessAPI2(apiStr string, jdParams map[string]interface{}, traceIn
|
||||
var request *http.Request
|
||||
if userGet {
|
||||
fullURL := utils.GenerateGetURL(a.baseURL, apiStr, params)
|
||||
// baseapi.SugarLogger.Debug(fullURL)
|
||||
request, _ = http.NewRequest(http.MethodGet, fullURL, nil)
|
||||
} else {
|
||||
fullURL := utils.GenerateGetURL(a.baseURL, apiStr, nil)
|
||||
// baseapi.SugarLogger.Debug(utils.Map2URLValues(params).Encode())
|
||||
globals.SugarLogger.Debugf("-----paramsparams- :%s", utils.Format4Output(params, false))
|
||||
request, _ = http.NewRequest(http.MethodPost, fullURL, strings.NewReader(utils.Map2URLValues(params).Encode()))
|
||||
request.Header.Set("charset", "UTF-8")
|
||||
request.Header.Set("Content-Type", "application/x-www-form-urlencoded")
|
||||
|
||||
@@ -51,19 +51,18 @@ func TestGetStoreInfoByStationNo(t *testing.T) {
|
||||
|
||||
func TestUpdateStoreInfo4Open(t *testing.T) {
|
||||
params := &OpStoreParams{
|
||||
StationNo: "12664100",
|
||||
StationName: "旺佳超市",
|
||||
OutSystemID: "668836",
|
||||
Mobile: "17751816719",
|
||||
Phone: "17751816719",
|
||||
Lat: 43.622098,
|
||||
Lng: 122.275918,
|
||||
City: 902,
|
||||
County: 32769,
|
||||
StationAddress: "内蒙古自治区通辽市科尔沁区百花新城",
|
||||
Operator: "18981810340",
|
||||
ServiceTimeEnd1: 44,
|
||||
ServiceTimeStart1: 14,
|
||||
StationNo: "11890095",
|
||||
OutSystemID: "100654",
|
||||
Mobile: "18123353875",
|
||||
Phone: "18123353875",
|
||||
Lat: 30.745945,
|
||||
Lng: 103.987782,
|
||||
City: 1930,
|
||||
County: 49322,
|
||||
StationAddress: "郫都区成都市郫都区犀浦镇华都大道东一段330号1层连心菜市场34号",
|
||||
Operator: "jxadmin-18981810340",
|
||||
ServiceTimeEnd1: 38,
|
||||
ServiceTimeStart1: 16,
|
||||
CoordinateType: 3,
|
||||
CloseStatus: 0,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user