|
|
@ -91,10 +91,12 @@ import com.epmet.resi.group.dto.topic.result.GovTopicIssueInfoResultDTO; |
|
|
|
import com.epmet.resi.group.dto.topic.result.*; |
|
|
|
import com.github.pagehelper.PageHelper; |
|
|
|
import com.github.pagehelper.PageInfo; |
|
|
|
import com.google.common.base.CharMatcher; |
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
|
import org.apache.commons.logging.Log; |
|
|
|
import org.apache.commons.logging.LogFactory; |
|
|
|
import org.jsoup.helper.StringUtil; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.beans.factory.annotation.Value; |
|
|
|
import org.springframework.stereotype.Service; |
|
|
@ -1598,14 +1600,14 @@ public class ResiTopicServiceImpl extends BaseServiceImpl<ResiTopicDao, ResiTopi |
|
|
|
pointEventMsg.setIsCommon(false); |
|
|
|
|
|
|
|
//某某小组中发布的话题“某某某…” (前十个字后面省略号) 被转为议题
|
|
|
|
|
|
|
|
String content = CharMatcher.WHITESPACE.trimFrom(topic.getTopicContent()); |
|
|
|
pointEventMsg.setRemark(new StringBuilder(groupCache.getGroupName()).append("小组中发布的") |
|
|
|
.append( |
|
|
|
StringUtils.isBlank(topic.getTopicContent()) ? "语音话题" : |
|
|
|
StringUtils.isBlank(content) ? "语音话题" : |
|
|
|
"\"" + |
|
|
|
topic.getTopicContent() |
|
|
|
.substring(topic.getTopicContent().length() < NumConstant.TEN ? topic.getTopicContent().length() : NumConstant.TEN) |
|
|
|
+ (NumConstant.TEN > topic.getTopicContent().length() ? "\"" : "…\"") |
|
|
|
content |
|
|
|
.substring(NumConstant.ZERO,content.length() < NumConstant.TEN ? content.length() : NumConstant.TEN) |
|
|
|
+ (NumConstant.TEN > content.length() ? "\"" : "…\"") |
|
|
|
).append("被转为议题").toString()); |
|
|
|
pointEventMsgList.add(pointEventMsg); |
|
|
|
|
|
|
@ -1619,11 +1621,10 @@ public class ResiTopicServiceImpl extends BaseServiceImpl<ResiTopicDao, ResiTopi |
|
|
|
//将话题“某某某…” (前十个字后面省略号) 转为议题
|
|
|
|
pointEventMsg2.setRemark(new StringBuilder("将话题") |
|
|
|
.append( |
|
|
|
"\"" + |
|
|
|
topic.getTopicContent() |
|
|
|
.substring(topic.getTopicContent().length() < NumConstant.TEN ? topic.getTopicContent().length() : NumConstant.TEN) |
|
|
|
+ (NumConstant.TEN > topic.getTopicContent().length() ? "\"" : "…\"") |
|
|
|
).append("转为议题").toString()); |
|
|
|
new StringBuilder(new StringBuilder(pointEventMsg.getRemark().replaceFirst("小组中发布的","")) |
|
|
|
.reverse().toString() |
|
|
|
.replaceFirst("题议为转被","")).reverse() |
|
|
|
).append("转为议题").toString()); |
|
|
|
pointEventMsgList.add(pointEventMsg2); |
|
|
|
|
|
|
|
mqBaseMsgDTO.setMsg(JSON.toJSONString(pointEventMsgList)); |
|
|
@ -1733,14 +1734,14 @@ public class ResiTopicServiceImpl extends BaseServiceImpl<ResiTopicDao, ResiTopi |
|
|
|
pointEventMsg.setIsCommon(false); |
|
|
|
pointEventMsg.setEventTag(EventEnum.TOPIC_SHIFTED_TO_ISSUE.getEventTag()); |
|
|
|
//某某小组中发布的话题“某某某…” (前十个字后面省略号) 被转为议题
|
|
|
|
|
|
|
|
String content = CharMatcher.WHITESPACE.trimFrom(topic.getTopicContent()); |
|
|
|
pointEventMsg.setRemark(new StringBuilder(groupCache.getGroupName()).append("小组中发布的") |
|
|
|
.append( |
|
|
|
StringUtils.isBlank(topic.getTopicContent()) ? "语音话题" : |
|
|
|
StringUtils.isBlank(content) ? "语音话题" : |
|
|
|
"\"" + |
|
|
|
topic.getTopicContent() |
|
|
|
.substring(topic.getTopicContent().length() < NumConstant.TEN ? topic.getTopicContent().length() : NumConstant.TEN) |
|
|
|
+ (NumConstant.TEN > topic.getTopicContent().length() ? "\"" : "…\"") |
|
|
|
content |
|
|
|
.substring(NumConstant.ZERO,content.length() < NumConstant.TEN ? content.length() : NumConstant.TEN) |
|
|
|
+ (NumConstant.TEN > content.length() ? "\"" : "…\"") |
|
|
|
).append("被转为议题").toString()); |
|
|
|
pointEventMsgList.add(pointEventMsg); |
|
|
|
|
|
|
@ -1754,10 +1755,8 @@ public class ResiTopicServiceImpl extends BaseServiceImpl<ResiTopicDao, ResiTopi |
|
|
|
//将话题“某某某…” (前十个字后面省略号) 转为议题
|
|
|
|
pointEventMsg2.setRemark(new StringBuilder("将话题") |
|
|
|
.append( |
|
|
|
"\"" + |
|
|
|
topic.getTopicContent() |
|
|
|
.substring(topic.getTopicContent().length() < NumConstant.TEN ? topic.getTopicContent().length() : NumConstant.TEN) |
|
|
|
+ (NumConstant.TEN > topic.getTopicContent().length() ? "\"" : "…\"") |
|
|
|
new StringBuilder(new StringBuilder(pointEventMsg.getRemark().replaceFirst("小组中发布的","")).reverse() |
|
|
|
.toString().replaceFirst("题议为转被","")).reverse() |
|
|
|
).append("转为议题").toString()); |
|
|
|
pointEventMsgList.add(pointEventMsg2); |
|
|
|
|
|
|
@ -1768,7 +1767,6 @@ public class ResiTopicServiceImpl extends BaseServiceImpl<ResiTopicDao, ResiTopi |
|
|
|
} |
|
|
|
return issueInfo; |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* @Description 政府端查看议题详情时的话题相关信息 |
|
|
|
* @param govTopicIssueInfoFormDTO |
|
|
|