This commit is contained in:
jiangyong 2023-08-27 17:09:57 +08:00
parent f1b590f676
commit aff454cda3
1 changed files with 7 additions and 3 deletions

View File

@ -69,13 +69,17 @@ func (s *SyncOrder) run() {
}
cipherText := cast.ToString(result["data"])
datas, err := common.Decrypt(cipherText, s.token)
originText, err := common.Decrypt(cipherText, s.token)
if err != nil {
log.Errorf("common.Decrypt error :%s", err.Error())
return
}
for _, d := range datas {
var arrs []interface{}
if err := json.Unmarshal([]byte(originText), arrs); err != nil {
log.Errorf("json.Unmarsha error :%s", err.Error())
return
}
for _, d := range arrs {
data := cast.ToStringMap(d)
id := cast.ToInt64(data["id"])
order, err := model.GetOrder(id)