| | |
| | | import me.zhengjie.modules.temp.service.dto.WechatSendHistoryQueryCriteria; |
| | | import me.zhengjie.modules.temp.service.mapstruct.WechatSendHistoryMapper; |
| | | import me.zhengjie.utils.weixin.WXBizJsonMsgCrypt; |
| | | import org.json.JSONObject; |
| | | import org.json.XML; |
| | | import org.springframework.stereotype.Service; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.data.domain.Page; |
| | |
| | | beforeHistory.setContent(callbackXmlData); |
| | | wechatSendHistoryRepository.save(beforeHistory); |
| | | |
| | | String decryptedMessage = wxcpt.DecryptMsg(msgSignature, timestamp, nonce, callbackXmlData); |
| | | JSONObject json = XML.toJSONObject(callbackXmlData); |
| | | String decryptedMessage = wxcpt.DecryptMsg(msgSignature, timestamp, nonce, json.toString()); |
| | | WechatSendHistory afterHistory = new WechatSendHistory(); |
| | | afterHistory.setContent(decryptedMessage); |
| | | wechatSendHistoryRepository.save(afterHistory); |