This commit is contained in:
邹宗楠
2025-08-14 10:13:30 +08:00
parent e2a9064949
commit a79d9ddec2
3 changed files with 10 additions and 4 deletions

View File

@@ -335,12 +335,18 @@ func (a *API) GetMerchantReportStatus(orgCode, agentNo, externalCustomerNo strin
return nil, err
}
if imgSupplementResp.Code != "200" {
if imgSupplementResp.Code != Success {
return nil, fmt.Errorf(imgSupplementResp.Message)
}
base64DecryData, _ := base64.StdEncoding.DecodeString(imgSupplementResp.Data)
resultData, err := DecryptByPublicKey(base64DecryData, PublicKeyBegin)
if err != nil {
return nil, err
}
openUnionpayMerchantVo := &OpenUnionpayMerchantVo{}
if err = json.Unmarshal([]byte(imgSupplementResp.Data), openUnionpayMerchantVo); err != nil {
if err = json.Unmarshal(resultData, openUnionpayMerchantVo); err != nil {
return nil, err
}