| | |
| | | import com.yami.trading.bean.chat.query.ChatRecordReqModel; |
| | | import com.yami.trading.bean.chat.query.ChatRecordRespModel; |
| | | import com.yami.trading.bean.model.User; |
| | | import com.yami.trading.common.constants.Constants; |
| | | import com.yami.trading.common.domain.Result; |
| | | import com.yami.trading.common.util.DateUtils; |
| | | import com.yami.trading.common.util.StringUtils; |
| | |
| | | String content =null; |
| | | String contentType = onlinechatMessage.getContentType(); |
| | | if ("img".equals(contentType) && !onlinechatMessage.getContent().startsWith("http")){ |
| | | content=awsS3OSSFileService.getUrl(onlinechatMessage.getContent()); |
| | | content= Constants.IMAGES_HTTP+onlinechatMessage.getContent(); |
| | | } else { |
| | | content=onlinechatMessage.getContent(); |
| | | } |
| | |
| | | String content = request.getParameter("content"); |
| | | String type = request.getParameter("type"); |
| | | if (StringUtils.isNullOrEmpty(content.trim()) || StringUtils.isNullOrEmpty(type)) { |
| | | return Result.failed("发送消息为空"); |
| | | return Result.failed("Message cannot be empty"); |
| | | } |
| | | log.info("==========sendsendsendsend======="); |
| | | if(-1>=content.indexOf("%")) content = URLDecoder.decode(content, "utf-8"); |