- jd storepage GetStoreOrderInfo add param stationNo
This commit is contained in:
@@ -66,16 +66,20 @@ func (a *API) AccessStorePage(subURL string) (retVal map[string]interface{}, err
|
||||
return retVal, err
|
||||
}
|
||||
|
||||
func (a *API) GetRealMobile4Order(orderId string) (mobile string, err error) {
|
||||
retVal, err := a.GetStoreOrderInfo(orderId)
|
||||
func (a *API) GetRealMobile4Order(orderId, stationNo string) (mobile string, err error) {
|
||||
retVal, err := a.GetStoreOrderInfo(orderId, stationNo)
|
||||
if err == nil {
|
||||
return retVal["mobile"].(string), nil
|
||||
}
|
||||
return "", err
|
||||
}
|
||||
|
||||
func (a *API) GetStoreOrderInfo(orderId string) (storeOrderInfo map[string]interface{}, err error) {
|
||||
retVal, err := a.AccessStorePage(fmt.Sprintf("order/newManager/search?pageNo=1&pageSize=1&orderBy=&desc=true¶m=%s&stationNo=", orderId))
|
||||
func (a *API) GetStoreOrderInfo(orderId, stationNo string) (storeOrderInfo map[string]interface{}, err error) {
|
||||
urlStr := "order/newManager/search?pageNo=1&pageSize=1&orderBy=&desc=true¶m=" + orderId
|
||||
if stationNo != "" {
|
||||
urlStr += "&stationNo=" + stationNo
|
||||
}
|
||||
retVal, err := a.AccessStorePage(urlStr)
|
||||
// baseapi.SugarLogger.Debug(utils.Format4Output(retVal, false))
|
||||
if err == nil {
|
||||
newOrderinfoMains := retVal["result"].(map[string]interface{})["newOrderinfoMains"].(map[string]interface{})
|
||||
|
||||
Reference in New Issue
Block a user