소스 검색

报警列表 通过报警时间倒序排序 如果相同,再通过ID排序

王苗苗 1 일 전
부모
커밋
dc6144e17e
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      slibra-system/src/main/resources/mapper/business/TXinyiWarningRecordMapper.xml

+ 1 - 1
slibra-system/src/main/resources/mapper/business/TXinyiWarningRecordMapper.xml

@@ -77,7 +77,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="timeBegin != null  and timeBegin != ''"> and DATE_FORMAT(create_time, '%Y-%m-%d') &gt;= #{timeBegin}</if>
             <if test="timeEnd != null  and timeEnd != ''"> and DATE_FORMAT(create_time, '%Y-%m-%d') &lt;= #{timeEnd}</if>
         </where>
-        and del_flag = 0 order by id desc
+        and del_flag = 0 order by create_time desc, id desc
     </select>
 
     <select id="selectTXinyiWarningRecordById" parameterType="Long" resultMap="TXinyiWarningRecordResult">