Commit fa8ab204 authored by shiyu's avatar shiyu

ai会话

parent 887dc4e9
......@@ -37,13 +37,14 @@ public class IMCallbackController {
public Object getCallbackInfo(@RequestParam(required = false, name = "SdkAppid") String sdkAppid,
@RequestParam(required = false, name = "OptPlatform") String optPlatform,
@RequestParam(required = false, name = "CallbackCommand") String callbackCommand,
@RequestBody(required = false) String jsonStr) {
@RequestBody(required = false) JSONObject jsonObject) {
try {
logger.info("消息发送之后的回调url参数 -> SdkAppid: {}, OptPlatform:{}, CallbackCommand:{}", sdkAppid, optPlatform, callbackCommand);
if (!sdkAppid.equals(String.valueOf(SDKAppID))) {
logger.info(">>>>>>>>>>> IM回调sdkappid 不一致 <<<<<<<<<<<");
return false;
}
String jsonStr = JsonUtils.from(jsonObject);
logger.info("消息发送之后的回调推送原文 -> {}", jsonStr);
ImRecord imRecord = new ImRecord();
//发送消息后回调信息处理
......
......@@ -167,7 +167,7 @@ public class ImServiceImpl implements IMService {
ImRecord answerImRecord = new ImRecord();
answerImRecord.setFromAccount(dto.getToAccount());
answerImRecord.setToAccount(dto.getFromAccount());
imRecord.setMsgKey(answerResult.getData());
answerImRecord.setMsgKey(answerResult.getData());
answerImRecord.setMsgType(IMEnum.MsgTypeEnum.TIMTextElem.getCode());
answerImRecord.setMsgContent(answer);
answerImRecord.setOnlineOnlyFlag(0);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment