Commit f434ad0a by 孙喜旺

新增全文检索导出列表接口

1 parent ed2d44d6
......@@ -153,4 +153,17 @@ public class WeChatContactMsgController extends BaseController {
List<WeChatContactMsgVo> list = iWeChatContactMsgService.selectFullSearchChatList(weChatContactMsg);
return getDataTable(list);
}
/**
* 全文检索 会话列表
*/
@ApiOperation("全文检索 导出列表")
@Log(title = "全文检索 导出列表" , businessType = BusinessType.OTHER)
@GetMapping("/selectFullSearchChatList/export" )
public AjaxResult fullSearchChatListExport(WeChatContactMsg weChatContactMsg) {
startPage();
List<WeChatContactMsgVo> list = iWeChatContactMsgService.selectFullSearchChatList(weChatContactMsg);
ExcelUtil<WeChatContactMsgVo> util = new ExcelUtil<WeChatContactMsgVo>(WeChatContactMsgVo.class);
return util.exportExcel(list, "msg" );
}
}
package com.linkwechat.wecom.domain.vo;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.linkwechat.common.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
......@@ -22,22 +23,28 @@ public class WeChatContactMsgVo {
@ApiModelProperty("发送人人id")
private String fromId;
@Excel(name = "名称")
@ApiModelProperty("名称")
private String name;
@Excel(name = "头像")
@ApiModelProperty("头像")
private String avatar;
@Excel(name = "发送时间")
@ApiModelProperty("消息发送时间")
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
private Date msgTime;
@Excel(name = "消息类型")
@ApiModelProperty("消息类型(如:文本,图片)")
private String msgType;
@Excel(name = "发送类型")
@ApiModelProperty("消息类型(send(发送消息)/recall(撤回消息)/switch(切换企业日志))")
private String action;
@Excel(name = "消息内容")
@ApiModelProperty("消息内容")
private String contact;
}
......@@ -8,7 +8,9 @@
<select id="selectWeGroupList" parameterType="WeGroup" resultType="com.linkwechat.wecom.domain.WeGroup">
SELECT
wg.chat_id,
wg.group_name,
if(wg.group_name = '' or wg.group_name is null,
(SELECT group_concat(name separator '、') FROM we_group_member wgm WHERE wgm.chat_id = wg.chat_id limit 10),
wg.group_name) as group_name,
wg.add_time,
wg.notice,
wu.user_name as groupLeaderName,
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!