Forráskód Böngészése

Merge branch 'dev' of http://219.151.181.73:3000/zhuwei/bladex into dev

laibulaizheli 3 hete
szülő
commit
5914ac7992
25 módosított fájl, 977 hozzáadás és 34 törlés
  1. 65 0
      blade-service-api/blade-archive-api/src/main/java/org/springblade/archive/entity/ArchivesSortRule.java
  2. 5 0
      blade-service-api/blade-archive-api/src/main/java/org/springblade/archive/vo/ArchivesAutoVO.java
  3. 19 0
      blade-service-api/blade-archive-api/src/main/java/org/springblade/archive/vo/ArchivesAutoVO5.java
  4. 40 0
      blade-service-api/blade-manager-api/src/main/java/org/springblade/manager/dto/AlbumDTO.java
  5. 77 0
      blade-service-api/blade-manager-api/src/main/java/org/springblade/manager/entity/Album.java
  6. 38 0
      blade-service-api/blade-manager-api/src/main/java/org/springblade/manager/vo/AlbumVO.java
  7. 76 1
      blade-service/blade-archive/src/main/java/org/springblade/archive/controller/ArchivesAutoController.java
  8. 1 0
      blade-service/blade-archive/src/main/java/org/springblade/archive/mapper/ArchivesAutoMapper.java
  9. 78 8
      blade-service/blade-archive/src/main/java/org/springblade/archive/mapper/ArchivesAutoMapper.xml
  10. 18 0
      blade-service/blade-archive/src/main/java/org/springblade/archive/mapper/ArchivesSortRuleMapper.java
  11. 21 0
      blade-service/blade-archive/src/main/java/org/springblade/archive/mapper/ArchivesSortRuleMapper.xml
  12. 13 0
      blade-service/blade-archive/src/main/java/org/springblade/archive/service/ArchivesSortRuleService.java
  13. 4 0
      blade-service/blade-archive/src/main/java/org/springblade/archive/service/IArchivesAutoService.java
  14. 54 0
      blade-service/blade-archive/src/main/java/org/springblade/archive/service/impl/ArchivesAutoServiceImpl.java
  15. 22 0
      blade-service/blade-archive/src/main/java/org/springblade/archive/service/impl/ArchivesSortRuleServiceImpl.java
  16. 179 0
      blade-service/blade-manager/src/main/java/org/springblade/manager/controller/AlbumController.java
  17. 42 4
      blade-service/blade-manager/src/main/java/org/springblade/manager/controller/ExcelTabController.java
  18. 1 6
      blade-service/blade-manager/src/main/java/org/springblade/manager/controller/WbsTreeContractController.java
  19. 37 0
      blade-service/blade-manager/src/main/java/org/springblade/manager/mapper/AlbumMapper.java
  20. 35 0
      blade-service/blade-manager/src/main/java/org/springblade/manager/mapper/AlbumMapper.xml
  21. 43 0
      blade-service/blade-manager/src/main/java/org/springblade/manager/service/IAlbumService.java
  22. 0 2
      blade-service/blade-manager/src/main/java/org/springblade/manager/service/IWbsTreeContractService.java
  23. 54 0
      blade-service/blade-manager/src/main/java/org/springblade/manager/service/impl/AlbumServiceImpl.java
  24. 6 13
      blade-service/blade-manager/src/main/java/org/springblade/manager/service/impl/WbsTreeContractServiceImpl.java
  25. 49 0
      blade-service/blade-manager/src/main/java/org/springblade/manager/wrapper/AlbumWrapper.java

+ 65 - 0
blade-service-api/blade-archive-api/src/main/java/org/springblade/archive/entity/ArchivesSortRule.java

@@ -0,0 +1,65 @@
+package org.springblade.archive.entity;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import java.util.Date;
+
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+/**
+ * 档案案卷排序规则
+ * @author LHB
+ * @TableName u_archives_sort_rule
+ */
+@TableName(value ="u_archives_sort_rule")
+@Data
+public class ArchivesSortRule {
+    /**
+     * 
+     */
+    @ApiModelProperty(value = "主键id")
+    @TableId(type = IdType.INPUT)
+    private Long id;
+
+    /**
+     * 项目id
+     */
+    @ApiModelProperty(value = "项目id")
+    private Long projectId;
+
+    /**
+     *  类型(1-节点配许,2-流水号排序)
+     */
+    @ApiModelProperty(value = "类型(1-节点配许,2-流水号排序)")
+    private Integer type;
+
+    /**
+     *  创建时间
+     */
+    @org.springframework.format.annotation.DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @com.fasterxml.jackson.annotation.JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+
+    /**
+     *  创建人
+     */
+    @ApiModelProperty(value = "创建人")
+    private Long createUser;
+
+    /**
+     *  修改时间
+     */
+    @org.springframework.format.annotation.DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @com.fasterxml.jackson.annotation.JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "修改时间")
+    private Date updateTime;
+
+    /**
+     *  修改人
+     */
+    @ApiModelProperty(value = "修改人")
+    private Long updateUser;
+}

+ 5 - 0
blade-service-api/blade-archive-api/src/main/java/org/springblade/archive/vo/ArchivesAutoVO.java

@@ -170,6 +170,11 @@ public class ArchivesAutoVO extends ArchivesAuto {
 	 */
 	private String innerSearch;
 
+	/**
+	 * 排序规则
+	 */
+	private Integer sortRuleType;
+
 	@ApiModelProperty("批量保存")
 	private List<ArchivesAutoVO> list;
 	/**

+ 19 - 0
blade-service-api/blade-archive-api/src/main/java/org/springblade/archive/vo/ArchivesAutoVO5.java

@@ -0,0 +1,19 @@
+package org.springblade.archive.vo;
+
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+public class ArchivesAutoVO5 {
+    private Long id;
+    private String fileNumber;
+    private String name;
+    private String storageTimeValue;
+    private String storageTime;
+    private Integer pageN;
+    private String unit;
+    private String remark;
+}

+ 40 - 0
blade-service-api/blade-manager-api/src/main/java/org/springblade/manager/dto/AlbumDTO.java

@@ -0,0 +1,40 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.manager.dto;
+
+import org.springblade.manager.entity.Album;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+import java.util.List;
+
+/**
+ * 数据传输对象实体类
+ *
+ * @author BladeX
+ * @since 2025-07-15
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class AlbumDTO extends Album {
+	private static final long serialVersionUID = 1L;
+
+	private List<String> margePdfUrls;
+
+	private String dateValue;
+
+}

+ 77 - 0
blade-service-api/blade-manager-api/src/main/java/org/springblade/manager/entity/Album.java

@@ -0,0 +1,77 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.manager.entity;
+
+import com.baomidou.mybatisplus.annotation.TableName;
+import java.io.Serializable;
+import java.time.LocalDate;
+import org.springblade.core.mp.base.BaseEntity;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 实体类
+ *
+ * @author BladeX
+ * @since 2025-07-15
+ */
+@Data
+@TableName("m_album")
+@EqualsAndHashCode(callSuper = true)
+public class Album extends BaseEntity {
+
+	private static final long serialVersionUID = 1L;
+
+	/**
+	* 项目ID
+	*/
+		private Long projectId;
+	/**
+	* 合同段ID
+	*/
+		private Long contractId;
+	/**
+	* 分类ID (m_image_classification_config)
+	*/
+		private Long classifyId;
+	/**
+	* 相册文件题名
+	*/
+		private String imagesName;
+	/**
+	* 主要拍摄人
+	*/
+		private String photographer;
+	/**
+	* 分组号
+	*/
+		private String groupNumber;
+	/**
+	* 开始日期
+	*/
+		private String startDate;
+	/**
+	* 结束日期
+	*/
+		private String endDate;
+	/**
+	* 相册PDF
+	*/
+		private String imagesPdf;
+
+
+}

+ 38 - 0
blade-service-api/blade-manager-api/src/main/java/org/springblade/manager/vo/AlbumVO.java

@@ -0,0 +1,38 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.manager.vo;
+
+import org.springblade.manager.entity.Album;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+
+/**
+ * 视图实体类
+ *
+ * @author BladeX
+ * @since 2025-07-15
+ */
+@Data
+@EqualsAndHashCode(callSuper = true)
+public class AlbumVO extends Album {
+	private static final long serialVersionUID = 1L;
+
+	private String classifyName;
+
+	private String dateValue;
+
+}

+ 76 - 1
blade-service/blade-archive/src/main/java/org/springblade/archive/controller/ArchivesAutoController.java

@@ -30,6 +30,10 @@ import lombok.SneakyThrows;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.commons.lang.StringUtils;
 import org.apache.http.message.BasicNameValuePair;
+import org.apache.poi.openxml4j.exceptions.InvalidFormatException;
+import org.apache.poi.ss.usermodel.Row;
+import org.apache.poi.ss.usermodel.Sheet;
+import org.apache.poi.ss.usermodel.WorkbookFactory;
 import org.springblade.archive.dto.ArchiveWarningDTO;
 import org.springblade.archive.dto.FindAndReplaceDto;
 import org.springblade.archive.dto.SaveApplyDTO;
@@ -41,6 +45,7 @@ import org.springblade.archive.utils.CallBgrsjk;
 import org.springblade.archive.vo.*;
 import org.springblade.business.entity.ArchiveFile;
 import org.springblade.business.feign.ArchiveFileClient;
+import org.springblade.business.vo.NeiYeLedgerVO1;
 import org.springblade.common.utils.DeepSeekClient;
 import org.springblade.common.utils.SnowFlakeUtil;
 import org.springblade.core.mp.support.Condition;
@@ -54,6 +59,11 @@ import org.springblade.manager.feign.ArchiveTreeContractClient;
 import org.springblade.manager.feign.ContractClient;
 import org.springblade.manager.feign.ProjectClient;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.core.io.ByteArrayResource;
+import org.springframework.core.io.Resource;
+import org.springframework.http.HttpHeaders;
+import org.springframework.http.MediaType;
+import org.springframework.http.ResponseEntity;
 import org.springframework.jdbc.core.JdbcTemplate;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.web.bind.annotation.*;
@@ -65,7 +75,9 @@ import org.springblade.archive.service.IArchivesAutoService;
 import org.springblade.core.boot.ctrl.BladeController;
 import org.springframework.web.multipart.MultipartFile;
 
-import java.io.IOException;
+import java.io.*;
+import java.net.URLEncoder;
+import java.nio.charset.StandardCharsets;
 import java.util.*;
 import java.util.concurrent.ExecutorService;
 import java.util.stream.Collectors;
@@ -146,6 +158,53 @@ public class ArchivesAutoController extends BladeController {
 		return R.data(pages);
 	}
 
+	@SneakyThrows
+	@PostMapping ("/downloadArchiveAutoExcel")
+	@ApiOperationSupport(order = 13)
+	@ApiOperation(value = "档案下载案卷excel")
+	public ResponseEntity<Resource> downloadArchiveAutoExcel(HttpServletResponse response,Long nodeId,Long projectId,Long contractId) throws IOException, InvalidFormatException {
+		List<ArchiveTreeContract> archiveTreeContracts = this.archiveTreeContractClient.queryAllChildByAncestors(nodeId+"",contractId);
+		List<String> ids=new ArrayList<>();
+		if(archiveTreeContracts != null && archiveTreeContracts.size() > 0){
+			ids = JSONArray.parseArray(JSONObject.toJSONString(archiveTreeContracts.stream().map(ArchiveTreeContract::getId).distinct().collect(Collectors.toList())), String.class);
+			ids.add(nodeId+"");
+		}
+	    List<ArchivesAutoVO5> list=	archivesAutoService.selectArchivesAutoFileFormDownload(projectId,contractId,ids);
+		//String templatePath="/mnt/sdc/Users/hongchuangyanfa/Desktop/excel/archiveTemplate.xlsx";
+		String templatePath="C:\\Users\\hc01\\Desktop\\archiveTemplate.xlsx";
+		InputStream templateStream = new FileInputStream(new File(templatePath));
+		org.apache.poi.ss.usermodel.Workbook workbook = WorkbookFactory.create(templateStream);
+		Sheet sheet = workbook.getSheetAt(0);
+		// 3. 填充数据(假设数据从第2行开始填充)
+		int startRow = 1; // 第2行开始填充数据
+		for (int i = 0; i < list.size(); i++) {
+			Row row = sheet.createRow(startRow + i);
+			ArchivesAutoVO5 vo1 = list.get(i);
+			// 填充各列数据
+			row.createCell(0).setCellValue(i + 1); // 序号
+			row.createCell(1).setCellValue(StringUtils.isNotEmpty(vo1.getFileNumber())?vo1.getFileNumber():""); // 档号
+			row.createCell(2).setCellValue(StringUtils.isNotEmpty(vo1.getStorageTimeValue())?vo1.getStorageTimeValue():""); // 案卷题名
+			row.createCell(3).setCellValue(StringUtils.isNotEmpty(vo1.getStorageTimeValue())?vo1.getStorageTimeValue():""); // 保管期限
+			row.createCell(4).setCellValue(vo1.getPageN()+""); // 总页数
+			row.createCell(5).setCellValue(StringUtils.isNotEmpty(vo1.getUnit())?vo1.getUnit():""); // 立卷单位
+			row.createCell(6).setCellValue(StringUtils.isNotEmpty(vo1.getRemark())?vo1.getRemark():""); // 备注
+		}
+		ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
+		workbook.write(outputStream);
+		workbook.close();
+		ByteArrayResource resource = new ByteArrayResource(outputStream.toByteArray());
+
+		String fileName = "案卷目录.xlsx";
+		String encodedFileName = URLEncoder.encode(fileName, StandardCharsets.UTF_8.toString())
+				.replaceAll("\\+", "%20");
+		return ResponseEntity.ok()
+				.header(HttpHeaders.CONTENT_DISPOSITION, "attachment; filename*=UTF-8''" + encodedFileName)
+				.contentType(MediaType.APPLICATION_OCTET_STREAM)
+				.contentLength(resource.contentLength())
+				.body(resource);
+
+	}
+
     @GetMapping("/fileNumberFlush")
     @ApiOperationSupport(order = 4)
     @ApiOperation(value = "档号整理——按档号排序")
@@ -1031,5 +1090,21 @@ public class ArchivesAutoController extends BladeController {
         return R.status(archivesAutoService.reBuildArchiveFrontPdfs(archiveIds,projectId));
     }
 
+    @GetMapping("/sortRule")
+    @ApiOperationSupport(order = 42)
+    @ApiModelProperty(value = "排序规则")
+	@ApiImplicitParams(value = {
+			@ApiImplicitParam(name = "projectId", value = "项目id", required = true),
+			@ApiImplicitParam(name = "type", value = "排序类型:1-节点排序,2-流水号排序", required = true)
+	})
+    public R sortRule(Long projectId,Integer type){
+		if(projectId == null){
+			return R.fail("项目id不能为空");
+		}
+		if(type == null || type < 1 || type > 2){
+			return R.fail("排序类型错误");
+		}
+        return R.status(archivesAutoService.sortRule(projectId,type));
+    }
 
 }

+ 1 - 0
blade-service/blade-archive/src/main/java/org/springblade/archive/mapper/ArchivesAutoMapper.java

@@ -235,4 +235,5 @@ public interface ArchivesAutoMapper extends BaseMapper<ArchivesAuto> {
 	void deleteIsElementFileByProjectId(@Param("projectId") Long projectId);
 
 	void deleteIsElementFileByNode(@Param("projectId") Long projectId,@Param("ancestors") String ancestors,@Param("nodeId") String nodeId);
+	List<ArchivesAutoVO5> selectArchivesAutoFileFormDownload(@Param("projectId") Long projectId, @Param("contractId") Long contractId, @Param("ids") List<String> ids);
 }

+ 78 - 8
blade-service/blade-archive/src/main/java/org/springblade/archive/mapper/ArchivesAutoMapper.xml

@@ -262,16 +262,13 @@
 
 
     <select id="selectArchivesAutoFileCount" resultType="java.lang.Integer">
-        select count(id) from u_archives_auto u where u.is_deleted = 0
+        select count(0) from u_archives_auto u LEFT JOIN m_archive_tree_contract m ON u.node_id = m.id where u.is_deleted = 0
         <if test="vo.projectId != null and vo.projectId != ''">
             and u.project_id = #{vo.projectId}
         </if>
         <if test="vo.queryValue != null and vo.queryValue != ''">
             and (u.name like concat('%',#{vo.queryValue},'%') or u.file_number like concat('%',#{vo.queryValue},'%'))
         </if>
-        <if test="vo.isAutoFile != null and vo.isAutoFile != ''">
-            and u.is_auto_file = #{vo.isAutoFile}
-        </if>
         <choose>
             <when test="vo.isArchive != null and vo.isArchive != ''">
                 and u.is_archive = #{vo.isArchive}
@@ -289,6 +286,22 @@
                 #{nodeId}
             </foreach>
         </if>
+        <if test="vo.queryValueSize != null and vo.queryValueSize != ''">
+            <choose>
+                <when test="vo.queryValueSize == 1">
+                    and CHAR_LENGTH(u.name) <![CDATA[ < ]]> 80
+                </when>
+                <when test="vo.queryValueSize == 2">
+                    and CHAR_LENGTH(u.name) >= 80 and CHAR_LENGTH(u.name) <![CDATA[ < ]]> 120
+                </when>
+                <when test="vo.queryValueSize == 3">
+                    and CHAR_LENGTH(u.name) >= 120 and CHAR_LENGTH(u.name) <![CDATA[ < ]]> 150
+                </when>
+                <when test="vo.queryValueSize == 4">
+                    and CHAR_LENGTH(u.name) >= 150
+                </when>
+            </choose>
+        </if>
     </select>
 
     <select id="selectArchivesAutoFilePage" resultMap="archivesAutoResultMap">
@@ -332,8 +345,23 @@
                 </when>
             </choose>
         </if>
-        order by m.tree_sort,u.auto_file_sort is null ,u.auto_file_sort,u.file_number is null,
-        SUBSTRING_INDEX(u.file_number, '_', 1), SUBSTRING_INDEX(u.file_number, '_', -1) + 0 ,u.create_time asc
+        <choose>
+            <when test="vo.sortRuleType != null and vo.sortRuleType == 1 and vo.isArchive != null and vo.isArchive != ''">
+                ORDER BY
+                    m.tree_sort,
+                    CASE WHEN u.file_number IS NULL THEN 1 ELSE 0 END,
+                    CAST(SUBSTRING_INDEX(file_number, '_', -1) AS SIGNED)
+            </when>
+            <when test="vo.sortRuleType != null and vo.sortRuleType == 2 and vo.isArchive != null and vo.isArchive != ''">
+                order by
+                    CASE WHEN u.file_number IS NULL THEN 1 ELSE 0 END,
+                    CAST(SUBSTRING_INDEX(file_number, '_', -1) AS SIGNED)
+            </when>
+            <otherwise>
+                order by m.tree_sort,u.auto_file_sort is null ,u.auto_file_sort,u.file_number is null,
+                SUBSTRING_INDEX(u.file_number, '_', 1), SUBSTRING_INDEX(u.file_number, '_', -1) + 0 ,u.create_time asc
+            </otherwise>
+        </choose>
         limit #{current}, #{size}
     </select>
 
@@ -663,7 +691,23 @@
             </foreach>
         </if>
         GROUP BY uaa.id
-        order by uaa.tree_sort,uaa.auto_file_sort,uaa.file_number asc
+
+        <choose>
+            <when test="vo.sortRuleType != null and vo.sortRuleType == 1">
+                ORDER BY
+                matc.tree_sort,
+                CASE WHEN uaa.file_number IS NULL THEN 1 ELSE 0 END,
+                CAST(SUBSTRING_INDEX(uaa.file_number, '_', -1) AS SIGNED)
+            </when>
+            <when test="vo.sortRuleType != null and vo.sortRuleType == 2">
+                ORDER BY
+                CASE WHEN uaa.file_number IS NULL THEN 1 ELSE 0 END,
+                CAST(SUBSTRING_INDEX(uaa.file_number, '_', -1) AS SIGNED)
+            </when>
+            <otherwise>
+                order by uaa.tree_sort,uaa.auto_file_sort,uaa.file_number asc
+            </otherwise>
+        </choose>
     </select>
 
     <select id="pageByArchivesAuto11" resultMap="archivesAutoResultMap">
@@ -722,7 +766,22 @@
             </foreach>
         </if>
         GROUP BY uaa.id
-        order by uaa.tree_sort,uaa.auto_file_sort,uaa.file_number asc
+        <choose>
+            <when test="vo.sortRuleType != null and vo.sortRuleType == 1">
+                ORDER BY
+                matc.tree_sort,
+                CASE WHEN uaa.file_number IS NULL THEN 1 ELSE 0 END,
+                CAST(SUBSTRING_INDEX(uaa.file_number, '_', -1) AS SIGNED)
+            </when>
+            <when test="vo.sortRuleType != null and vo.sortRuleType == 2">
+                ORDER BY
+                CASE WHEN uaa.file_number IS NULL THEN 1 ELSE 0 END,
+                CAST(SUBSTRING_INDEX(uaa.file_number, '_', -1) AS SIGNED)
+            </when>
+            <otherwise>
+                order by uaa.tree_sort,uaa.auto_file_sort,uaa.file_number asc
+            </otherwise>
+        </choose>
     </select>
 
     <select id="pageByArchivesAuto2" resultMap="archivesAutoResultMap">
@@ -1489,4 +1548,15 @@
         order by uatc.tree_sort,uaa.auto_file_sort is null ,uaa.auto_file_sort,uaa.file_number is null,
         SUBSTRING_INDEX(uaa.file_number, '_', 1), SUBSTRING_INDEX(uaa.file_number, '_', -1) + 0 ,uaa.create_time asc
     </select>
+    <select id="selectArchivesAutoFileFormDownload" resultType="org.springblade.archive.vo.ArchivesAutoVO5">
+        select u.id,u.file_number,u.name,u.storageTime,u.page_n,u.unit,u.remark from u_archives_auto u LEFT JOIN m_archive_tree_contract m ON u.node_id = m.id where u.is_deleted = 0 and u.project_id = #{vo.projectId} and u.is_archive=1
+        <if test="vo.nodeIds != null and vo.nodeIds != ''">
+            and u.node_id in
+            <foreach collection="vo.nodeIdArray" item="nodeId" open="(" separator="," close=")">
+                #{nodeId}
+            </foreach>
+        </if>
+        order by m.tree_sort,u.auto_file_sort is null ,u.auto_file_sort,u.file_number is null,
+        SUBSTRING_INDEX(u.file_number, '_', 1), SUBSTRING_INDEX(u.file_number, '_', -1) + 0 ,u.create_time asc
+    </select>
 </mapper>

+ 18 - 0
blade-service/blade-archive/src/main/java/org/springblade/archive/mapper/ArchivesSortRuleMapper.java

@@ -0,0 +1,18 @@
+package org.springblade.archive.mapper;
+
+import org.springblade.archive.entity.ArchivesSortRule;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+* @author LHB
+* @description 针对表【u_archives_sort_rule(档案案卷排序规则)】的数据库操作Mapper
+* @createDate 2025-07-15 11:37:52
+* @Entity generator.domain.UArchivesSortRule
+*/
+public interface ArchivesSortRuleMapper extends BaseMapper<ArchivesSortRule> {
+
+}
+
+
+
+

+ 21 - 0
blade-service/blade-archive/src/main/java/org/springblade/archive/mapper/ArchivesSortRuleMapper.xml

@@ -0,0 +1,21 @@
+<?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="org.springblade.archive.mapper.ArchivesSortRuleMapper">
+
+    <resultMap id="BaseResultMap" type="org.springblade.archive.entity.ArchivesSortRule">
+            <id property="id" column="id" />
+            <result property="projectId" column="project_id" />
+            <result property="type" column="type" />
+            <result property="createTime" column="create_time" />
+            <result property="createUser" column="create_user" />
+            <result property="updateTime" column="update_time" />
+            <result property="updateUser" column="update_user" />
+    </resultMap>
+
+    <sql id="Base_Column_List">
+        id,project_id,type,create_time,create_user,update_time,
+        update_user
+    </sql>
+</mapper>

+ 13 - 0
blade-service/blade-archive/src/main/java/org/springblade/archive/service/ArchivesSortRuleService.java

@@ -0,0 +1,13 @@
+package org.springblade.archive.service;
+
+import org.springblade.archive.entity.ArchivesSortRule;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+/**
+* @author LHB
+* @description 针对表【u_archives_sort_rule(档案案卷排序规则)】的数据库操作Service
+* @createDate 2025-07-15 11:37:52
+*/
+public interface ArchivesSortRuleService extends IService<ArchivesSortRule> {
+
+}

+ 4 - 0
blade-service/blade-archive/src/main/java/org/springblade/archive/service/IArchivesAutoService.java

@@ -169,4 +169,8 @@ public interface IArchivesAutoService extends BaseService<ArchivesAuto> {
 
 
 	boolean creatFileNameFormAI(String ids, Long projectId, Long contractId) throws IOException;
+
+	List<ArchivesAutoVO5> selectArchivesAutoFileFormDownload(Long projectId, Long contractId, List<String> ids);
+
+	boolean sortRule(Long projectId, Integer type);
 }

+ 54 - 0
blade-service/blade-archive/src/main/java/org/springblade/archive/service/impl/ArchivesAutoServiceImpl.java

@@ -25,6 +25,7 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 
 import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
 import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
+import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.itextpdf.text.*;
@@ -156,6 +157,8 @@ public class ArchivesAutoServiceImpl extends BaseServiceImpl<ArchivesAutoMapper,
 
 	private final IArchiveAiNameService aiNameService;
 
+	private final ArchivesSortRuleService archivesSortRuleService;
+
 
 	@Override
 	public IPage<ArchivesAutoVO> selectArchivesAutoPage(IPage<ArchivesAutoVO> page, ArchivesAutoVO archivesAuto) {
@@ -212,6 +215,15 @@ public class ArchivesAutoServiceImpl extends BaseServiceImpl<ArchivesAutoMapper,
 				vo.setContractId(null);
 			}
 		}
+		//添加排序规则
+		if(vo.getProjectId() != null){
+			ArchivesSortRule one = archivesSortRuleService.getOne(Wrappers.<ArchivesSortRule>lambdaQuery()
+					.eq(ArchivesSortRule::getProjectId, vo.getProjectId()));
+			if(one != null){
+				//添加排序类型
+				vo.setSortRuleType(one.getType());
+			}
+		}
 		if (StringUtils.isNotBlank(vo.getNodeIds())) {
 			vo.setNodeIdArray(Arrays.asList(vo.getNodeIds().split(",")));
 			//如果搜索类型不为文件,就不连接文件表
@@ -633,6 +645,15 @@ public class ArchivesAutoServiceImpl extends BaseServiceImpl<ArchivesAutoMapper,
 			fixArchivesAutoFile(vo);
 		}
 
+		//添加排序规则
+		if(vo.getProjectId() != null){
+			ArchivesSortRule one = archivesSortRuleService.getOne(Wrappers.<ArchivesSortRule>lambdaQuery()
+					.eq(ArchivesSortRule::getProjectId, vo.getProjectId()));
+			if(one != null){
+				//添加排序类型
+				vo.setSortRuleType(one.getType());
+			}
+		}
 		List<ArchivesAuto> pageList = this.baseMapper.selectArchivesAutoFilePage(current, vo.getSize(), vo);
 		//设置分页信息
 		iPage.setTotal(total);
@@ -1579,6 +1600,22 @@ public class ArchivesAutoServiceImpl extends BaseServiceImpl<ArchivesAutoMapper,
 		return aiNameService.saveBatch(aiNames);
 	}
 
+	@Override
+	public List<ArchivesAutoVO5> selectArchivesAutoFileFormDownload(Long projectId, Long contractId, List<String> ids) {
+		List<ArchivesAutoVO5> list = this.baseMapper.selectArchivesAutoFileFormDownload(projectId, contractId, ids);
+		List<DictBiz> sheetSourceList1 = this.iDictBizClient.getList("storage_period", "notRoot").getData();
+		list.forEach(vos -> {
+			if (StringUtils.isNotEmpty(vos.getStorageTime())) {
+				sheetSourceList1.forEach(source -> {
+					if (source.getDictKey().equals(vos.getStorageTime())) {
+						vos.setStorageTimeValue(source.getDictValue());
+					}
+				});
+			}
+		});
+		return list;
+	}
+
 
 	/**
 	 * 单独组卷规则组卷
@@ -4900,4 +4937,21 @@ public class ArchivesAutoServiceImpl extends BaseServiceImpl<ArchivesAutoMapper,
 		}
 	}
 
+	@Override
+	public boolean sortRule(Long projectId, Integer type) {
+		//根据项目id查询如果没有就新增,如果有就修改
+		ArchivesSortRule one = archivesSortRuleService.getOne(Wrappers.<ArchivesSortRule>lambdaQuery()
+				.eq(ArchivesSortRule::getProjectId, projectId));
+		if (one == null) {
+			one = new ArchivesSortRule();
+			one.setId(SnowFlakeUtil.getId());
+			one.setProjectId(projectId);
+			one.setCreateUser(AuthUtil.getUserId());
+		} else {
+			one.setUpdateUser(AuthUtil.getUserId());
+		}
+		one.setType(type);
+		archivesSortRuleService.saveOrUpdate(one);
+		return true;
+	}
 }

+ 22 - 0
blade-service/blade-archive/src/main/java/org/springblade/archive/service/impl/ArchivesSortRuleServiceImpl.java

@@ -0,0 +1,22 @@
+package org.springblade.archive.service.impl;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springblade.archive.entity.ArchivesSortRule;
+import org.springblade.archive.mapper.ArchivesSortRuleMapper;
+import org.springblade.archive.service.ArchivesSortRuleService;
+import org.springframework.stereotype.Service;
+
+/**
+* @author LHB
+* @description 针对表【u_archives_sort_rule(档案案卷排序规则)】的数据库操作Service实现
+* @createDate 2025-07-15 11:37:52
+*/
+@Service
+public class ArchivesSortRuleServiceImpl extends ServiceImpl<ArchivesSortRuleMapper, ArchivesSortRule>
+    implements ArchivesSortRuleService {
+
+}
+
+
+
+

+ 179 - 0
blade-service/blade-manager/src/main/java/org/springblade/manager/controller/AlbumController.java

@@ -0,0 +1,179 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.manager.controller;
+
+import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import io.swagger.annotations.ApiParam;
+import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
+import lombok.AllArgsConstructor;
+import javax.validation.Valid;
+
+import org.springblade.common.constant.CommonConstant;
+import org.springblade.common.utils.SnowFlakeUtil;
+import org.springblade.core.log.exception.ServiceException;
+import org.springblade.core.mp.support.Condition;
+import org.springblade.core.mp.support.Query;
+import org.springblade.core.oss.model.BladeFile;
+import org.springblade.core.tool.api.R;
+import org.springblade.core.tool.utils.BeanUtil;
+import org.springblade.core.tool.utils.Func;
+import org.springblade.manager.dto.AlbumDTO;
+import org.springblade.manager.utils.FileUtils;
+import org.springblade.resource.feign.NewIOSSClient;
+import org.springblade.system.cache.ParamCache;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.bind.annotation.RequestParam;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import org.springblade.manager.entity.Album;
+import org.springblade.manager.vo.AlbumVO;
+import org.springblade.manager.wrapper.AlbumWrapper;
+import org.springblade.manager.service.IAlbumService;
+import org.springblade.core.boot.ctrl.BladeController;
+
+/**
+ *  控制器
+ *
+ * @author BladeX
+ * @since 2025-07-15
+ */
+@RestController
+@AllArgsConstructor
+@RequestMapping("/album")
+@Api(value = "", tags = "接口")
+public class AlbumController extends BladeController {
+
+	private final IAlbumService albumService;
+
+	private final NewIOSSClient newIOSSClient;
+
+	/**
+	 * 详情
+	 */
+	@GetMapping("/detail")
+	@ApiOperationSupport(order = 1)
+	@ApiOperation(value = "详情", notes = "传入album")
+	public R<AlbumVO> detail(Album album) {
+		Album detail = albumService.getOne(Condition.getQueryWrapper(album));
+		return R.data(AlbumWrapper.build().entityVO(detail));
+	}
+
+	/**
+	 * 分页 
+	 */
+	@PostMapping("/page")
+	@ApiOperationSupport(order = 2)
+	@ApiOperation(value = "分页", notes = "传入album")
+	public R<IPage<AlbumVO>> page(Long projectId,Long contractId,Query query) {
+		IPage<AlbumVO> pages = albumService.selectPage1(projectId,contractId,Condition.getPage(query));
+		return R.data(pages);
+	}
+
+
+//	/**
+//	 * 自定义分页
+//	 */
+//	@GetMapping("/page")
+//	@ApiOperationSupport(order = 3)
+//	@ApiOperation(value = "分页", notes = "传入album")
+//	public R<IPage<AlbumVO>> page(AlbumVO album, Query query) {
+//		IPage<AlbumVO> pages = albumService.selectAlbumPage(Condition.getPage(query), album);
+//		return R.data(pages);
+//	}
+
+	/**
+	 * 新增 
+	 */
+	@PostMapping("/save")
+	@ApiOperationSupport(order = 4)
+	@ApiOperation(value = "新增", notes = "传入album")
+	public R save(@Valid @RequestBody AlbumDTO albumDTO) {
+		if(albumDTO.getMargePdfUrls().isEmpty()){
+			throw new ServiceException("相册不能为空");
+		}
+		Album album=new Album();
+		BeanUtil.copy(albumDTO,album);
+		String dateValue = albumDTO.getDateValue();
+		String[] strings = dateValue.split("~");
+		album.setStartDate(strings[0]);
+		album.setEndDate(strings[1]);
+		if(albumDTO.getMargePdfUrls().size()>1){
+			String file_path = FileUtils.getSysLocalFileUrl();
+			Long id = SnowFlakeUtil.getId();
+			String mergeName=id+".pdf";
+			String mergeUrl = file_path + "/nodePDF/"+id+".pdf";;
+			FileUtils.mergePdfPublicMethods(albumDTO.getMargePdfUrls(), mergeUrl);
+			BladeFile bladeFile = this.newIOSSClient.uploadFile(mergeName, mergeUrl);
+			if (bladeFile != null && ObjectUtils.isNotEmpty(bladeFile.getLink())) {
+				album.setImagesPdf(bladeFile.getLink());
+			}
+		}else {
+			album.setImagesPdf(albumDTO.getMargePdfUrls().get(0));
+		}
+
+		return R.status(albumService.save(album));
+	}
+
+	/**
+	 * 修改 
+	 */
+	@PostMapping("/update")
+	@ApiOperationSupport(order = 5)
+	@ApiOperation(value = "修改", notes = "传入album")
+	public R update(@Valid @RequestBody AlbumDTO albumDTO) {
+		Album album=new Album();
+		BeanUtil.copy(albumDTO,album);
+		String dateValue = albumDTO.getDateValue();
+		String[] strings = dateValue.split("~");
+		album.setStartDate(strings[0]);
+		album.setEndDate(strings[1]);
+		return R.status(albumService.updateById(album));
+	}
+
+//	/**
+//	 * 新增或修改
+//	 */
+//	@PostMapping("/submit")
+//	@ApiOperationSupport(order = 6)
+//	@ApiOperation(value = "新增或修改", notes = "传入album")
+//	public R submit(@Valid @RequestBody Album album) {
+//		return R.status(albumService.saveOrUpdate(album));
+//	}
+
+	
+//	/**
+//	 * 删除
+//	 */
+//	@PostMapping("/remove")
+//	@ApiOperationSupport(order = 7)
+//	@ApiOperation(value = "逻辑删除", notes = "传入ids")
+//	public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) {
+//		return R.status(albumService.deleteLogic(Func.toLongList(ids)));
+//	}
+
+
+
+	@PostMapping("/remove")
+	@ApiOperationSupport(order = 7)
+	@ApiOperation(value = "逻辑删除", notes = "传入ids")
+	public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam Long id) {
+		return R.status(albumService.removeById(id));
+	}
+
+	
+}

+ 42 - 4
blade-service/blade-manager/src/main/java/org/springblade/manager/controller/ExcelTabController.java

@@ -38,10 +38,7 @@ import org.springblade.business.feign.ContractLogClient;
 import org.springblade.business.feign.InformationQueryClient;
 import org.springblade.business.vo.SaveContractLogVO;
 import org.springblade.common.constant.CommonConstant;
-import org.springblade.common.utils.BaseUtils;
-import org.springblade.common.utils.CommonUtil;
-import org.springblade.common.utils.MathUtil;
-import org.springblade.common.utils.SnowFlakeUtil;
+import org.springblade.common.utils.*;
 import org.springblade.core.boot.ctrl.BladeController;
 import org.springblade.core.log.exception.ServiceException;
 import org.springblade.core.mp.support.Condition;
@@ -58,9 +55,11 @@ import org.springblade.manager.dto.AddBussFileSortDTO;
 import org.springblade.manager.entity.*;
 import org.springblade.manager.enums.ExecuteType;
 import org.springblade.manager.mapper.ExcelTabMapper;
+import org.springblade.manager.mapper.WbsTreeContractMapper;
 import org.springblade.manager.mapper.WbsTreePrivateMapper;
 import org.springblade.manager.service.*;
 import org.springblade.manager.utils.*;
+import org.springblade.manager.utils.FileUtils;
 import org.springblade.manager.vo.*;
 import org.springblade.manager.wrapper.ExcelTabWrapper;
 import org.springblade.resource.feign.CommonFileClient;
@@ -163,6 +162,8 @@ public class ExcelTabController extends BladeController {
 
     private final  SignFtpUtil signFtpUtil;
 
+    private final WbsTreeContractMapper wbsTreeContractMapper;
+
 
     @Autowired
     StringRedisTemplate RedisTemplate;
@@ -4800,4 +4801,41 @@ public class ExcelTabController extends BladeController {
         List<ParameterElementVO2> query = jdbcTemplate.query(sql, new BeanPropertyRowMapper<>(ParameterElementVO2.class));
         return R.data(query);
     }
+
+    @GetMapping("/checkAllNodeDate")
+    @ApiOperationSupport(order = 43)
+    @ApiOperation(value = "检查所有表单是否填写完毕日期")
+    public R checkAllNodeDate(Long projectId,Long contractId) throws Exception {
+        //查询出当前项目或合同段下所有的表单
+        List<WbsTreeContract>list= wbsTreeContractMapper.selectListForcheckAllNodeDate(projectId,contractId);
+        //将表单通过pid分组
+        Map<Long, List<WbsTreeContract>> map = list.stream().collect(Collectors.groupingBy(WbsTreeContract::getPId));
+        for (Map.Entry<Long, List<WbsTreeContract>> entry : map.entrySet()) {
+            Long pId = entry.getKey();
+            WbsTreeContract parent = wbsTreeContractMapper.selectOne(new LambdaQueryWrapper<>(WbsTreeContract.class).eq(WbsTreeContract::getPKeyId, pId));
+            List<WbsTreeContract> wbsTreeContractList = entry.getValue();
+            for (WbsTreeContract contract : wbsTreeContractList) {
+                Map<String, Object> dataInfo = excelTabService.getBussDataInfo(contract.getPKeyId(), 0, true);
+                InputStream inputStreamByUrl = FileUtils.getInputStreamByUrl(contract.getHtmlUrl());
+                String htmlString = IoUtil.readToString(inputStreamByUrl);
+                Document doc = Jsoup.parse(htmlString);
+                Elements dateElements = doc.select("el-date-picker");
+                if(!dateElements.isEmpty()){
+                    Boolean dateFlag=true;
+                    for (Element element : dateElements) {
+                        String keyname = element.attr("keyname");
+                        if(!dataInfo.containsKey(keyname)||(StringUtils.isEmpty(dataInfo.get(keyname).toString()))){
+                            dateFlag=false;
+                            break;
+                        }
+                    }
+                    if(!dateFlag){
+                        wbsTreeContractMapper.update(contract,new LambdaUpdateWrapper<WbsTreeContract>().eq(WbsTreeContract::getPKeyId,contract.getPKeyId()).set(WbsTreeContract::getDateIsComplete,2));
+                    }
+                }
+            }
+            wbsTreeContractService.checkNodeAllDate(parent);
+        }
+        return R.status(true);
+    }
 }

+ 1 - 6
blade-service/blade-manager/src/main/java/org/springblade/manager/controller/WbsTreeContractController.java

@@ -825,11 +825,6 @@ public class WbsTreeContractController extends BladeController {
         wbsTreeContractServiceImpl.resetTableDate(projectId);
         return R.success("成功");
     }
-    @GetMapping("/checkAllNodeDate")
-    @ApiOperationSupport(order = 43)
-    @ApiOperation(value = "检查所有表单是否填写完毕日期")
-    public R checkAllNodeDate(Long projectId,Long contractId){
-        return R.status(wbsTreeContractServiceImpl.checkAllNodeDate(projectId,contractId));
-    }
+
 
 }

+ 37 - 0
blade-service/blade-manager/src/main/java/org/springblade/manager/mapper/AlbumMapper.java

@@ -0,0 +1,37 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.manager.mapper;
+
+import org.apache.ibatis.annotations.Param;
+import org.springblade.manager.entity.Album;
+import org.springblade.manager.vo.AlbumVO;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import java.util.List;
+
+/**
+ *  Mapper 接口
+ *
+ * @author BladeX
+ * @since 2025-07-15
+ */
+public interface AlbumMapper extends BaseMapper<Album> {
+
+
+
+    List<AlbumVO> selectAlbumPages(@Param("projectId") Long projectId, @Param("contractId")Long contractId, @Param("current")long current, @Param("size")long size);
+}

+ 35 - 0
blade-service/blade-manager/src/main/java/org/springblade/manager/mapper/AlbumMapper.xml

@@ -0,0 +1,35 @@
+<?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="org.springblade.manager.mapper.AlbumMapper">
+
+    <!-- 通用查询映射结果 -->
+    <resultMap id="albumResultMap" type="org.springblade.manager.entity.Album">
+        <result column="id" property="id"/>
+        <result column="create_user" property="createUser"/>
+        <result column="create_dept" property="createDept"/>
+        <result column="create_time" property="createTime"/>
+        <result column="update_user" property="updateUser"/>
+        <result column="update_time" property="updateTime"/>
+        <result column="status" property="status"/>
+        <result column="is_deleted" property="isDeleted"/>
+        <result column="project_id" property="projectId"/>
+        <result column="contract_id" property="contractId"/>
+        <result column="classify_id" property="classifyId"/>
+        <result column="images_name" property="imagesName"/>
+        <result column="photographer" property="photographer"/>
+        <result column="group_number" property="groupNumber"/>
+        <result column="start_date" property="startDate"/>
+        <result column="end_date" property="endDate"/>
+        <result column="images_pdf" property="imagesPdf"/>
+    </resultMap>
+
+
+
+    <select id="selectAlbumPages" resultType="org.springblade.manager.vo.AlbumVO">
+        select a.*,m.classf_name as classifyName,
+               CONCAT(a.start_date, '~', a.end_date) as dateValue
+        from m_album a left join m_image_classification_config m on a.classify_id=m.id
+        where a.project_id=#{projectId} and a.contract_id=#{contractId} and a.is_deleted = 0
+            limit #{current},#{size}
+    </select>
+</mapper>

+ 43 - 0
blade-service/blade-manager/src/main/java/org/springblade/manager/service/IAlbumService.java

@@ -0,0 +1,43 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.manager.service;
+
+import org.springblade.manager.entity.Album;
+import org.springblade.manager.vo.AlbumVO;
+import org.springblade.core.mp.base.BaseService;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+/**
+ *  服务类
+ *
+ * @author BladeX
+ * @since 2025-07-15
+ */
+public interface IAlbumService extends BaseService<Album> {
+
+//	/**
+//	 * 自定义分页
+//	 *
+//	 * @param page
+//	 * @param album
+//	 * @return
+//	 */
+//	IPage<AlbumVO> selectAlbumPage(IPage<AlbumVO> page, AlbumVO album);
+
+
+	IPage<AlbumVO> selectPage1(Long projectId, Long contractId, IPage<AlbumVO> page);
+}

+ 0 - 2
blade-service/blade-manager/src/main/java/org/springblade/manager/service/IWbsTreeContractService.java

@@ -90,6 +90,4 @@ public interface IWbsTreeContractService extends BaseService<WbsTreeContract> {
     EKeyDto getEKey(String contractId, Long pKeyId, String wbsId);
 
     boolean checkNodeAllDate(WbsTreeContract contract);
-
-    boolean checkAllNodeDate(Long projectId, Long contractId);
 }

+ 54 - 0
blade-service/blade-manager/src/main/java/org/springblade/manager/service/impl/AlbumServiceImpl.java

@@ -0,0 +1,54 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.manager.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import org.springblade.manager.entity.Album;
+import org.springblade.manager.vo.AlbumVO;
+import org.springblade.manager.mapper.AlbumMapper;
+import org.springblade.manager.service.IAlbumService;
+import org.springblade.core.mp.base.BaseServiceImpl;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+
+import java.util.List;
+
+/**
+ *  服务实现类
+ *
+ * @author BladeX
+ * @since 2025-07-15
+ */
+@Service
+public class AlbumServiceImpl extends BaseServiceImpl<AlbumMapper, Album> implements IAlbumService {
+
+//	@Override
+//	public IPage<AlbumVO> selectAlbumPage(IPage<AlbumVO> page, AlbumVO album) {
+//		return page.setRecords(baseMapper.selectAlbumPage(page, album));
+//	}
+
+	@Override
+	public IPage<AlbumVO> selectPage1(Long projectId, Long contractId, IPage<AlbumVO> page) {
+		Long count = baseMapper.selectCount(new LambdaQueryWrapper<>(Album.class).eq(Album::getProjectId, projectId).eq(Album::getContractId, contractId));
+		page.setTotal(count);
+		List<AlbumVO> albumVOS = baseMapper.selectAlbumPages(projectId, contractId, (page.getCurrent()-1)*page.getSize(),page.getSize());
+		page.setRecords(albumVOS);
+		return page;
+	}
+
+
+}

+ 6 - 13
blade-service/blade-manager/src/main/java/org/springblade/manager/service/impl/WbsTreeContractServiceImpl.java

@@ -2508,6 +2508,7 @@ public class WbsTreeContractServiceImpl extends BaseServiceImpl<WbsTreeContractM
                     unit.setIsTypePrivatePid(null);
                     unit.setSort(i);
                     unit.setTreePId(null);
+                    unit.setDateIsComplete(null);
                     unit.setPId(wbsTreeContractRoot.getPKeyId());
                     unit.setAncestorsPId(wbsTreeContractRoot.getAncestorsPId() + "," + wbsTreeContractRoot.getPKeyId());
                     baseMapper.insert(unit);
@@ -2534,6 +2535,7 @@ public class WbsTreeContractServiceImpl extends BaseServiceImpl<WbsTreeContractM
                     subUnit.setIsTypePrivatePid(null);
                     subUnit.setSort(i);
                     subUnit.setTreePId(null);
+                    subUnit.setDateIsComplete(null);
                     subUnit.setPId(fatherNode.getPKeyId());
                     subUnit.setAncestorsPId(fatherNode.getAncestorsPId() + "," + fatherNode.getPKeyId());
                     baseMapper.insert(subUnit);
@@ -2580,6 +2582,7 @@ public class WbsTreeContractServiceImpl extends BaseServiceImpl<WbsTreeContractM
                                 division.setIsTypePrivatePid(null);
                                 division.setSort(i);
                                 division.setTreePId(null);
+                                division.setDateIsComplete(null);
                                 division.setPId(contract.getPKeyId());
                                 division.setAncestorsPId(contract.getAncestorsPId() + "," + contract.getPKeyId());
                                 baseMapper.insert(division);
@@ -2633,6 +2636,7 @@ public class WbsTreeContractServiceImpl extends BaseServiceImpl<WbsTreeContractM
                                 subDivision.setIsTypePrivatePid(null);
                                 subDivision.setSort(i);
                                 subDivision.setTreePId(null);
+                                subDivision.setDateIsComplete(null);
                                 subDivision.setPId(contract.getPKeyId());
                                 subDivision.setAncestorsPId(contract.getAncestorsPId() + "," + contract.getPKeyId());
                                 baseMapper.insert(subDivision);
@@ -2690,6 +2694,7 @@ public class WbsTreeContractServiceImpl extends BaseServiceImpl<WbsTreeContractM
                                 item.setIsTypePrivatePid(null);
                                 item.setSort(i);
                                 item.setTreePId(null);
+                                item.setDateIsComplete(null);
                                 item.setPId(contract.getPKeyId());
                                 item.setAncestorsPId(contract.getAncestorsPId() + "," + contract.getPKeyId());
                                 baseMapper.insert(item);
@@ -2750,6 +2755,7 @@ public class WbsTreeContractServiceImpl extends BaseServiceImpl<WbsTreeContractM
                                 subItem.setIsTypePrivatePid(null);
                                 subItem.setSort(i);
                                 subItem.setTreePId(null);
+                                subItem.setDateIsComplete(null);
                                 subItem.setPId(contract.getPKeyId());
                                 subItem.setAncestorsPId(contract.getAncestorsPId() + "," + contract.getPKeyId());
                                 baseMapper.insert(subItem);
@@ -3937,18 +3943,5 @@ public static boolean hasConflictingCodes(List<ImportTreeDto> list) {
     }
 
 
-    @Override
-    public boolean checkAllNodeDate(Long projectId, Long contractId) {
-        //查询出当前项目或合同段下所有的表单
-      List<WbsTreeContract>list= baseMapper.selectListForcheckAllNodeDate(projectId,contractId);
-        //将表单通过pid分组
-        Map<Long, List<WbsTreeContract>> map = list.stream().collect(Collectors.groupingBy(WbsTreeContract::getPId));
-        for (Map.Entry<Long, List<WbsTreeContract>> entry : map.entrySet()) {
-            List<WbsTreeContract> wbsTreeContractList = entry.getValue();
-            for (WbsTreeContract contract : wbsTreeContractList) {
 
-            }
-        }
-        return false;
-    }
 }

+ 49 - 0
blade-service/blade-manager/src/main/java/org/springblade/manager/wrapper/AlbumWrapper.java

@@ -0,0 +1,49 @@
+/*
+ *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ *  Redistribution and use in source and binary forms, with or without
+ *  modification, are permitted provided that the following conditions are met:
+ *
+ *  Redistributions of source code must retain the above copyright notice,
+ *  this list of conditions and the following disclaimer.
+ *  Redistributions in binary form must reproduce the above copyright
+ *  notice, this list of conditions and the following disclaimer in the
+ *  documentation and/or other materials provided with the distribution.
+ *  Neither the name of the dreamlu.net developer nor the names of its
+ *  contributors may be used to endorse or promote products derived from
+ *  this software without specific prior written permission.
+ *  Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.manager.wrapper;
+
+import org.springblade.core.mp.support.BaseEntityWrapper;
+import org.springblade.core.tool.utils.BeanUtil;
+import org.springblade.manager.entity.Album;
+import org.springblade.manager.vo.AlbumVO;
+import java.util.Objects;
+
+/**
+ * 包装类,返回视图层所需的字段
+ *
+ * @author BladeX
+ * @since 2025-07-15
+ */
+public class AlbumWrapper extends BaseEntityWrapper<Album, AlbumVO>  {
+
+	public static AlbumWrapper build() {
+		return new AlbumWrapper();
+ 	}
+
+	@Override
+	public AlbumVO entityVO(Album album) {
+		AlbumVO albumVO = Objects.requireNonNull(BeanUtil.copy(album, AlbumVO.class));
+
+		//User createUser = UserCache.getUser(album.getCreateUser());
+		//User updateUser = UserCache.getUser(album.getUpdateUser());
+		//albumVO.setCreateUserName(createUser.getName());
+		//albumVO.setUpdateUserName(updateUser.getName());
+
+		return albumVO;
+	}
+
+}