From f0aac7e028b09aefa2428a8d66fdb81e466a89fe Mon Sep 17 00:00:00 2001
From: fei <791364011@qq.com>
Date: 星期三, 19 十一月 2025 15:35:52 +0800
Subject: [PATCH] 修改了对应代码
---
archiveManager/src/main/java/com/ruoyi/mapper/ArchiveRecordsMapper.java | 16 +++++++++++-----
1 files changed, 11 insertions(+), 5 deletions(-)
diff --git a/archiveManager/src/main/java/com/ruoyi/mapper/ArchiveRecordsMapper.java b/archiveManager/src/main/java/com/ruoyi/mapper/ArchiveRecordsMapper.java
index 76f9b7c..0f47537 100644
--- a/archiveManager/src/main/java/com/ruoyi/mapper/ArchiveRecordsMapper.java
+++ b/archiveManager/src/main/java/com/ruoyi/mapper/ArchiveRecordsMapper.java
@@ -20,7 +20,7 @@
@Select({
"<script>",
- "SELECT distinct c.*,a.archive_records_id, if(a.user_id=#{userId}, TRUE, FALSE) as tst,b.user_id FROM archiverecordstouser a inner join sys_user b ON a.user_id = b.user_id right join archive_records c on c.record_id=a.archive_records_id ${ew.customSqlSegment} ",
+ "SELECT distinct c.*,a.archive_records_id, if(a.user_id=#{userId}, TRUE, FALSE) as tst,b.user_id FROM archiverecordstouser a inner join sys_user b ON a.user_id = b.user_id right join archive_records c on c.id=a.archive_records_id ${ew.customSqlSegment} ",
"<if test= \"userId !=1 \">",
"order by tst desc",
"</if>",
@@ -38,15 +38,21 @@
ArchiveInfoVo findByRecordId(@Param("id") Long id);
@Select("SELECT every_project_name, count(*) as cnt, (select count(*) from archive_records as ac where ac.every_project_name=ar.every_project_name and record_status='鏈綍鍏�') as unfinished,\n" +
- "(select count(*) from archive_records as ac where ac.every_project_name=ar.every_project_name and record_status='褰曞叆瀹屾垚') as finished \n" +
- " from archive_records as ar GROUP BY every_project_name")
+ "(select count(*) from archive_records as ac where ac.every_project_name=ar.every_project_name and record_status='鏈笂浼犻檮浠�') as unwf,\n" +
+ "(select count(*) from archive_records as ac where ac.every_project_name=ar.every_project_name and record_status='寰呬慨鏀�') as dxg,\n" +
+ " (select count(*) from archive_records as ac where ac.every_project_name=ar.every_project_name and record_status='褰曞叆瀹屾垚') as finished\n" +
+ " from archive_records as ar GROUP BY every_project_name\n" +
+ " ")
List<AnalysisResult> statisticAyasis();
- @Select("update archive_records set record_status='褰曞叆瀹屾垚' where id=#{id}")
- public void updateStatusById(@Param("id")Long id);
+ @Select("update archive_records set record_status=#{status} where id=#{id}")
+ public void updateStatusById(@Param("status") String status, @Param("id")Long id);
@Select("select ROW_NUMBER() OVER (ORDER BY record_id) AS num, filing_number, concat_ws(\" \", inquiry_number,record_id) as inqrid, case_title, public_attribute, (select count(*) as cnt from document_materials where record_id=ar.id) as cnt, remarks from archive_records as ar \n" +
"${ew.customSqlSegment}")
public List<ArchiveRecordSmall> selectByIds(@Param("ew") LambdaQueryWrapper<ArchiveRecords> queryWrapper);
+
+ @Select("SELECT COALESCE(SUM(IF(url IS NULL AND file_style != '鏂囧瓧鏉愭枡', 1, 0)), 0) = 0 AS result from document_materials where `record_id` = #{recordId}")
+ boolean whether(@Param("recordId") Long recordId);
}
--
Gitblit v1.9.1