wangmiaomiao пре 10 месеци
родитељ
комит
ddb6a72c02

+ 46 - 6
slibra-admin/src/main/java/com/slibra/web/controller/business/FrontController.java

@@ -1,14 +1,16 @@
 package com.slibra.web.controller.business;
 
 import com.google.protobuf.ByteString;
-import com.slibra.business.mapper.TXinyiDailyMapper;
-import com.slibra.business.mapper.TXinyiIndustryMapper;
-import com.slibra.business.mapper.TXinyiNormConfigMapper;
-import com.slibra.business.mapper.TXinyiRobotMapper;
+import com.slibra.business.domain.TXinyiChatRecord;
+import com.slibra.business.mapper.*;
 import com.slibra.business.res.XinyiIndustrySimple;
 import com.slibra.business.service.IFrontService;
 import com.slibra.common.core.controller.BaseController;
 import com.slibra.common.core.domain.AjaxResult;
+import com.slibra.common.core.page.TableDataInfo;
+import com.slibra.common.exception.ServiceException;
+import com.slibra.common.utils.SecurityUtils;
+import com.slibra.common.utils.StringUtils;
 import io.grpc.ManagedChannel;
 import io.grpc.ManagedChannelBuilder;
 import lombok.extern.slf4j.Slf4j;
@@ -26,12 +28,13 @@ import java.io.OutputStream;
 import java.io.UnsupportedEncodingException;
 import java.nio.charset.StandardCharsets;
 import java.util.Iterator;
+import java.util.List;
 
 /**
- * 告警相关
+ * 前端用户相关接口
  */
 @RestController
-@RequestMapping("/test")
+@RequestMapping("/front")
 @Slf4j
 public class FrontController extends BaseController {
 
@@ -40,6 +43,9 @@ public class FrontController extends BaseController {
     private IFrontService frontService;
 
 
+    @Autowired
+    private TXinyiChatRecordMapper tXinyiChatRecordMapper;
+
 
 
     /**
@@ -54,6 +60,40 @@ public class FrontController extends BaseController {
     }
 
 
+    /**
+     * 分页获取大模型的问答记录
+     * @param tXinyiChatRecord
+     * @return
+     */
+    @GetMapping("/bigmodel/qa/list")
+    public TableDataInfo qaPageList(TXinyiChatRecord tXinyiChatRecord)
+    {
+        //获取登录用户信息
+        Long userId = SecurityUtils.getUserId();
+        tXinyiChatRecord.setUserId(String.valueOf(userId));
+        startPage();
+        return getDataTable(tXinyiChatRecordMapper.selectTXinyiChatRecordFirstList(tXinyiChatRecord));
+    }
+
+
+
+    /**
+     * 通过sessionId获取某个用户的问答列表
+     * @param tXinyiChatRecord
+     * @return
+     */
+    @GetMapping("/bigmodel/qa/list")
+    public List<TXinyiChatRecord> qaListBySessionId(TXinyiChatRecord tXinyiChatRecord)
+    {
+        String sessionId = tXinyiChatRecord.getSessionId();
+        if(StringUtils.isBlank(sessionId))
+            throw new ServiceException("必须传入sessionId");
+        //获取登录用户信息
+        Long userId = SecurityUtils.getUserId();
+        tXinyiChatRecord.setUserId(String.valueOf(userId));
+        return tXinyiChatRecordMapper.selectTXinyiChatRecordFirstList(tXinyiChatRecord);
+    }
+
 
 
 

+ 106 - 0
slibra-admin/src/main/java/com/slibra/web/controller/business/TXinyiChatRecordController.java

@@ -0,0 +1,106 @@
+package com.slibra.web.controller.business;
+
+import java.util.List;
+import javax.servlet.http.HttpServletResponse;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.DeleteMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.slibra.common.annotation.Log;
+import com.slibra.common.core.controller.BaseController;
+import com.slibra.common.core.domain.AjaxResult;
+import com.slibra.common.enums.BusinessType;
+import com.slibra.business.domain.TXinyiChatRecord;
+import com.slibra.business.service.ITXinyiChatRecordService;
+import com.slibra.common.utils.poi.ExcelUtil;
+import com.slibra.common.core.page.TableDataInfo;
+
+/**
+ * 信义大模型问答记录Controller
+ * 
+ * @author slibra
+ * @date 2024-05-15
+ */
+@RestController
+@RequestMapping("/business/record")
+public class TXinyiChatRecordController extends BaseController
+{
+    @Autowired
+    private ITXinyiChatRecordService tXinyiChatRecordService;
+
+    /**
+     * 查询信义大模型问答记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('business:record:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(TXinyiChatRecord tXinyiChatRecord)
+    {
+        startPage();
+        List<TXinyiChatRecord> list = tXinyiChatRecordService.selectTXinyiChatRecordList(tXinyiChatRecord);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出信义大模型问答记录列表
+     */
+    @PreAuthorize("@ss.hasPermi('business:record:export')")
+    @Log(title = "信义大模型问答记录", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, TXinyiChatRecord tXinyiChatRecord)
+    {
+        List<TXinyiChatRecord> list = tXinyiChatRecordService.selectTXinyiChatRecordList(tXinyiChatRecord);
+        ExcelUtil<TXinyiChatRecord> util = new ExcelUtil<TXinyiChatRecord>(TXinyiChatRecord.class);
+        util.exportExcel(response, list, "信义大模型问答记录数据");
+    }
+
+    /**
+     * 获取信义大模型问答记录详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('business:record:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return success(tXinyiChatRecordService.selectTXinyiChatRecordById(id));
+    }
+
+    /**
+     * 新增信义大模型问答记录
+     */
+    @PreAuthorize("@ss.hasPermi('business:record:add')")
+    @Log(title = "信义大模型问答记录", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody TXinyiChatRecord tXinyiChatRecord)
+    {
+        tXinyiChatRecord.setCreateBy(getUsername());
+        return toAjax(tXinyiChatRecordService.insertTXinyiChatRecord(tXinyiChatRecord));
+    }
+
+    /**
+     * 修改信义大模型问答记录
+     */
+    @PreAuthorize("@ss.hasPermi('business:record:edit')")
+    @Log(title = "信义大模型问答记录", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody TXinyiChatRecord tXinyiChatRecord)
+    {
+        tXinyiChatRecord.setUpdateBy(getUsername());
+        return toAjax(tXinyiChatRecordService.updateTXinyiChatRecord(tXinyiChatRecord));
+    }
+
+    /**
+     * 删除信义大模型问答记录
+     */
+    @PreAuthorize("@ss.hasPermi('business:record:remove')")
+    @Log(title = "信义大模型问答记录", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(tXinyiChatRecordService.deleteTXinyiChatRecordByIds(ids));
+    }
+}

+ 68 - 0
slibra-system/src/main/java/com/slibra/business/domain/TXinyiChatRecord.java

@@ -0,0 +1,68 @@
+package com.slibra.business.domain;
+
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+import com.slibra.common.annotation.Excel;
+import com.slibra.common.core.domain.BaseEntity;
+
+/**
+ * 信义大模型问答记录对象 t_xinyi_chat_record
+ * 
+ * @author slibra
+ * @date 2024-05-15
+ */
+@Data
+@Builder
+@AllArgsConstructor
+@NoArgsConstructor
+public class TXinyiChatRecord extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long id;
+
+    /** 会话ID */
+    @Excel(name = "会话ID")
+    private String sessionId;
+
+    /** 类型(0普通问答 1rag问答 2决策) */
+    @Excel(name = "类型", readConverterExp = "0=普通问答,1=rag问答,2=决策")
+    private Long type;
+
+    /** 隶属哪个模块(0专家问答 1智能工单 2智能体助手) */
+    @Excel(name = "隶属哪个模块", readConverterExp = "0=专家问答,1=智能工单,2=智能体助手")
+    private String module;
+
+    /** 用户ID */
+    @Excel(name = "用户ID")
+    private String userId;
+
+    /** 用户提问 */
+    @Excel(name = "用户提问")
+    private String ask;
+
+    /** 大模型回答 */
+    @Excel(name = "大模型回答")
+    private String answer;
+
+    /** 告警记录ID */
+    @Excel(name = "告警记录ID")
+    private String warningId;
+
+    /** 问答次数 */
+    @Excel(name = "问答次数")
+    private Long counts;
+
+    /** 删除标志(0代表存在 2代表删除) */
+    private Long delFlag;
+
+    /** 乐观锁 */
+    @Excel(name = "乐观锁")
+    private Long revision;
+
+}

+ 72 - 0
slibra-system/src/main/java/com/slibra/business/mapper/TXinyiChatRecordMapper.java

@@ -0,0 +1,72 @@
+package com.slibra.business.mapper;
+
+import java.util.List;
+import com.slibra.business.domain.TXinyiChatRecord;
+
+/**
+ * 信义大模型问答记录Mapper接口
+ * 
+ * @author slibra
+ * @date 2024-05-15
+ */
+public interface TXinyiChatRecordMapper 
+{
+    /**
+     * 查询信义大模型问答记录
+     * 
+     * @param id 信义大模型问答记录主键
+     * @return 信义大模型问答记录
+     */
+    public TXinyiChatRecord selectTXinyiChatRecordById(Long id);
+
+    /**
+     * 查询信义大模型问答记录列表
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 信义大模型问答记录集合
+     */
+    public List<TXinyiChatRecord> selectTXinyiChatRecordList(TXinyiChatRecord tXinyiChatRecord);
+
+    /**
+     * 新增信义大模型问答记录
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 结果
+     */
+    public int insertTXinyiChatRecord(TXinyiChatRecord tXinyiChatRecord);
+
+    /**
+     * 修改信义大模型问答记录
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 结果
+     */
+    public int updateTXinyiChatRecord(TXinyiChatRecord tXinyiChatRecord);
+
+    /**
+     * 删除信义大模型问答记录
+     * 
+     * @param id 信义大模型问答记录主键
+     * @return 结果
+     */
+    public int deleteTXinyiChatRecordById(Long id);
+
+    /**
+     * 批量删除信义大模型问答记录
+     * 
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteTXinyiChatRecordByIds(Long[] ids);
+
+
+
+    //----下面是新增的----
+    /**
+     * 查询信义大模型问答记录列表
+     *
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 信义大模型问答记录集合
+     */
+    public List<TXinyiChatRecord> selectTXinyiChatRecordFirstList(TXinyiChatRecord tXinyiChatRecord);
+}

+ 61 - 0
slibra-system/src/main/java/com/slibra/business/service/ITXinyiChatRecordService.java

@@ -0,0 +1,61 @@
+package com.slibra.business.service;
+
+import java.util.List;
+import com.slibra.business.domain.TXinyiChatRecord;
+
+/**
+ * 信义大模型问答记录Service接口
+ * 
+ * @author slibra
+ * @date 2024-05-15
+ */
+public interface ITXinyiChatRecordService 
+{
+    /**
+     * 查询信义大模型问答记录
+     * 
+     * @param id 信义大模型问答记录主键
+     * @return 信义大模型问答记录
+     */
+    public TXinyiChatRecord selectTXinyiChatRecordById(Long id);
+
+    /**
+     * 查询信义大模型问答记录列表
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 信义大模型问答记录集合
+     */
+    public List<TXinyiChatRecord> selectTXinyiChatRecordList(TXinyiChatRecord tXinyiChatRecord);
+
+    /**
+     * 新增信义大模型问答记录
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 结果
+     */
+    public int insertTXinyiChatRecord(TXinyiChatRecord tXinyiChatRecord);
+
+    /**
+     * 修改信义大模型问答记录
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 结果
+     */
+    public int updateTXinyiChatRecord(TXinyiChatRecord tXinyiChatRecord);
+
+    /**
+     * 批量删除信义大模型问答记录
+     * 
+     * @param ids 需要删除的信义大模型问答记录主键集合
+     * @return 结果
+     */
+    public int deleteTXinyiChatRecordByIds(Long[] ids);
+
+    /**
+     * 删除信义大模型问答记录信息
+     * 
+     * @param id 信义大模型问答记录主键
+     * @return 结果
+     */
+    public int deleteTXinyiChatRecordById(Long id);
+}

+ 96 - 0
slibra-system/src/main/java/com/slibra/business/service/impl/TXinyiChatRecordServiceImpl.java

@@ -0,0 +1,96 @@
+package com.slibra.business.service.impl;
+
+import java.util.List;
+import com.slibra.common.utils.DateUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.slibra.business.mapper.TXinyiChatRecordMapper;
+import com.slibra.business.domain.TXinyiChatRecord;
+import com.slibra.business.service.ITXinyiChatRecordService;
+
+/**
+ * 信义大模型问答记录Service业务层处理
+ * 
+ * @author slibra
+ * @date 2024-05-15
+ */
+@Service
+public class TXinyiChatRecordServiceImpl implements ITXinyiChatRecordService 
+{
+    @Autowired
+    private TXinyiChatRecordMapper tXinyiChatRecordMapper;
+
+    /**
+     * 查询信义大模型问答记录
+     * 
+     * @param id 信义大模型问答记录主键
+     * @return 信义大模型问答记录
+     */
+    @Override
+    public TXinyiChatRecord selectTXinyiChatRecordById(Long id)
+    {
+        return tXinyiChatRecordMapper.selectTXinyiChatRecordById(id);
+    }
+
+    /**
+     * 查询信义大模型问答记录列表
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 信义大模型问答记录
+     */
+    @Override
+    public List<TXinyiChatRecord> selectTXinyiChatRecordList(TXinyiChatRecord tXinyiChatRecord)
+    {
+        return tXinyiChatRecordMapper.selectTXinyiChatRecordList(tXinyiChatRecord);
+    }
+
+    /**
+     * 新增信义大模型问答记录
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 结果
+     */
+    @Override
+    public int insertTXinyiChatRecord(TXinyiChatRecord tXinyiChatRecord)
+    {
+        tXinyiChatRecord.setCreateTime(DateUtils.getNowDate());
+        return tXinyiChatRecordMapper.insertTXinyiChatRecord(tXinyiChatRecord);
+    }
+
+    /**
+     * 修改信义大模型问答记录
+     * 
+     * @param tXinyiChatRecord 信义大模型问答记录
+     * @return 结果
+     */
+    @Override
+    public int updateTXinyiChatRecord(TXinyiChatRecord tXinyiChatRecord)
+    {
+        tXinyiChatRecord.setUpdateTime(DateUtils.getNowDate());
+        return tXinyiChatRecordMapper.updateTXinyiChatRecord(tXinyiChatRecord);
+    }
+
+    /**
+     * 批量删除信义大模型问答记录
+     * 
+     * @param ids 需要删除的信义大模型问答记录主键
+     * @return 结果
+     */
+    @Override
+    public int deleteTXinyiChatRecordByIds(Long[] ids)
+    {
+        return tXinyiChatRecordMapper.deleteTXinyiChatRecordByIds(ids);
+    }
+
+    /**
+     * 删除信义大模型问答记录信息
+     * 
+     * @param id 信义大模型问答记录主键
+     * @return 结果
+     */
+    @Override
+    public int deleteTXinyiChatRecordById(Long id)
+    {
+        return tXinyiChatRecordMapper.deleteTXinyiChatRecordById(id);
+    }
+}

+ 143 - 0
slibra-system/src/main/resources/mapper/business/TXinyiChatRecordMapper.xml

@@ -0,0 +1,143 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.slibra.business.mapper.TXinyiChatRecordMapper">
+
+    <resultMap type="TXinyiChatRecord" id="TXinyiChatRecordResult">
+        <result property="id"    column="id"    />
+        <result property="sessionId"    column="session_id"    />
+        <result property="type"    column="type"    />
+        <result property="module"    column="module"    />
+        <result property="userId"    column="user_id"    />
+        <result property="ask"    column="ask"    />
+        <result property="answer"    column="answer"    />
+        <result property="warningId"    column="warning_id"    />
+        <result property="counts"    column="counts"    />
+        <result property="delFlag"    column="del_flag"    />
+        <result property="revision"    column="revision"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+        <result property="remark"    column="remark"    />
+    </resultMap>
+
+    <sql id="selectTXinyiChatRecordVo">
+        select id, session_id, type, module, user_id, ask, answer, warning_id, counts, del_flag, revision, create_by, create_time, update_by, update_time, remark from t_xinyi_chat_record
+    </sql>
+
+    <select id="selectTXinyiChatRecordList" parameterType="TXinyiChatRecord" resultMap="TXinyiChatRecordResult">
+        <include refid="selectTXinyiChatRecordVo"/>
+        <where>
+            1 = 1
+            <if test="sessionId != null  and sessionId != ''"> and session_id = #{sessionId}</if>
+            <if test="type != null "> and type = #{type}</if>
+            <if test="module != null  and module != ''"> and module = #{module}</if>
+            <if test="userId != null  and userId != ''"> and user_id = #{userId}</if>
+            <if test="ask != null  and ask != ''"> and ask = #{ask}</if>
+            <if test="answer != null  and answer != ''"> and answer = #{answer}</if>
+            <if test="warningId != null  and warningId != ''"> and warning_id = #{warningId}</if>
+            <if test="counts != null "> and counts = #{counts}</if>
+            <if test="revision != null "> and revision = #{revision}</if>
+        </where>
+        and del_flag = 0
+    </select>
+
+
+    <select id="selectTXinyiChatRecordFirstList" parameterType="TXinyiChatRecord" resultMap="TXinyiChatRecordResult">
+        <include refid="selectTXinyiChatRecordVo"/>
+        <where>
+            1 = 1
+            <if test="sessionId != null  and sessionId != ''"> and session_id = #{sessionId}</if>
+            <if test="type != null "> and type = #{type}</if>
+            <if test="module != null  and module != ''"> and module = #{module}</if>
+            <if test="userId != null  and userId != ''"> and user_id = #{userId}</if>
+            <if test="ask != null  and ask != ''"> and ask = #{ask}</if>
+            <if test="answer != null  and answer != ''"> and answer = #{answer}</if>
+            <if test="warningId != null  and warningId != ''"> and warning_id = #{warningId}</if>
+            <if test="counts != null "> and counts = #{counts}</if>
+            <if test="revision != null "> and revision = #{revision}</if>
+        </where>
+        and del_flag = 0
+    </select>
+
+    <select id="selectTXinyiChatRecordById" parameterType="Long" resultMap="TXinyiChatRecordResult">
+        <include refid="selectTXinyiChatRecordVo"/>
+        where id = #{id} and del_flag = 0
+    </select>
+
+    <insert id="insertTXinyiChatRecord" parameterType="TXinyiChatRecord" useGeneratedKeys="true" keyProperty="id">
+        insert into t_xinyi_chat_record
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="sessionId != null">session_id,</if>
+            <if test="type != null">type,</if>
+            <if test="module != null">module,</if>
+            <if test="userId != null">user_id,</if>
+            <if test="ask != null">ask,</if>
+            <if test="answer != null">answer,</if>
+            <if test="warningId != null">warning_id,</if>
+            <if test="counts != null">counts,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="revision != null">revision,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+            <if test="remark != null">remark,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="sessionId != null">#{sessionId},</if>
+            <if test="type != null">#{type},</if>
+            <if test="module != null">#{module},</if>
+            <if test="userId != null">#{userId},</if>
+            <if test="ask != null">#{ask},</if>
+            <if test="answer != null">#{answer},</if>
+            <if test="warningId != null">#{warningId},</if>
+            <if test="counts != null">#{counts},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="revision != null">#{revision},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+            <if test="remark != null">#{remark},</if>
+        </trim>
+    </insert>
+
+    <update id="updateTXinyiChatRecord" parameterType="TXinyiChatRecord">
+        update t_xinyi_chat_record
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="sessionId != null">session_id = #{sessionId},</if>
+            <if test="type != null">type = #{type},</if>
+            <if test="module != null">module = #{module},</if>
+            <if test="userId != null">user_id = #{userId},</if>
+            <if test="ask != null">ask = #{ask},</if>
+            <if test="answer != null">answer = #{answer},</if>
+            <if test="warningId != null">warning_id = #{warningId},</if>
+            <if test="counts != null">counts = #{counts},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="revision != null">revision = #{revision},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+            <if test="remark != null">remark = #{remark},</if>
+        </trim>
+        ,revision = revision + 1
+        where id = #{id}
+    </update>
+
+
+
+    <delete id="deleteTXinyiChatRecordById" parameterType="Long">
+        update t_xinyi_chat_record set del_flag = 2,revision = revision + 1 where del_flag = 0 and id = #{id}
+    </delete>
+
+    <delete id="deleteTXinyiChatRecordByIds" parameterType="String">
+        update t_xinyi_chat_record set del_flag = 2,revision = revision + 1 where del_flag = 0 and id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>