|
@@ -583,19 +583,31 @@ public class SocialServiceImpl implements SocialServiceI {
|
583
|
583
|
public ResponseBean addTransactionReply(String paramets, UserElement userElement) {
|
584
|
584
|
ResponseBean response = new ResponseBean();
|
585
|
585
|
JSONObject object = JSONObject.parseObject(paramets);
|
|
586
|
+ Integer state = object.getInteger("state");
|
|
587
|
+ TpUser tpUser = tpUserMapper.selectLoginName(userElement.getLoginName(),userElement.getCommunityId());
|
586
|
588
|
JSONArray array = object.getJSONArray("imgArr");
|
587
|
589
|
String[] reply = null;
|
588
|
590
|
if (null != array) {
|
589
|
591
|
reply = array.toArray(new String[]{});
|
590
|
592
|
}
|
591
|
593
|
TaUserVerify taUserVerify= taUserVerifyMapper.selectByPrimaryKey(userElement.getUserVerifyId());
|
592
|
|
- TpTransactionReply tpTransactionReply = JSONObject.parseObject(paramets, TpTransactionReply.class);
|
593
|
|
- tpTransactionReply.setCommunityId(userElement.getCommunityId());
|
594
|
|
- tpTransactionReply.setUuid(userElement.getUserVerifyId());
|
595
|
|
- tpTransactionReply.setUuidType("app");
|
596
|
|
- tpTransactionReply.setUuidName(userElement.getUserName());
|
597
|
|
- tpTransactionReply.setUuidRole(taSysRoleMapper.selectByPrimaryKey(taUserVerify.getRoleId()).getDescription());
|
598
|
594
|
|
|
595
|
+ TpTransactionReply tpTransactionReply = JSONObject.parseObject(paramets, TpTransactionReply.class);
|
|
596
|
+ // 我1时代表物业端身份评论
|
|
597
|
+ int current = state.intValue();
|
|
598
|
+ if (1==current){
|
|
599
|
+ tpTransactionReply.setCommunityId(userElement.getCommunityId());
|
|
600
|
+ tpTransactionReply.setUuid( tpUser.getId());
|
|
601
|
+ tpTransactionReply.setUuidType("prop");
|
|
602
|
+ tpTransactionReply.setUuidName(tpUser.getUserName());
|
|
603
|
+ tpTransactionReply.setUuidRole("物业");
|
|
604
|
+ }else {
|
|
605
|
+ tpTransactionReply.setCommunityId(userElement.getCommunityId());
|
|
606
|
+ tpTransactionReply.setUuid(userElement.getUserVerifyId());
|
|
607
|
+ tpTransactionReply.setUuidType("app");
|
|
608
|
+ tpTransactionReply.setUuidName(userElement.getUserName());
|
|
609
|
+ tpTransactionReply.setUuidRole(taSysRoleMapper.selectByPrimaryKey(taUserVerify.getRoleId()).getDescription());
|
|
610
|
+ }
|
599
|
611
|
TpTransactionReply tpTransactionReplyBack = new TpTransactionReply();
|
600
|
612
|
TpTransaction tpTransaction = new TpTransaction();
|
601
|
613
|
//replyId为空的情况下被回复人就是帖子的创建人
|