This commit is contained in:
邹宗楠
2025-01-06 14:34:52 +08:00
parent e802a3eebc
commit c73357624e
6 changed files with 57 additions and 34 deletions

View File

@@ -2,7 +2,6 @@ package controllers
import (
"encoding/json"
"fmt"
"git.rosy.net.cn/baseapi/platformapi/mtwmapi"
"git.rosy.net.cn/baseapi/utils"
"git.rosy.net.cn/jx-callback/business/model"
@@ -190,10 +189,10 @@ func pushMTWMOrder2GY(value url.Values, msgType string, serverType string) *mtwm
return mtwmapi.Err2CallbackResponse(err, "")
}
defer resp.Body.Close()
byteData, err := ioutil.ReadAll(resp.Body)
if err != nil {
return mtwmapi.Err2CallbackResponse(err, "")
}
fmt.Println(string(byteData))
return mtwmapi.Err2CallbackResponse(err, "")
byteData, _ := ioutil.ReadAll(resp.Body)
result := mtwmapi.CallbackResponse{}
json.Unmarshal(byteData, &result)
return &result
}