From 72a372cb26c4ba489efae6b65dbf9fdfea1b5815 Mon Sep 17 00:00:00 2001
From: maven <2163098428@qq.com>
Date: 星期三, 19 十一月 2025 16:53:11 +0800
Subject: [PATCH] yys 1.劳保台账修改

---
 src/main/resources/mapper/staff/StaffJoinLeaveRecordMapper.xml                |   14 
 src/main/java/com/ruoyi/staff/pojo/StaffJoinLeaveRecord.java                  |    8 
 src/main/resources/mapper/device/DeviceMaintenanceMapper.xml                  |    3 
 src/main/java/com/ruoyi/device/dto/DeviceMaintenanceDto.java                  |    4 
 src/main/java/com/ruoyi/device/dto/DeviceRepairDto.java                       |    4 
 src/main/java/com/ruoyi/lavorissue/service/impl/DeptPositionServiceImpl.java  |  207 ++++++++++
 src/main/java/com/ruoyi/device/execl/DeviceMaintenanceExeclDto.java           |    6 
 src/main/java/com/ruoyi/lavorissue/pojo/LaborConf.java                        |   85 ++++
 src/main/java/com/ruoyi/lavorissue/mapper/DeptPositionMapper.java             |   14 
 src/main/java/com/ruoyi/device/service/impl/DeviceRepairServiceImpl.java      |  103 +++++
 src/main/resources/mapper/staff/StaffOnJobMapper.xml                          |   14 
 src/main/java/com/ruoyi/lavorissue/controller/DeptPositionController.java     |   99 +++++
 src/main/java/com/ruoyi/lavorissue/service/impl/LaborConfServiceImpl.java     |   29 +
 src/main/resources/mapper/lavorissue/LavorIssueMapper.xml                     |    8 
 src/main/java/com/ruoyi/device/service/IDeviceRepairService.java              |    7 
 src/main/java/com/ruoyi/device/service/impl/DeviceMaintenanceServiceImpl.java |  104 +++++
 src/main/java/com/ruoyi/lavorissue/service/LaborConfService.java              |   14 
 src/main/java/com/ruoyi/lavorissue/mapper/LaborConfMapper.java                |   15 
 src/main/java/com/ruoyi/device/controller/DeviceMaintenanceController.java    |   26 +
 src/main/java/com/ruoyi/device/mapper/DeviceMaintenanceMapper.java            |   30 +
 src/main/java/com/ruoyi/device/controller/DeviceRepairController.java         |   26 +
 src/main/java/com/ruoyi/device/dto/RepairAmountGroupDTO.java                  |   23 +
 src/main/java/com/ruoyi/device/service/IDeviceMaintenanceService.java         |    7 
 src/main/java/com/ruoyi/lavorissue/service/DeptPositionService.java           |   27 +
 src/main/java/com/ruoyi/lavorissue/pojo/DeptPosition.java                     |   80 ++++
 src/main/java/com/ruoyi/device/pojo/DeviceRepair.java                         |    3 
 src/main/java/com/ruoyi/lavorissue/pojo/LaborIssue.java                       |   12 
 src/main/resources/application-jyhjCopy.yml                                   |    4 
 src/main/java/com/ruoyi/device/mapper/DeviceRepairMapper.java                 |   31 +
 src/main/java/com/ruoyi/staff/pojo/StaffOnJob.java                            |    8 
 src/main/java/com/ruoyi/device/dto/DeviceMonthlyRepairTableDTO.java           |   29 +
 src/main/resources/mapper/device/DeviceRepairMapper.xml                       |    1 
 src/main/resources/mapper/lavorissue/LaborConfMapper.xml                      |   17 
 src/main/java/com/ruoyi/device/execl/DeviceRepairExeclDto.java                |    5 
 src/main/java/com/ruoyi/lavorissue/controller/LaborConfController.java        |   58 +++
 src/main/java/com/ruoyi/device/pojo/DeviceMaintenance.java                    |    4 
 36 files changed, 1,099 insertions(+), 30 deletions(-)

diff --git a/src/main/java/com/ruoyi/device/controller/DeviceMaintenanceController.java b/src/main/java/com/ruoyi/device/controller/DeviceMaintenanceController.java
index 37ce27d..47521e7 100644
--- a/src/main/java/com/ruoyi/device/controller/DeviceMaintenanceController.java
+++ b/src/main/java/com/ruoyi/device/controller/DeviceMaintenanceController.java
@@ -3,7 +3,9 @@
 
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.ruoyi.device.dto.DeviceMaintenanceDto;
+import com.ruoyi.device.dto.DeviceMonthlyRepairTableDTO;
 import com.ruoyi.device.dto.DeviceRepairDto;
+import com.ruoyi.device.dto.RepairAmountGroupDTO;
 import com.ruoyi.device.pojo.DeviceLedger;
 import com.ruoyi.device.pojo.DeviceMaintenance;
 import com.ruoyi.device.pojo.DeviceRepair;
@@ -19,6 +21,7 @@
 import javax.servlet.http.HttpServletResponse;
 import java.util.ArrayList;
 import java.util.Arrays;
+import java.util.List;
 
 @Api(tags = "璁惧淇濆吇")
 @RestController
@@ -87,4 +90,27 @@
     }
 
 
+    /**
+     * 鎸夊勾浠芥煡璇㈡瘡鏈堟姤淇噾棰濓紙鎸夎澶囧彴璐﹀垎缁勶級
+     * @param year 鍓嶇浼犲叆鐨勫勾浠斤紙濡�2025锛�
+     */
+    @GetMapping("/monthlyAmount")
+    @ApiModelProperty("鎸夊勾浠芥煡璇㈡瘡鏈堟姤淇噾棰濓紙鎸夎澶囧彴璐﹀垎缁勶級")
+    public AjaxResult getMonthlyAmount(@RequestParam(defaultValue = "2025", required = true,name = "year") String year) {
+        List<DeviceMonthlyRepairTableDTO> result = deviceMaintenanceService.getMonthlyRepairAmountByYear(year);
+        return AjaxResult.success(result);
+    }
+
+    /**
+     * 鎸夊勾浠芥煡璇㈡姤淇噾棰濓紙鎸夎澶囧彴璐﹀垎缁勶級
+     * @param year 鍓嶇浼犲叆鐨勫勾浠斤紙濡�2025锛�
+     */
+    @GetMapping("/yearlyAmount")
+    @ApiModelProperty("鎸夊勾浠芥煡璇㈡姤淇噾棰濓紙鎸夎澶囧彴璐﹀垎缁勶級")
+    public AjaxResult yearlyAmount(@RequestParam(defaultValue = "2025", required = true,name = "year") String year) {
+        List<RepairAmountGroupDTO> result = deviceMaintenanceService.getRepairAmountByYear(year);
+        return AjaxResult.success(result);
+    }
+
+
 }
diff --git a/src/main/java/com/ruoyi/device/controller/DeviceRepairController.java b/src/main/java/com/ruoyi/device/controller/DeviceRepairController.java
index 5c3dd58..7b386bd 100644
--- a/src/main/java/com/ruoyi/device/controller/DeviceRepairController.java
+++ b/src/main/java/com/ruoyi/device/controller/DeviceRepairController.java
@@ -2,7 +2,9 @@
 
 
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.ruoyi.device.dto.DeviceMonthlyRepairTableDTO;
 import com.ruoyi.device.dto.DeviceRepairDto;
+import com.ruoyi.device.dto.RepairAmountGroupDTO;
 import com.ruoyi.device.pojo.DeviceLedger;
 import com.ruoyi.device.pojo.DeviceRepair;
 import com.ruoyi.device.service.IDeviceLedgerService;
@@ -16,6 +18,7 @@
 import javax.servlet.http.HttpServletResponse;
 import java.util.ArrayList;
 import java.util.Arrays;
+import java.util.List;
 
 @Api(tags = "璁惧鎶ヤ慨绠$悊")
 @RequestMapping("/device/repair")
@@ -75,4 +78,27 @@
     public void export(HttpServletResponse response, Long[] ids) {
         deviceRepairService.export(response, ids);
     }
+
+    /**
+     * 鎸夊勾浠芥煡璇㈡瘡鏈堟姤淇噾棰濓紙鎸夎澶囧彴璐﹀垎缁勶級
+     * @param year 鍓嶇浼犲叆鐨勫勾浠斤紙濡�2025锛�
+     */
+    @GetMapping("/monthlyAmount")
+    @ApiModelProperty("鎸夊勾浠芥煡璇㈡瘡鏈堟姤淇噾棰濓紙鎸夎澶囧彴璐﹀垎缁勶級")
+    public AjaxResult getMonthlyAmount(@RequestParam(defaultValue = "2025", required = true,name = "year") String year) {
+        List<DeviceMonthlyRepairTableDTO> result = deviceRepairService.getMonthlyRepairAmountByYear(year);
+        return AjaxResult.success(result);
+    }
+
+    /**
+     * 鎸夊勾浠芥煡璇㈡姤淇噾棰濓紙鎸夎澶囧彴璐﹀垎缁勶級
+     * @param year 鍓嶇浼犲叆鐨勫勾浠斤紙濡�2025锛�
+     */
+    @GetMapping("/yearlyAmount")
+    @ApiModelProperty("鎸夊勾浠芥煡璇㈡姤淇噾棰濓紙鎸夎澶囧彴璐﹀垎缁勶級")
+    public AjaxResult yearlyAmount(@RequestParam(defaultValue = "2025", required = true,name = "year") String year) {
+        List<RepairAmountGroupDTO> result = deviceRepairService.getRepairAmountByYear(year);
+        return AjaxResult.success(result);
+    }
+
 }
diff --git a/src/main/java/com/ruoyi/device/dto/DeviceMaintenanceDto.java b/src/main/java/com/ruoyi/device/dto/DeviceMaintenanceDto.java
index cae0715..f1bc18e 100644
--- a/src/main/java/com/ruoyi/device/dto/DeviceMaintenanceDto.java
+++ b/src/main/java/com/ruoyi/device/dto/DeviceMaintenanceDto.java
@@ -5,6 +5,7 @@
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 
+import java.math.BigDecimal;
 import java.time.LocalDateTime;
 import java.util.Date;
 
@@ -16,6 +17,9 @@
 
     private Long id;
 
+    @ApiModelProperty("璁惧淇濆吇閲戦")
+    private BigDecimal maintenancePrice;
+
     @ApiModelProperty("璁惧鍙拌处id")
     private Long deviceLedgerId;
 
diff --git a/src/main/java/com/ruoyi/device/dto/DeviceMonthlyRepairTableDTO.java b/src/main/java/com/ruoyi/device/dto/DeviceMonthlyRepairTableDTO.java
new file mode 100644
index 0000000..bb5be4b
--- /dev/null
+++ b/src/main/java/com/ruoyi/device/dto/DeviceMonthlyRepairTableDTO.java
@@ -0,0 +1,29 @@
+package com.ruoyi.device.dto;
+
+import lombok.Data;
+
+import java.math.BigDecimal;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 10:58
+ */
+@Data
+public class DeviceMonthlyRepairTableDTO {
+
+    private String deviceName; // 璁惧鍚嶇О
+    private BigDecimal month1; // 1鏈堥噾棰�
+    private BigDecimal month2; // 2鏈堥噾棰�
+    private BigDecimal month3; // 3鏈堥噾棰�
+    private BigDecimal month4; // 4鏈堥噾棰�
+    private BigDecimal month5; // 5鏈堥噾棰�
+    private BigDecimal month6; // 6鏈堥噾棰�
+    private BigDecimal month7; // 7鏈堥噾棰�
+    private BigDecimal month8; // 8鏈堥噾棰�
+    private BigDecimal month9; // 9鏈堥噾棰�
+    private BigDecimal month10; // 10鏈堥噾棰�
+    private BigDecimal month11; // 11鏈堥噾棰�
+    private BigDecimal month12; // 12鏈堥噾棰�
+    private BigDecimal total; // 鎬昏
+
+}
diff --git a/src/main/java/com/ruoyi/device/dto/DeviceRepairDto.java b/src/main/java/com/ruoyi/device/dto/DeviceRepairDto.java
index 92cfe8c..560d87e 100644
--- a/src/main/java/com/ruoyi/device/dto/DeviceRepairDto.java
+++ b/src/main/java/com/ruoyi/device/dto/DeviceRepairDto.java
@@ -6,6 +6,7 @@
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 
+import java.math.BigDecimal;
 import java.time.LocalDateTime;
 import java.util.Date;
 
@@ -18,6 +19,9 @@
     @ApiModelProperty("璁惧鍙拌处id")
     private Long deviceLedgerId;
 
+    @ApiModelProperty("鎶ヤ慨閲戦")
+    private BigDecimal repairPrice;
+
     @ApiModelProperty("璁惧鍚嶇О")
     private String deviceName;
 
diff --git a/src/main/java/com/ruoyi/device/dto/RepairAmountGroupDTO.java b/src/main/java/com/ruoyi/device/dto/RepairAmountGroupDTO.java
new file mode 100644
index 0000000..ed1e1bc
--- /dev/null
+++ b/src/main/java/com/ruoyi/device/dto/RepairAmountGroupDTO.java
@@ -0,0 +1,23 @@
+package com.ruoyi.device.dto;
+
+import lombok.Data;
+
+import java.math.BigDecimal;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 10:44
+ */
+@Data
+public class RepairAmountGroupDTO {
+
+    // 骞存湀锛堟牸寮忥細MM锛�
+    private String repairYearMonth;
+    // 璁惧鍙拌处id
+    private Long deviceLedgerId;
+    // 璁惧鍙拌处鍚嶇О
+    private String deviceName;
+    // 璇ヨ澶囨姤淇噾棰濇�诲拰
+    private BigDecimal totalRepairPrice;
+
+}
diff --git a/src/main/java/com/ruoyi/device/execl/DeviceMaintenanceExeclDto.java b/src/main/java/com/ruoyi/device/execl/DeviceMaintenanceExeclDto.java
index 6cd3316..8bf980a 100644
--- a/src/main/java/com/ruoyi/device/execl/DeviceMaintenanceExeclDto.java
+++ b/src/main/java/com/ruoyi/device/execl/DeviceMaintenanceExeclDto.java
@@ -4,6 +4,7 @@
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 
+import java.math.BigDecimal;
 import java.time.LocalDateTime;
 import java.util.Date;
 
@@ -17,6 +18,11 @@
     @Excel(name = "璁惧鍚嶇О")
     private String deviceName;
 
+
+    @ApiModelProperty("璁惧淇濆吇閲戦")
+    @Excel(name = "璁惧淇濆吇閲戦")
+    private BigDecimal maintenancePrice;
+
     @Excel(name = "瑙勬牸鍨嬪彿")
     @ApiModelProperty("瑙勬牸鍨嬪彿")
     private String deviceModel;
diff --git a/src/main/java/com/ruoyi/device/execl/DeviceRepairExeclDto.java b/src/main/java/com/ruoyi/device/execl/DeviceRepairExeclDto.java
index a1b15f3..d40eb24 100644
--- a/src/main/java/com/ruoyi/device/execl/DeviceRepairExeclDto.java
+++ b/src/main/java/com/ruoyi/device/execl/DeviceRepairExeclDto.java
@@ -7,6 +7,7 @@
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
 
+import java.math.BigDecimal;
 import java.time.LocalDateTime;
 import java.util.Date;
 
@@ -17,6 +18,10 @@
     @Excel(name = "璁惧鍚嶇О")
     private String deviceName;
 
+    @ApiModelProperty("鎶ヤ慨閲戦")
+    @Excel(name = "鎶ヤ慨閲戦")
+    private BigDecimal repairPrice;
+
     @ApiModelProperty("璁惧鍨嬪彿")
     @Excel(name = "璁惧鍨嬪彿")
     private String deviceModel;
diff --git a/src/main/java/com/ruoyi/device/mapper/DeviceMaintenanceMapper.java b/src/main/java/com/ruoyi/device/mapper/DeviceMaintenanceMapper.java
index 86c726b..4225bf0 100644
--- a/src/main/java/com/ruoyi/device/mapper/DeviceMaintenanceMapper.java
+++ b/src/main/java/com/ruoyi/device/mapper/DeviceMaintenanceMapper.java
@@ -7,8 +7,11 @@
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.ruoyi.device.dto.DeviceMaintenanceDto;
 import com.ruoyi.device.dto.DeviceRepairDto;
+import com.ruoyi.device.dto.RepairAmountGroupDTO;
 import com.ruoyi.device.pojo.DeviceMaintenance;
 import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+import org.apache.ibatis.annotations.Select;
 
 import java.util.List;
 
@@ -21,4 +24,31 @@
 
     @InterceptorIgnore(tenantLine = "true")
     List<DeviceMaintenance> list1(Long id);
+
+    /**
+     * 鎸夆�滄寚瀹氬勾浠界殑骞存湀+璁惧鍙拌处id鈥濆垎缁勶紝姹傚拰鎶ヤ慨閲戦
+     * @param year 鍓嶇浼犲叆鐨勫勾浠斤紙濡�"2025"锛�
+     */
+    @Select("SELECT " +
+            "  DATE_FORMAT(maintenance_actually_time, '%m') AS repairYearMonth, " +
+            "  device_ledger_id AS deviceLedgerId, " +
+            "  SUM(maintenance_price) AS totalRepairPrice " +
+            "FROM device_maintenance " +
+            "WHERE DATE_FORMAT(maintenance_actually_time, '%Y') = #{year} " + // 鍙煡璇㈡寚瀹氬勾浠界殑鏁版嵁
+            "GROUP BY device_ledger_id,DATE_FORMAT(maintenance_actually_time, '%Y-%m')  " +
+            "ORDER BY repairYearMonth ASC") // 鎸夋湀浠芥帓搴忥紝鏂逛究鍓嶇灞曠ず
+    List<RepairAmountGroupDTO> groupByMonthAndDeviceLedger(@Param("year") String year);
+
+    /**
+     * 鎸夆�滆澶囧彴璐d鈥濆垎缁勶紝姹傚拰鎶ヤ慨閲戦
+     * @param year 鍓嶇浼犲叆鐨勫勾浠斤紙濡�"2025"锛�
+     */
+    @Select("SELECT " +
+            "  device_ledger_id AS deviceLedgerId, " +
+            "  SUM(maintenance_price) AS totalRepairPrice " +
+            "FROM device_maintenance " +
+            "WHERE DATE_FORMAT(maintenance_actually_time, '%Y') = #{year} " + // 鍙煡璇㈡寚瀹氬勾浠界殑鏁版嵁
+            "GROUP BY device_ledger_id ") // 鎸夋湀浠芥帓搴忥紝鏂逛究鍓嶇灞曠ず
+    List<RepairAmountGroupDTO> groupByDeviceLedger(@Param("year") String year);
+
 }
diff --git a/src/main/java/com/ruoyi/device/mapper/DeviceRepairMapper.java b/src/main/java/com/ruoyi/device/mapper/DeviceRepairMapper.java
index cbfcbcd..0c34e69 100644
--- a/src/main/java/com/ruoyi/device/mapper/DeviceRepairMapper.java
+++ b/src/main/java/com/ruoyi/device/mapper/DeviceRepairMapper.java
@@ -4,13 +4,44 @@
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.ruoyi.device.dto.DeviceRepairDto;
+import com.ruoyi.device.dto.RepairAmountGroupDTO;
 import com.ruoyi.device.pojo.DeviceRepair;
 import org.apache.ibatis.annotations.Mapper;
 import org.apache.ibatis.annotations.Param;
+import org.apache.ibatis.annotations.Select;
+
+import java.util.List;
 
 @Mapper
 public interface DeviceRepairMapper extends BaseMapper<DeviceRepair> {
     IPage<DeviceRepairDto> queryPage(Page page, @Param("deviceRepairDto") DeviceRepairDto deviceRepairDto);
 
     DeviceRepairDto detailById(Long id);
+
+
+    /**
+     * 鎸夆�滄寚瀹氬勾浠界殑骞存湀+璁惧鍙拌处id鈥濆垎缁勶紝姹傚拰鎶ヤ慨閲戦
+     * @param year 鍓嶇浼犲叆鐨勫勾浠斤紙濡�"2025"锛�
+     */
+    @Select("SELECT " +
+            "  DATE_FORMAT(repair_time, '%m') AS repairYearMonth, " +
+            "  device_ledger_id AS deviceLedgerId, " +
+            "  SUM(repair_price) AS totalRepairPrice " +
+            "FROM device_repair " +
+            "WHERE DATE_FORMAT(repair_time, '%Y') = #{year} " + // 鍙煡璇㈡寚瀹氬勾浠界殑鏁版嵁
+            "GROUP BY device_ledger_id,DATE_FORMAT(repair_time, '%Y-%m')  " +
+            "ORDER BY repairYearMonth ASC") // 鎸夋湀浠芥帓搴忥紝鏂逛究鍓嶇灞曠ず
+    List<RepairAmountGroupDTO> groupByMonthAndDeviceLedger(@Param("year") String year);
+
+    /**
+     * 鎸夆�滆澶囧彴璐d鈥濆垎缁勶紝姹傚拰鎶ヤ慨閲戦
+     * @param year 鍓嶇浼犲叆鐨勫勾浠斤紙濡�"2025"锛�
+     */
+    @Select("SELECT " +
+            "  device_ledger_id AS deviceLedgerId, " +
+            "  SUM(repair_price) AS totalRepairPrice " +
+            "FROM device_repair " +
+            "WHERE DATE_FORMAT(repair_time, '%Y') = #{year} " + // 鍙煡璇㈡寚瀹氬勾浠界殑鏁版嵁
+            "GROUP BY device_ledger_id ") // 鎸夋湀浠芥帓搴忥紝鏂逛究鍓嶇灞曠ず
+    List<RepairAmountGroupDTO> groupByDeviceLedger(@Param("year") String year);
 }
diff --git a/src/main/java/com/ruoyi/device/pojo/DeviceMaintenance.java b/src/main/java/com/ruoyi/device/pojo/DeviceMaintenance.java
index f5d5463..4b7a971 100644
--- a/src/main/java/com/ruoyi/device/pojo/DeviceMaintenance.java
+++ b/src/main/java/com/ruoyi/device/pojo/DeviceMaintenance.java
@@ -8,6 +8,7 @@
 import lombok.Data;
 import org.springframework.format.annotation.DateTimeFormat;
 
+import java.math.BigDecimal;
 import java.time.LocalDateTime;
 import java.util.Date;
 
@@ -22,6 +23,9 @@
     @ApiModelProperty("璁惧鍙拌处id")
     private Long deviceLedgerId;
 
+    @ApiModelProperty("璁惧淇濆吇閲戦")
+    private BigDecimal maintenancePrice;
+
 
     private String deviceName;
 
diff --git a/src/main/java/com/ruoyi/device/pojo/DeviceRepair.java b/src/main/java/com/ruoyi/device/pojo/DeviceRepair.java
index 5804519..06b672c 100644
--- a/src/main/java/com/ruoyi/device/pojo/DeviceRepair.java
+++ b/src/main/java/com/ruoyi/device/pojo/DeviceRepair.java
@@ -25,6 +25,9 @@
     @ApiModelProperty("璁惧鍙拌处id")
     private Long deviceLedgerId;
 
+    @ApiModelProperty("鎶ヤ慨閲戦")
+    private BigDecimal repairPrice;
+
     private String deviceName;
 
     private String deviceModel;
diff --git a/src/main/java/com/ruoyi/device/service/IDeviceMaintenanceService.java b/src/main/java/com/ruoyi/device/service/IDeviceMaintenanceService.java
index 82db913..6a2e027 100644
--- a/src/main/java/com/ruoyi/device/service/IDeviceMaintenanceService.java
+++ b/src/main/java/com/ruoyi/device/service/IDeviceMaintenanceService.java
@@ -4,10 +4,13 @@
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.baomidou.mybatisplus.extension.service.IService;
 import com.ruoyi.device.dto.DeviceMaintenanceDto;
+import com.ruoyi.device.dto.DeviceMonthlyRepairTableDTO;
+import com.ruoyi.device.dto.RepairAmountGroupDTO;
 import com.ruoyi.device.pojo.DeviceMaintenance;
 import com.ruoyi.framework.web.domain.AjaxResult;
 
 import javax.servlet.http.HttpServletResponse;
+import java.util.List;
 
 public interface IDeviceMaintenanceService extends IService<DeviceMaintenance> {
 
@@ -20,4 +23,8 @@
     void export(HttpServletResponse response, Long[] ids);
 
     DeviceMaintenanceDto detailById(Long id);
+
+    List<DeviceMonthlyRepairTableDTO> getMonthlyRepairAmountByYear(String year);
+
+    List<RepairAmountGroupDTO> getRepairAmountByYear(String year);
 }
diff --git a/src/main/java/com/ruoyi/device/service/IDeviceRepairService.java b/src/main/java/com/ruoyi/device/service/IDeviceRepairService.java
index 5877ffd..a065903 100644
--- a/src/main/java/com/ruoyi/device/service/IDeviceRepairService.java
+++ b/src/main/java/com/ruoyi/device/service/IDeviceRepairService.java
@@ -3,11 +3,14 @@
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.baomidou.mybatisplus.extension.service.IService;
+import com.ruoyi.device.dto.DeviceMonthlyRepairTableDTO;
 import com.ruoyi.device.dto.DeviceRepairDto;
+import com.ruoyi.device.dto.RepairAmountGroupDTO;
 import com.ruoyi.device.pojo.DeviceRepair;
 import com.ruoyi.framework.web.domain.AjaxResult;
 
 import javax.servlet.http.HttpServletResponse;
+import java.util.List;
 
 
 public interface IDeviceRepairService extends IService<DeviceRepair> {
@@ -21,4 +24,8 @@
     void export(HttpServletResponse response, Long[] ids);
 
     DeviceRepairDto detailById(Long id);
+
+    List<DeviceMonthlyRepairTableDTO> getMonthlyRepairAmountByYear(String year);
+
+    List<RepairAmountGroupDTO> getRepairAmountByYear(String year);
 }
diff --git a/src/main/java/com/ruoyi/device/service/impl/DeviceMaintenanceServiceImpl.java b/src/main/java/com/ruoyi/device/service/impl/DeviceMaintenanceServiceImpl.java
index 011d32b..8cfe235 100644
--- a/src/main/java/com/ruoyi/device/service/impl/DeviceMaintenanceServiceImpl.java
+++ b/src/main/java/com/ruoyi/device/service/impl/DeviceMaintenanceServiceImpl.java
@@ -7,18 +7,24 @@
 import com.ruoyi.common.utils.bean.BeanUtils;
 import com.ruoyi.common.utils.poi.ExcelUtil;
 import com.ruoyi.device.dto.DeviceMaintenanceDto;
+import com.ruoyi.device.dto.DeviceMonthlyRepairTableDTO;
+import com.ruoyi.device.dto.RepairAmountGroupDTO;
 import com.ruoyi.device.execl.DeviceMaintenanceExeclDto;
+import com.ruoyi.device.mapper.DeviceLedgerMapper;
 import com.ruoyi.device.mapper.DeviceMaintenanceMapper;
+import com.ruoyi.device.pojo.DeviceLedger;
 import com.ruoyi.device.pojo.DeviceMaintenance;
 import com.ruoyi.device.service.IDeviceMaintenanceService;
 import com.ruoyi.framework.web.domain.AjaxResult;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
 
 import javax.servlet.http.HttpServletResponse;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
+import java.math.BigDecimal;
+import java.util.*;
+import java.util.stream.Collectors;
+import java.util.stream.Stream;
 
 
 @Service
@@ -73,4 +79,96 @@
 
         return deviceMaintenanceMapper.detailById(id);
     }
+
+    @Autowired
+    private DeviceLedgerMapper deviceLedgerMapper;
+
+    @Override
+    public List<DeviceMonthlyRepairTableDTO> getMonthlyRepairAmountByYear(String year) {
+        List<RepairAmountGroupDTO> repairAmountGroupDTOS = deviceMaintenanceMapper.groupByMonthAndDeviceLedger(year);
+        // 1. 鍏堥�氳繃璁惧鍙拌处id鍏宠仈璁惧鍚嶇О锛堝鏋淩epairAmountGroupDTO娌℃湁deviceName锛岄渶鍏堟煡璁惧鍙拌处琛級
+        // 杩欓噷鍋囪浣犺兘閫氳繃deviceLedgerId鑾峰彇鍒癲eviceName锛屾瘮濡傦細
+        Map<Long, String> deviceNameMap = new HashMap<>(); // key:deviceLedgerId, value:deviceName
+        // 锛堝疄闄呴渶璋冪敤璁惧鍙拌处鐨凪apper鏌ヨ锛歞eviceNameMap = deviceLedgerMapper.listAll().stream().collect(Collectors.toMap(DeviceLedger::getId, DeviceLedger::getDeviceName))锛�
+        deviceNameMap = deviceLedgerMapper.selectList(null)
+                .stream()
+                .collect(Collectors.toMap(DeviceLedger::getId, DeviceLedger::getDeviceName));
+        if(CollectionUtils.isEmpty(deviceNameMap)){
+            return Collections.emptyList();
+        }
+        // 2. 鎸夎澶囧悕绉板垎缁勶紝瀛樺偍姣忎釜璁惧鐨勫悇鏈堥噾棰�
+        Map<String, DeviceMonthlyRepairTableDTO> deviceTableMap = new HashMap<>();
+
+        for (RepairAmountGroupDTO dto : repairAmountGroupDTOS) {
+            // 鎷嗗垎repairYearMonth涓烘湀浠斤紙濡�"2025-01" 鈫� "01" 鈫� 1锛�
+            String yearMonth = dto.getRepairYearMonth(); // 鏍煎紡锛歽yyy-MM
+            int month = Integer.parseInt(yearMonth); // 鎻愬彇MM骞惰浆鎴愭暟瀛楋紙1-12锛�
+
+            // 鑾峰彇璁惧鍚嶇О
+            String deviceName = deviceNameMap.get(dto.getDeviceLedgerId());
+            if (deviceName == null) {
+                deviceName = "鏈煡璁惧"; // 鍏滃簳
+            }
+
+            // 浠嶮ap涓幏鍙栬璁惧鐨勮〃鏍糄TO锛屼笉瀛樺湪鍒欏垵濮嬪寲
+            DeviceMonthlyRepairTableDTO tableDTO = deviceTableMap.getOrDefault(deviceName, new DeviceMonthlyRepairTableDTO());
+            tableDTO.setDeviceName(deviceName);
+
+            // 鏍规嵁鏈堜唤濉厖閲戦锛圔igDecimal榛樿0锛岄伩鍏峮ull锛�
+            BigDecimal amount = dto.getTotalRepairPrice() == null ? BigDecimal.ZERO : dto.getTotalRepairPrice();
+            switch (month) {
+                case 1: tableDTO.setMonth1(amount); break;
+                case 2: tableDTO.setMonth2(amount); break;
+                case 3: tableDTO.setMonth3(amount); break;
+                case 4: tableDTO.setMonth4(amount); break;
+                case 5: tableDTO.setMonth5(amount); break;
+                case 6: tableDTO.setMonth6(amount); break;
+                case 7: tableDTO.setMonth7(amount); break;
+                case 8: tableDTO.setMonth8(amount); break;
+                case 9: tableDTO.setMonth9(amount); break;
+                case 10: tableDTO.setMonth10(amount); break;
+                case 11: tableDTO.setMonth11(amount); break;
+                case 12: tableDTO.setMonth12(amount); break;
+            }
+
+            // 閲嶆柊鏀惧叆Map
+            deviceTableMap.put(deviceName, tableDTO);
+        }
+
+
+        // 3. 璁$畻姣忎釜璁惧鐨勬�昏锛屽苟琛ュ厖搴忓彿
+        List<DeviceMonthlyRepairTableDTO> resultList = new ArrayList<>();
+        for (DeviceMonthlyRepairTableDTO tableDTO : deviceTableMap.values()) {
+            // 璁$畻鎬昏锛�1-12鏈堥噾棰濈浉鍔�
+            BigDecimal total = Stream.of(
+                            tableDTO.getMonth1(), tableDTO.getMonth2(), tableDTO.getMonth3(),
+                            tableDTO.getMonth4(), tableDTO.getMonth5(), tableDTO.getMonth6(),
+                            tableDTO.getMonth7(), tableDTO.getMonth8(), tableDTO.getMonth9(),
+                            tableDTO.getMonth10(), tableDTO.getMonth11(), tableDTO.getMonth12()
+                    )
+                    .map(amt -> amt == null ? BigDecimal.ZERO : amt)
+                    .reduce(BigDecimal.ZERO, BigDecimal::add);
+            tableDTO.setTotal(total);
+            resultList.add(tableDTO);
+        }
+        return resultList;
+    }
+
+    @Override
+    public List<RepairAmountGroupDTO> getRepairAmountByYear(String year) {
+        List<RepairAmountGroupDTO> repairAmountGroupDTOS = deviceMaintenanceMapper.groupByDeviceLedger(year);
+        Map<Long, String> deviceNameMap = new HashMap<>(); // key:deviceLedgerId, value:deviceName
+        // 锛堝疄闄呴渶璋冪敤璁惧鍙拌处鐨凪apper鏌ヨ锛歞eviceNameMap = deviceLedgerMapper.listAll().stream().collect(Collectors.toMap(DeviceLedger::getId, DeviceLedger::getDeviceName))锛�
+        deviceNameMap = deviceLedgerMapper.selectList(null)
+                .stream()
+                .collect(Collectors.toMap(DeviceLedger::getId, DeviceLedger::getDeviceName));
+        if(CollectionUtils.isEmpty(deviceNameMap)){
+            return Collections.emptyList();
+        }
+        Map<Long, String> finalDeviceNameMap = deviceNameMap;
+        repairAmountGroupDTOS.forEach(dto -> {
+            dto.setDeviceName(finalDeviceNameMap.get(dto.getDeviceLedgerId()));
+        });
+        return repairAmountGroupDTOS;
+    }
 }
diff --git a/src/main/java/com/ruoyi/device/service/impl/DeviceRepairServiceImpl.java b/src/main/java/com/ruoyi/device/service/impl/DeviceRepairServiceImpl.java
index 1f09d07..c771b47 100644
--- a/src/main/java/com/ruoyi/device/service/impl/DeviceRepairServiceImpl.java
+++ b/src/main/java/com/ruoyi/device/service/impl/DeviceRepairServiceImpl.java
@@ -6,9 +6,12 @@
 import com.ruoyi.common.utils.bean.BeanUtils;
 import com.ruoyi.common.utils.poi.ExcelUtil;
 import com.ruoyi.device.dto.DeviceDefectRecordDto;
+import com.ruoyi.device.dto.DeviceMonthlyRepairTableDTO;
 import com.ruoyi.device.dto.DeviceRepairDto;
+import com.ruoyi.device.dto.RepairAmountGroupDTO;
 import com.ruoyi.device.execl.DeviceRepairExeclDto;
 import com.ruoyi.device.mapper.DeviceDefectRecordMapper;
+import com.ruoyi.device.mapper.DeviceLedgerMapper;
 import com.ruoyi.device.mapper.DeviceRepairMapper;
 import com.ruoyi.device.pojo.DeviceDefectRecord;
 import com.ruoyi.device.pojo.DeviceLedger;
@@ -21,11 +24,13 @@
 import lombok.extern.slf4j.Slf4j;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
 
 import javax.servlet.http.HttpServletResponse;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
+import java.math.BigDecimal;
+import java.util.*;
+import java.util.stream.Collectors;
+import java.util.stream.Stream;
 
 @Service
 @AllArgsConstructor
@@ -116,4 +121,96 @@
         return deviceRepairMapper.detailById(id);
     }
 
+    @Autowired
+    private DeviceLedgerMapper deviceLedgerMapper;
+
+    @Override
+    public List<DeviceMonthlyRepairTableDTO> getMonthlyRepairAmountByYear(String year) {
+        List<RepairAmountGroupDTO> repairAmountGroupDTOS = deviceRepairMapper.groupByMonthAndDeviceLedger(year);
+        // 1. 鍏堥�氳繃璁惧鍙拌处id鍏宠仈璁惧鍚嶇О锛堝鏋淩epairAmountGroupDTO娌℃湁deviceName锛岄渶鍏堟煡璁惧鍙拌处琛級
+        // 杩欓噷鍋囪浣犺兘閫氳繃deviceLedgerId鑾峰彇鍒癲eviceName锛屾瘮濡傦細
+        Map<Long, String> deviceNameMap = new HashMap<>(); // key:deviceLedgerId, value:deviceName
+        // 锛堝疄闄呴渶璋冪敤璁惧鍙拌处鐨凪apper鏌ヨ锛歞eviceNameMap = deviceLedgerMapper.listAll().stream().collect(Collectors.toMap(DeviceLedger::getId, DeviceLedger::getDeviceName))锛�
+        deviceNameMap = deviceLedgerMapper.selectList(null)
+                .stream()
+                .collect(Collectors.toMap(DeviceLedger::getId, DeviceLedger::getDeviceName));
+        if(CollectionUtils.isEmpty(deviceNameMap)){
+            return Collections.emptyList();
+        }
+        // 2. 鎸夎澶囧悕绉板垎缁勶紝瀛樺偍姣忎釜璁惧鐨勫悇鏈堥噾棰�
+        Map<String, DeviceMonthlyRepairTableDTO> deviceTableMap = new HashMap<>();
+
+        for (RepairAmountGroupDTO dto : repairAmountGroupDTOS) {
+            // 鎷嗗垎repairYearMonth涓烘湀浠斤紙濡�"2025-01" 鈫� "01" 鈫� 1锛�
+            String yearMonth = dto.getRepairYearMonth(); // 鏍煎紡锛歽yyy-MM
+            int month = Integer.parseInt(yearMonth); // 鎻愬彇MM骞惰浆鎴愭暟瀛楋紙1-12锛�
+
+            // 鑾峰彇璁惧鍚嶇О
+            String deviceName = deviceNameMap.get(dto.getDeviceLedgerId());
+            if (deviceName == null) {
+                deviceName = "鏈煡璁惧"; // 鍏滃簳
+            }
+
+            // 浠嶮ap涓幏鍙栬璁惧鐨勮〃鏍糄TO锛屼笉瀛樺湪鍒欏垵濮嬪寲
+            DeviceMonthlyRepairTableDTO tableDTO = deviceTableMap.getOrDefault(deviceName, new DeviceMonthlyRepairTableDTO());
+            tableDTO.setDeviceName(deviceName);
+
+            // 鏍规嵁鏈堜唤濉厖閲戦锛圔igDecimal榛樿0锛岄伩鍏峮ull锛�
+            BigDecimal amount = dto.getTotalRepairPrice() == null ? BigDecimal.ZERO : dto.getTotalRepairPrice();
+            switch (month) {
+                case 1: tableDTO.setMonth1(amount); break;
+                case 2: tableDTO.setMonth2(amount); break;
+                case 3: tableDTO.setMonth3(amount); break;
+                case 4: tableDTO.setMonth4(amount); break;
+                case 5: tableDTO.setMonth5(amount); break;
+                case 6: tableDTO.setMonth6(amount); break;
+                case 7: tableDTO.setMonth7(amount); break;
+                case 8: tableDTO.setMonth8(amount); break;
+                case 9: tableDTO.setMonth9(amount); break;
+                case 10: tableDTO.setMonth10(amount); break;
+                case 11: tableDTO.setMonth11(amount); break;
+                case 12: tableDTO.setMonth12(amount); break;
+            }
+
+            // 閲嶆柊鏀惧叆Map
+            deviceTableMap.put(deviceName, tableDTO);
+        }
+
+
+        // 3. 璁$畻姣忎釜璁惧鐨勬�昏锛屽苟琛ュ厖搴忓彿
+        List<DeviceMonthlyRepairTableDTO> resultList = new ArrayList<>();
+        for (DeviceMonthlyRepairTableDTO tableDTO : deviceTableMap.values()) {
+            // 璁$畻鎬昏锛�1-12鏈堥噾棰濈浉鍔�
+            BigDecimal total = Stream.of(
+                            tableDTO.getMonth1(), tableDTO.getMonth2(), tableDTO.getMonth3(),
+                            tableDTO.getMonth4(), tableDTO.getMonth5(), tableDTO.getMonth6(),
+                            tableDTO.getMonth7(), tableDTO.getMonth8(), tableDTO.getMonth9(),
+                            tableDTO.getMonth10(), tableDTO.getMonth11(), tableDTO.getMonth12()
+                    )
+                    .map(amt -> amt == null ? BigDecimal.ZERO : amt)
+                    .reduce(BigDecimal.ZERO, BigDecimal::add);
+            tableDTO.setTotal(total);
+            resultList.add(tableDTO);
+        }
+        return resultList;
+    }
+
+    @Override
+    public List<RepairAmountGroupDTO> getRepairAmountByYear(String year) {
+        List<RepairAmountGroupDTO> repairAmountGroupDTOS = deviceRepairMapper.groupByDeviceLedger(year);
+        Map<Long, String> deviceNameMap = new HashMap<>(); // key:deviceLedgerId, value:deviceName
+        // 锛堝疄闄呴渶璋冪敤璁惧鍙拌处鐨凪apper鏌ヨ锛歞eviceNameMap = deviceLedgerMapper.listAll().stream().collect(Collectors.toMap(DeviceLedger::getId, DeviceLedger::getDeviceName))锛�
+        deviceNameMap = deviceLedgerMapper.selectList(null)
+                .stream()
+                .collect(Collectors.toMap(DeviceLedger::getId, DeviceLedger::getDeviceName));
+        if(CollectionUtils.isEmpty(deviceNameMap)){
+            return Collections.emptyList();
+        }
+        Map<Long, String> finalDeviceNameMap = deviceNameMap;
+        repairAmountGroupDTOS.forEach(dto -> {
+            dto.setDeviceName(finalDeviceNameMap.get(dto.getDeviceLedgerId()));
+        });
+        return repairAmountGroupDTOS;
+    }
+
 }
diff --git a/src/main/java/com/ruoyi/lavorissue/controller/DeptPositionController.java b/src/main/java/com/ruoyi/lavorissue/controller/DeptPositionController.java
new file mode 100644
index 0000000..0fb84ac
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/controller/DeptPositionController.java
@@ -0,0 +1,99 @@
+package com.ruoyi.lavorissue.controller;
+
+import com.baomidou.mybatisplus.core.toolkit.Wrappers;
+import com.ruoyi.framework.aspectj.lang.annotation.Log;
+import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
+import com.ruoyi.framework.web.controller.BaseController;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.lavorissue.pojo.DeptPosition;
+import com.ruoyi.lavorissue.service.DeptPositionService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.util.CollectionUtils;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 13:20
+ */
+@RestController
+@Api(tags = "閮ㄩ棬宀椾綅")
+@RequestMapping("/deptPosition")
+public class DeptPositionController extends BaseController {
+
+    @Autowired
+    private DeptPositionService deptPositionService;
+
+
+    /**
+     * 閫掑綊鑾峰彇閮ㄩ棬宀椾綅鏍戝舰缁撴瀯
+     * @return
+     */
+    @GetMapping("/getDeptPositionTree")
+    @Log(title = "閫掑綊鑾峰彇閮ㄩ棬宀椾綅鏍戝舰缁撴瀯", businessType = BusinessType.OTHER)
+    @ApiOperation("閫掑綊鑾峰彇閮ㄩ棬宀椾綅鏍戝舰缁撴瀯")
+    public AjaxResult getDeptPositionTree() {
+        return deptPositionService.getDeptPositionTree();
+    }
+
+    /**
+     * 鏌ヨ鎵�鏈夊矖浣嶅垪琛�
+     */
+    @GetMapping("/list")
+    @Log(title = "鏌ヨ鎵�鏈夊矖浣嶅垪琛�", businessType = BusinessType.OTHER)
+    @ApiOperation("鏌ヨ鎵�鏈夊矖浣嶅垪琛�")
+    public AjaxResult list() {
+        return AjaxResult.success(deptPositionService.list(Wrappers.lambdaQuery(DeptPosition.class)
+                .eq(DeptPosition::getType, 2)));
+    }
+
+    /**
+     * 閫氳繃id閫掑綊鏌ヨ鎵�鏈夌殑宀椾綅,鍦ㄩ�氳繃宀椾綅鏌ヨ瀵瑰簲浜哄憳
+     * @param deptPosition
+     * @return
+     */
+    @GetMapping("/getDeptPositionByDeptId")
+    @Log(title = "閫氳繃閮ㄩ棬id閫掑綊鏌ヨ鎵�鏈夌殑宀椾綅", businessType = BusinessType.OTHER)
+    @ApiOperation("閫氳繃閮ㄩ棬id閫掑綊鏌ヨ鎵�鏈夌殑宀椾綅")
+    public AjaxResult getDeptPositionByDeptId(@RequestBody DeptPosition deptPosition) {
+        return AjaxResult.success(deptPositionService.getDeptPositionByDeptId(deptPosition));
+    }
+
+    /**
+     * 閫氳繃id閫掑綊鏌ヨ鎵�鏈夌殑宀椾綅,鍦ㄩ�氳繃宀椾綅鏌ヨ瀵瑰簲鍔充繚鐢ㄥ搧
+     * @param deptPosition
+     * @return
+     */
+    @GetMapping("/getDeptPositionByDeptIdLabor")
+    @Log(title = "閫氳繃id閫掑綊鏌ヨ鎵�鏈夌殑宀椾綅,鍦ㄩ�氳繃宀椾綅鏌ヨ瀵瑰簲鍔充繚鐢ㄥ搧", businessType = BusinessType.OTHER)
+    @ApiOperation("閫氳繃id閫掑綊鏌ヨ鎵�鏈夌殑宀椾綅,鍦ㄩ�氳繃宀椾綅鏌ヨ瀵瑰簲鍔充繚鐢ㄥ搧")
+    public AjaxResult getDeptPositionByDeptIdLabor(@RequestBody DeptPosition deptPosition) {
+        return AjaxResult.success(deptPositionService.getDeptPositionByDeptIdLabor(deptPosition));
+    }
+
+    @PostMapping("/addDeptPosition")
+    @Log(title = "娣诲姞閮ㄩ棬宀椾綅", businessType = BusinessType.INSERT)
+    @ApiOperation("娣诲姞閮ㄩ棬宀椾綅")
+    public AjaxResult addDeptPosition(@RequestBody DeptPosition deptPosition) {
+        return AjaxResult.success(deptPositionService.save(deptPosition));
+    }
+
+    @PostMapping("/updateDeptPosition")
+    @Log(title = "淇敼閮ㄩ棬宀椾綅", businessType = BusinessType.UPDATE)
+    @ApiOperation("淇敼閮ㄩ棬宀椾綅")
+    public AjaxResult updateDeptPosition(@RequestBody DeptPosition deptPosition) {
+        return AjaxResult.success(deptPositionService.updateById(deptPosition));
+    }
+
+    @DeleteMapping("/deleteDeptPosition")
+    @Log(title = "鍒犻櫎閮ㄩ棬宀椾綅", businessType = BusinessType.DELETE)
+    @ApiOperation("鍒犻櫎閮ㄩ棬宀椾綅")
+    public AjaxResult deleteDeptPosition(@RequestBody List<Long> ids) {
+        if(CollectionUtils.isEmpty(ids)) return AjaxResult.error("璇烽�夋嫨瑕佸垹闄ょ殑閮ㄩ棬宀椾綅");
+        return AjaxResult.success(deptPositionService.removeBatchByIds(ids));
+    }
+
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/controller/LaborConfController.java b/src/main/java/com/ruoyi/lavorissue/controller/LaborConfController.java
new file mode 100644
index 0000000..a56e863
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/controller/LaborConfController.java
@@ -0,0 +1,58 @@
+package com.ruoyi.lavorissue.controller;
+
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.ruoyi.framework.aspectj.lang.annotation.Log;
+import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
+import com.ruoyi.framework.web.controller.BaseController;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.lavorissue.pojo.LaborConf;
+import com.ruoyi.lavorissue.service.LaborConfService;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.List;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 14:02
+ */
+@RestController
+@Api(tags = "鍔充繚閰嶇疆")
+@RequestMapping("/laborConf")
+public class LaborConfController extends BaseController {
+
+    @Autowired
+    private LaborConfService laborConfService;
+
+    @GetMapping("/listPage")
+    @Log(title = "鏌ヨ鍔充繚閰嶇疆", businessType = BusinessType.OTHER)
+    @ApiOperation("鏌ヨ鍔充繚閰嶇疆")
+    public AjaxResult listPage(Page page, LaborConf laborConf) {
+        return laborConfService.listPage(page, laborConf);
+    }
+
+
+    @PostMapping("/add")
+    @Log(title = "娣诲姞鍔充繚閰嶇疆", businessType = BusinessType.INSERT)
+    @ApiOperation("娣诲姞鍔充繚閰嶇疆")
+    public AjaxResult add(@RequestBody LaborConf laborConf) {
+        return laborConfService.save(laborConf) ? success() : error();
+    }
+
+    @PostMapping("/update")
+    @Log(title = "淇敼鍔充繚閰嶇疆", businessType = BusinessType.UPDATE)
+    @ApiOperation("淇敼鍔充繚閰嶇疆")
+    public AjaxResult update(@RequestBody LaborConf laborConf) {
+        return laborConfService.updateById(laborConf) ? success() : error();
+    }
+
+    @DeleteMapping("/delete")
+    @Log(title = "鍒犻櫎鍔充繚閰嶇疆", businessType = BusinessType.DELETE)
+    @ApiOperation("鍒犻櫎鍔充繚閰嶇疆")
+    public AjaxResult delete(@RequestBody List<Long> ids) {
+        return laborConfService.removeBatchByIds(ids) ? success() : error();
+    }
+
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/mapper/DeptPositionMapper.java b/src/main/java/com/ruoyi/lavorissue/mapper/DeptPositionMapper.java
new file mode 100644
index 0000000..e19ca92
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/mapper/DeptPositionMapper.java
@@ -0,0 +1,14 @@
+package com.ruoyi.lavorissue.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.ruoyi.lavorissue.pojo.DeptPosition;
+
+import java.util.List;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 13:19
+ */
+public interface DeptPositionMapper extends BaseMapper<DeptPosition> {
+    List<DeptPosition> getDeptPositionTree(List<DeptPosition> deptPositions);
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/mapper/LaborConfMapper.java b/src/main/java/com/ruoyi/lavorissue/mapper/LaborConfMapper.java
new file mode 100644
index 0000000..abbf8bb
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/mapper/LaborConfMapper.java
@@ -0,0 +1,15 @@
+package com.ruoyi.lavorissue.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.ruoyi.lavorissue.pojo.LaborConf;
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 14:00
+ */
+public interface LaborConfMapper extends BaseMapper<LaborConf> {
+    IPage<LaborConf> listPage(Page page,@Param("req") LaborConf laborConf);
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/pojo/DeptPosition.java b/src/main/java/com/ruoyi/lavorissue/pojo/DeptPosition.java
new file mode 100644
index 0000000..a423ca7
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/pojo/DeptPosition.java
@@ -0,0 +1,80 @@
+package com.ruoyi.lavorissue.pojo;
+
+import com.baomidou.mybatisplus.annotation.*;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.framework.aspectj.lang.annotation.Excel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.time.LocalDateTime;
+import java.util.Date;
+import java.util.List;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 11:58
+ */
+@Data
+@TableName("dept_position")
+public class DeptPosition {
+    private static final long serialVersionUID = 1L;
+
+    @TableId(value = "id", type = IdType.AUTO)
+    private Long id;
+
+    @ApiModelProperty("鐖秈d")
+    private Long parentId;
+
+    @ApiModelProperty("鍚嶇О")
+    private String name;
+
+    /**
+     * 绫诲瀷锛�1-閮ㄩ棬 2-宀椾綅锛�
+     */
+    @ApiModelProperty("绫诲瀷锛�1-閮ㄩ棬 2-宀椾綅锛�")
+    private Integer type;
+
+    /**
+     * 鎺掑簭
+     */
+    @ApiModelProperty("鎺掑簭")
+    private Integer sort;
+
+    @ApiModelProperty("瀛愭暟鎹紙宀椾綅锛�")
+    @TableField(exist = false)
+    private List<DeptPosition> children;
+
+
+    /**
+     * 鍒涘缓鑰�
+     */
+    @TableField(fill = FieldFill.INSERT)
+    private Integer createUser;
+
+    /**
+     * 鍒涘缓鏃堕棿
+     */
+    @TableField(fill = FieldFill.INSERT)
+    private LocalDateTime createTime;
+
+    /**
+     * 淇敼鑰�
+     */
+    @TableField(fill = FieldFill.INSERT_UPDATE)
+    private Integer updateUser;
+
+    /**
+     * 淇敼鏃堕棿
+     */
+    @TableField(fill = FieldFill.INSERT_UPDATE)
+    private LocalDateTime updateTime;
+
+    /**
+     * 绉熸埛ID
+     */
+    @TableField(fill = FieldFill.INSERT)
+    private Long tenantId;
+
+
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/pojo/LaborConf.java b/src/main/java/com/ruoyi/lavorissue/pojo/LaborConf.java
new file mode 100644
index 0000000..44080fb
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/pojo/LaborConf.java
@@ -0,0 +1,85 @@
+package com.ruoyi.lavorissue.pojo;
+
+import com.baomidou.mybatisplus.annotation.*;
+import com.ruoyi.framework.aspectj.lang.annotation.Excel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+import java.util.List;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 13:56
+ */
+@Data
+@TableName("labor_conf")
+public class LaborConf {
+
+    private static final long serialVersionUID = 1L;
+
+    @TableId(value = "id", type = IdType.AUTO)
+    private Long id;
+
+    @ApiModelProperty("閮ㄩ棬宀椾綅琛╥d")
+    private Long deptPositionId;
+
+    /**
+     * 闃插叿鍚嶇О-瀛楀吀
+     */
+    @ApiModelProperty("闃插叿鍚嶇О-瀛楀吀")
+    private String dictId;
+
+    /**
+     * 闃插叿鍚嶇О
+     */
+    @ApiModelProperty("闃插叿鍚嶇О")
+    @TableField(exist = false)
+    private String dictName;
+
+
+    /**
+     * 鏁伴噺
+     */
+    @ApiModelProperty("鏁伴噺")
+    private Integer num;
+
+
+    /**
+     * 瀛e害锛堢涓�瀛e害-1绫绘帹锛�
+     */
+    @ApiModelProperty("瀛e害锛堢涓�瀛e害-1绫绘帹锛�")
+    private Integer quarter;
+
+
+    /**
+     * 鍒涘缓鑰�
+     */
+    @TableField(fill = FieldFill.INSERT)
+    private Integer createUser;
+
+    /**
+     * 鍒涘缓鏃堕棿
+     */
+    @TableField(fill = FieldFill.INSERT)
+    private LocalDateTime createTime;
+
+    /**
+     * 淇敼鑰�
+     */
+    @TableField(fill = FieldFill.INSERT_UPDATE)
+    private Integer updateUser;
+
+    /**
+     * 淇敼鏃堕棿
+     */
+    @TableField(fill = FieldFill.INSERT_UPDATE)
+    private LocalDateTime updateTime;
+
+    /**
+     * 绉熸埛ID
+     */
+    @TableField(fill = FieldFill.INSERT)
+    private Long tenantId;
+
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/pojo/LaborIssue.java b/src/main/java/com/ruoyi/lavorissue/pojo/LaborIssue.java
index 3994833..89b1f6a 100644
--- a/src/main/java/com/ruoyi/lavorissue/pojo/LaborIssue.java
+++ b/src/main/java/com/ruoyi/lavorissue/pojo/LaborIssue.java
@@ -34,10 +34,16 @@
     private Integer season;
 
     /**
-     * 閮ㄩ棬鍚嶇О
+     * 閮ㄩ棬宀椾綅id
      */
-    @ApiModelProperty("閮ㄩ棬鍚嶇О")
-    @Excel(name = "閮ㄩ棬鍚嶇О")
+    @ApiModelProperty("閮ㄩ棬宀椾綅id")
+    private Integer deptPositionName;
+
+    /**
+     * 閮ㄩ棬宀椾綅鍚嶇О
+     */
+    @ApiModelProperty("閮ㄩ棬宀椾綅鍚嶇О")
+    @Excel(name = "閮ㄩ棬宀椾綅鍚嶇О")
     @TableField(exist = false)
     private String deptName;
 
diff --git a/src/main/java/com/ruoyi/lavorissue/service/DeptPositionService.java b/src/main/java/com/ruoyi/lavorissue/service/DeptPositionService.java
new file mode 100644
index 0000000..3f82a90
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/service/DeptPositionService.java
@@ -0,0 +1,27 @@
+package com.ruoyi.lavorissue.service;
+
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.lavorissue.pojo.DeptPosition;
+import com.ruoyi.lavorissue.pojo.LaborConf;
+import com.ruoyi.staff.pojo.StaffJoinLeaveRecord;
+import com.ruoyi.staff.pojo.StaffOnJob;
+
+import java.util.List;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 13:21
+ */
+public interface DeptPositionService extends IService<DeptPosition> {
+
+    /**
+     * 閫掑綊鑾峰彇閮ㄩ棬宀椾綅鏍戝舰缁撴瀯
+     * @return
+     */
+    AjaxResult getDeptPositionTree();
+
+    List<StaffOnJob> getDeptPositionByDeptId(DeptPosition deptPosition);
+
+    List<LaborConf> getDeptPositionByDeptIdLabor(DeptPosition deptPosition);
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/service/LaborConfService.java b/src/main/java/com/ruoyi/lavorissue/service/LaborConfService.java
new file mode 100644
index 0000000..356436b
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/service/LaborConfService.java
@@ -0,0 +1,14 @@
+package com.ruoyi.lavorissue.service;
+
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.baomidou.mybatisplus.extension.service.IService;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.lavorissue.pojo.LaborConf;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 14:00
+ */
+public interface LaborConfService extends IService<LaborConf> {
+    AjaxResult listPage(Page page, LaborConf laborConf);
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/service/impl/DeptPositionServiceImpl.java b/src/main/java/com/ruoyi/lavorissue/service/impl/DeptPositionServiceImpl.java
new file mode 100644
index 0000000..49441b6
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/service/impl/DeptPositionServiceImpl.java
@@ -0,0 +1,207 @@
+package com.ruoyi.lavorissue.service.impl;
+
+import com.baomidou.mybatisplus.core.toolkit.Wrappers;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.ruoyi.common.utils.SecurityUtils;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.lavorissue.mapper.DeptPositionMapper;
+import com.ruoyi.lavorissue.mapper.LaborConfMapper;
+import com.ruoyi.lavorissue.pojo.DeptPosition;
+import com.ruoyi.lavorissue.pojo.LaborConf;
+import com.ruoyi.lavorissue.service.DeptPositionService;
+import com.ruoyi.staff.mapper.StaffOnJobMapper;
+import com.ruoyi.staff.pojo.StaffJoinLeaveRecord;
+import com.ruoyi.staff.pojo.StaffOnJob;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.util.CollectionUtils;
+
+import java.util.*;
+import java.util.stream.Collectors;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 13:21
+ */
+@Service
+@Slf4j
+public class DeptPositionServiceImpl extends ServiceImpl<DeptPositionMapper, DeptPosition> implements DeptPositionService {
+
+    @Autowired
+    private DeptPositionMapper deptPositionMapper;
+
+
+    /**
+     * 閫掑綊鑾峰彇閮ㄩ棬宀椾綅鏍戝舰缁撴瀯
+     * @return
+     */
+    @Override
+    public AjaxResult getDeptPositionTree() {
+        List<DeptPosition> deptPositions = deptPositionMapper.selectList(null);
+        // 2. 绛涢�夋牴閮ㄩ棬锛坧arentId涓�0鎴杗ull锛屼笖绫诲瀷涓洪儴闂╰ype=1锛�
+        List<DeptPosition> rootDepts = deptPositions.stream()
+                .filter(item -> (item.getParentId() == null || item.getParentId() == 0)
+                        && item.getType() == 1) // 鏍硅妭鐐瑰繀椤绘槸閮ㄩ棬
+                .sorted(Comparator.comparingInt(DeptPosition::getSort)) // 鎸夋帓搴忓瓧娈靛崌搴�
+                .collect(Collectors.toList());
+
+        // 3. 涓烘瘡涓牴閮ㄩ棬閫掑綊鏌ユ壘涓嬪睘宀椾綅锛堝瓙闆嗭級
+        for (DeptPosition rootDept : rootDepts) {
+            buildDeptChildren(rootDept, deptPositions);
+        }
+        return AjaxResult.success(rootDepts);
+    }
+
+    @Autowired
+    private StaffOnJobMapper staffOnJobMapper;
+
+    /**
+     * 閫氳繃id閫掑綊鏌ヨ鎵�鏈夌殑宀椾綅
+     * @param deptPosition
+     * @return
+     */
+    @Override
+    public List<StaffOnJob> getDeptPositionByDeptId(DeptPosition deptPosition) {
+        Long deptId = deptPosition.getId();
+        // 1. 鏍¢獙閮ㄩ棬鏄惁瀛樺湪
+        DeptPosition dept = deptPositionMapper.selectById(deptId);
+        if (dept == null) {
+            throw new IllegalArgumentException("鏃犳晥鐨勯儴闂ㄦ垨宀椾綅ID");
+        }
+        if(dept.getType() == 2){
+            return staffOnJobMapper.selectList(Wrappers.lambdaQuery(StaffOnJob.class)
+                    .eq(StaffOnJob::getStaffState, 1)
+                    .eq(StaffOnJob::getDeptPositionId, deptId));
+        }
+
+        // 2. 閫掑綊鑾峰彇褰撳墠閮ㄩ棬鍙婃墍鏈夊瓙閮ㄩ棬鐨処D闆嗗悎
+        Set<Long> deptIdSet = new HashSet<>();
+        // 鍏堟坊鍔犲綋鍓嶉儴闂↖D
+        deptIdSet.add(deptId);
+        // 閫掑綊鑾峰彇鎵�鏈夊瓙閮ㄩ棬ID
+        findAllChildDeptIds(deptId, deptIdSet);
+
+        // 3. 鏌ヨ杩欎簺閮ㄩ棬涓嬬殑鎵�鏈夊矖浣嶏紙type=2锛�
+        if (deptIdSet.isEmpty()) {
+            return Collections.emptyList();
+        }
+        List<DeptPosition> deptPositions = deptPositionMapper.selectList(
+                Wrappers.<DeptPosition>lambdaQuery()
+                        .in(DeptPosition::getParentId, deptIdSet) // 鐖禝D鍦ㄩ儴闂↖D闆嗗悎涓�
+                        .eq(DeptPosition::getType, 2) // 绫诲瀷涓哄矖浣�
+                        .orderByAsc(DeptPosition::getSort) // 鎸夋帓搴忓瓧娈靛崌搴�
+        );
+        if(CollectionUtils.isEmpty(deptPositions)){
+            return Collections.emptyList();
+        }
+        return staffOnJobMapper.selectList(Wrappers.lambdaQuery(StaffOnJob.class)
+                .eq(StaffOnJob::getStaffState, 1)
+                .in(StaffOnJob::getDeptPositionId, deptPositions
+                        .stream()
+                        .map(DeptPosition::getId)
+                        .collect(Collectors.toSet())));
+    }
+
+    @Autowired
+    private LaborConfMapper laborConfMapper;
+
+    @Override
+    public List<LaborConf> getDeptPositionByDeptIdLabor(DeptPosition deptPosition) {
+        Long deptId = deptPosition.getId();
+        // 1. 鏍¢獙閮ㄩ棬鏄惁瀛樺湪
+        DeptPosition dept = deptPositionMapper.selectById(deptId);
+        if (dept == null) {
+            throw new IllegalArgumentException("鏃犳晥鐨勯儴闂ㄦ垨宀椾綅ID");
+        }
+        if(dept.getType() == 2){
+            return laborConfMapper.selectList(Wrappers.lambdaQuery(LaborConf.class)
+                    .eq(LaborConf::getDeptPositionId, deptId));
+        }
+
+        // 2. 閫掑綊鑾峰彇褰撳墠閮ㄩ棬鍙婃墍鏈夊瓙閮ㄩ棬鐨処D闆嗗悎
+        Set<Long> deptIdSet = new HashSet<>();
+        // 鍏堟坊鍔犲綋鍓嶉儴闂↖D
+        deptIdSet.add(deptId);
+        // 閫掑綊鑾峰彇鎵�鏈夊瓙閮ㄩ棬ID
+        findAllChildDeptIds(deptId, deptIdSet);
+
+        // 3. 鏌ヨ杩欎簺閮ㄩ棬涓嬬殑鎵�鏈夊矖浣嶏紙type=2锛�
+        if (deptIdSet.isEmpty()) {
+            return Collections.emptyList();
+        }
+        List<DeptPosition> deptPositions = deptPositionMapper.selectList(
+                Wrappers.<DeptPosition>lambdaQuery()
+                        .in(DeptPosition::getParentId, deptIdSet) // 鐖禝D鍦ㄩ儴闂↖D闆嗗悎涓�
+                        .eq(DeptPosition::getType, 2) // 绫诲瀷涓哄矖浣�
+                        .orderByAsc(DeptPosition::getSort) // 鎸夋帓搴忓瓧娈靛崌搴�
+        );
+        if(CollectionUtils.isEmpty(deptPositions)){
+            return Collections.emptyList();
+        }
+        return laborConfMapper.selectList(Wrappers.lambdaQuery(LaborConf.class)
+                .in(LaborConf::getDeptPositionId, deptPositions.stream()
+                        .map(DeptPosition::getId)
+                        .collect(Collectors.toSet())));
+    }
+
+    /**
+     * 閫掑綊鑾峰彇鎵�鏈夊瓙閮ㄩ棬ID锛堜粎鍖呮嫭type=1鐨勯儴闂級
+     * @param parentDeptId 鐖堕儴闂↖D
+     * @param deptIdSet 瀛樺偍閮ㄩ棬ID鐨勯泦鍚堬紙寮曠敤浼犻�掞紝鎸佺画娣诲姞瀛愰儴闂↖D锛�
+     */
+    private void findAllChildDeptIds(Long parentDeptId, Set<Long> deptIdSet) {
+        // 鏌ヨ褰撳墠鐖堕儴闂ㄤ笅鐨勬墍鏈夊瓙閮ㄩ棬锛坱ype=1锛�
+        List<DeptPosition> childDepts = deptPositionMapper.selectList(
+                Wrappers.<DeptPosition>lambdaQuery()
+                        .eq(DeptPosition::getParentId, parentDeptId)
+                        .eq(DeptPosition::getType, 1) // 鍙煡瀛愰儴闂紝涓嶆煡宀椾綅
+        );
+
+        // 鑻ユ湁瀛愰儴闂紝娣诲姞ID鍒伴泦鍚堬紝骞剁户缁�掑綊鏌ヨ鍏跺瓙閮ㄩ棬
+        if (!childDepts.isEmpty()) {
+            for (DeptPosition childDept : childDepts) {
+                Long childDeptId = childDept.getId();
+                deptIdSet.add(childDeptId); // 娣诲姞瀛愰儴闂↖D
+                findAllChildDeptIds(childDeptId, deptIdSet); // 閫掑綊鏌ヨ璇ュ瓙閮ㄩ棬鐨勫瓙閮ㄩ棬
+            }
+        }
+    }
+
+
+    /**
+     * 閫掑綊鏋勫缓閮ㄩ棬鐨勫瓙鑺傜偣锛堝彲鑳芥槸瀛愰儴闂ㄦ垨宀椾綅锛�
+     * @param parent 鐖惰妭鐐癸紙閮ㄩ棬锛�
+     * @param allList 鎵�鏈夋暟鎹�
+     */
+    private void buildDeptChildren(DeptPosition parent, List<DeptPosition> allList) {
+        // 绗竴姝ワ細鏌ユ壘褰撳墠閮ㄩ棬鐨勫瓙閮ㄩ棬锛坱ype=1锛夛紝鏋勫缓閮ㄩ棬灞傜骇
+        List<DeptPosition> childDepts = allList.stream()
+                .filter(item -> parent.getId().equals(item.getParentId())
+                        && item.getType() == 1) // 瀛愯妭鐐规槸閮ㄩ棬
+                .sorted(Comparator.comparingInt(DeptPosition::getSort))
+                .collect(Collectors.toList());
+
+        // 绗簩姝ワ細鏌ユ壘褰撳墠閮ㄩ棬鐨勫矖浣嶏紙type=2锛夛紝浣滀负瀛愯妭鐐�
+        List<DeptPosition> childPositions = allList.stream()
+                .filter(item -> parent.getId().equals(item.getParentId())
+                        && item.getType() == 2) // 瀛愯妭鐐规槸宀椾綅
+                .sorted(Comparator.comparingInt(DeptPosition::getSort))
+                .collect(Collectors.toList());
+
+        // 鍚堝苟瀛愰儴闂ㄥ拰宀椾綅锛堝瓙閮ㄩ棬鍦ㄥ墠锛屽矖浣嶅湪鍚庯紝鎴栨寜sort鎺掑簭锛�
+        List<DeptPosition> allChildren = new ArrayList<>();
+        allChildren.addAll(childDepts);
+        allChildren.addAll(childPositions);
+
+        // 璁剧疆瀛愯妭鐐�
+        if (!allChildren.isEmpty()) {
+            parent.setChildren(allChildren);
+
+            // 閫掑綊澶勭悊瀛愰儴闂紙宀椾綅鏃犻渶閫掑綊锛屽洜涓哄矖浣嶆槸鍙跺瓙鑺傜偣锛�
+            for (DeptPosition child : childDepts) {
+                buildDeptChildren(child, allList); // 瀛愰儴闂ㄧ户缁壘瀹冪殑瀛愯妭鐐�
+            }
+        }
+    }
+}
diff --git a/src/main/java/com/ruoyi/lavorissue/service/impl/LaborConfServiceImpl.java b/src/main/java/com/ruoyi/lavorissue/service/impl/LaborConfServiceImpl.java
new file mode 100644
index 0000000..f555827
--- /dev/null
+++ b/src/main/java/com/ruoyi/lavorissue/service/impl/LaborConfServiceImpl.java
@@ -0,0 +1,29 @@
+package com.ruoyi.lavorissue.service.impl;
+
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.lavorissue.mapper.LaborConfMapper;
+import com.ruoyi.lavorissue.pojo.LaborConf;
+import com.ruoyi.lavorissue.service.LaborConfService;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+/**
+ * @author :yys
+ * @date : 2025/11/19 14:01
+ */
+@Service
+@Slf4j
+public class LaborConfServiceImpl extends ServiceImpl<LaborConfMapper, LaborConf> implements LaborConfService {
+
+    @Autowired
+    private LaborConfMapper laborConfMapper;
+
+    @Override
+    public AjaxResult listPage(Page page, LaborConf laborConf) {
+        return AjaxResult.success(laborConfMapper.listPage(page, laborConf));
+    }
+}
diff --git a/src/main/java/com/ruoyi/staff/pojo/StaffJoinLeaveRecord.java b/src/main/java/com/ruoyi/staff/pojo/StaffJoinLeaveRecord.java
index 8de0b69..4ee26a7 100644
--- a/src/main/java/com/ruoyi/staff/pojo/StaffJoinLeaveRecord.java
+++ b/src/main/java/com/ruoyi/staff/pojo/StaffJoinLeaveRecord.java
@@ -68,10 +68,14 @@
     private String nativePlace;
 
     /**
-     * 宀椾綅
+     * 閮ㄩ棬宀椾綅id
      */
+//    @Excel(name = "宀椾綅")
+    private Integer deptPositionId;
+
+    @TableField(exist = false)
     @Excel(name = "宀椾綅")
-    private String postJob;
+    private String deptPositionName;
 
     /**
      * 瀹跺涵浣忓潃
diff --git a/src/main/java/com/ruoyi/staff/pojo/StaffOnJob.java b/src/main/java/com/ruoyi/staff/pojo/StaffOnJob.java
index dc17ed2..2a88378 100644
--- a/src/main/java/com/ruoyi/staff/pojo/StaffOnJob.java
+++ b/src/main/java/com/ruoyi/staff/pojo/StaffOnJob.java
@@ -57,10 +57,14 @@
     private String nativePlace;
 
     /**
-     * 宀椾綅
+     * 閮ㄩ棬宀椾綅id
      */
+//    @Excel(name = "宀椾綅")
+    private Integer deptPositionId;
+
+    @TableField(exist = false)
     @Excel(name = "宀椾綅")
-    private String postJob;
+    private String deptPositionName;
 
     /**
      * 瀹跺涵浣忓潃
diff --git a/src/main/resources/application-jyhjCopy.yml b/src/main/resources/application-jyhjCopy.yml
index 918a013..fa3da4b 100644
--- a/src/main/resources/application-jyhjCopy.yml
+++ b/src/main/resources/application-jyhjCopy.yml
@@ -62,9 +62,9 @@
     druid:
       # 涓诲簱鏁版嵁婧�
       master:
-        url: jdbc:mysql://192.168.1.185:3306/product-inventory-management-jyhj?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
+        url: jdbc:mysql://localhost:3306/product-inventory-management-jyhj?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
         username: root
-        password: xd@123456..
+        password: 123456
       # 浠庡簱鏁版嵁婧�
       slave:
         # 浠庢暟鎹簮寮�鍏�/榛樿鍏抽棴
diff --git a/src/main/resources/mapper/device/DeviceMaintenanceMapper.xml b/src/main/resources/mapper/device/DeviceMaintenanceMapper.xml
index 9917ce2..68c0636 100644
--- a/src/main/resources/mapper/device/DeviceMaintenanceMapper.xml
+++ b/src/main/resources/mapper/device/DeviceMaintenanceMapper.xml
@@ -20,7 +20,8 @@
         dm.maintenance_actually_name,
         dl.device_name,
         dl.device_model,
-        su.user_name as create_user_name
+        su.user_name as create_user_name,
+        dm.maintenance_price
         from device_maintenance dm
         left join device_ledger dl on dm.device_ledger_id = dl.id
         left join sys_user su on dm.create_user = su.user_id
diff --git a/src/main/resources/mapper/device/DeviceRepairMapper.xml b/src/main/resources/mapper/device/DeviceRepairMapper.xml
index e8565d6..317009b 100644
--- a/src/main/resources/mapper/device/DeviceRepairMapper.xml
+++ b/src/main/resources/mapper/device/DeviceRepairMapper.xml
@@ -19,6 +19,7 @@
                 dr.update_time,
                 dr.create_user,
                 dr.update_user,
+               dr.repair_price,
                dr.tenant_id,
                dl.device_name,
                dl.device_model
diff --git a/src/main/resources/mapper/lavorissue/LaborConfMapper.xml b/src/main/resources/mapper/lavorissue/LaborConfMapper.xml
new file mode 100644
index 0000000..7e32fea
--- /dev/null
+++ b/src/main/resources/mapper/lavorissue/LaborConfMapper.xml
@@ -0,0 +1,17 @@
+<?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.ruoyi.lavorissue.mapper.LaborConfMapper">
+
+    <select id="listPage" resultType="com.ruoyi.lavorissue.pojo.LaborConf">
+        SELECT
+        t1.*,
+        t3.dict_label as dictName
+        FROM labor_conf t1
+        left join sys_dict_data t3 on t1.dict_id = t3.dict_value
+        <where>
+            <if test="req.deptPositionId != null">
+                AND t1.dept_position_id = #{req.deptPositionId}
+            </if>
+        </where>
+    </select>
+</mapper>
\ No newline at end of file
diff --git a/src/main/resources/mapper/lavorissue/LavorIssueMapper.xml b/src/main/resources/mapper/lavorissue/LavorIssueMapper.xml
index 81cf11d..dfe8270 100644
--- a/src/main/resources/mapper/lavorissue/LavorIssueMapper.xml
+++ b/src/main/resources/mapper/lavorissue/LavorIssueMapper.xml
@@ -8,11 +8,13 @@
                t2.staff_name as staffName,
                t2.staff_no as staffNo,
                t3.dict_label as dictName,
-               t4.dict_label as dictTypeName
+               t4.dict_label as dictTypeName,
+               t5.name as deptName
         from labor_issue t1
         left join staff_join_leave_record t2 on t1.staff_id = t2.id
         left join sys_dict_data t3 on t1.dict_id = t3.dict_value
         left join sys_dict_data t4 on t1.dict_type = t4.dict_value
+        left join dept_position t5 on t1.dept_position_id = t5.id
         <where>
             <if test="req.season != null and req.season != ''">
                 and (t1.issue_date &gt;= #{req.startDate} and t1.issue_date &lt;= #{req.endDate})
@@ -43,11 +45,13 @@
             t2.staff_name as staffName,
             t2.staff_no as staffNo,
             t3.dict_label as dictName,
-            t4.dict_label as dictTypeName
+            t4.dict_label as dictTypeName,
+               t5.name as deptName
         from labor_issue t1
                  left join staff_join_leave_record t2 on t1.staff_id = t2.id
                  left join sys_dict_data t3 on t1.dict_id = t3.dict_value
                  left join sys_dict_data t4 on t1.dict_type = t4.dict_value
+                                                   left join dept_position t5 on t1.dept_position_id = t5.id
         <where>
             <if test="req.adoptedDate != null">
                 and t1.adopted_date is null
diff --git a/src/main/resources/mapper/staff/StaffJoinLeaveRecordMapper.xml b/src/main/resources/mapper/staff/StaffJoinLeaveRecordMapper.xml
index d720d37..fde6af6 100644
--- a/src/main/resources/mapper/staff/StaffJoinLeaveRecordMapper.xml
+++ b/src/main/resources/mapper/staff/StaffJoinLeaveRecordMapper.xml
@@ -3,20 +3,22 @@
 <mapper namespace="com.ruoyi.staff.mapper.StaffJoinLeaveRecordMapper">
     <select id="staffJoinLeaveRecordListPage" resultType="com.ruoyi.staff.pojo.StaffJoinLeaveRecord">
         SELECT
-        *
-        FROM staff_join_leave_record
+        t1.*,
+        t2.name as deptPositionName
+        FROM staff_join_leave_record t1
+        left join dept_position  t2 on t1.dept_position_id = t2.id and t2.type = 2
         where
         staff_state = #{staffJoinLeaveRecord.staffState}
         <if test="staffJoinLeaveRecord.staffName != null and staffJoinLeaveRecord.staffName != '' ">
-            AND staff_name LIKE CONCAT('%',#{staffJoinLeaveRecord.staffName},'%')
+            AND t1.staff_name LIKE CONCAT('%',#{staffJoinLeaveRecord.staffName},'%')
         </if>
         <if test="staffJoinLeaveRecord.entryDateStart != null and staffJoinLeaveRecord.entryDateStart != '' ">
-            and contract_start_time like concat('%',#{staffJoinLeaveRecord.entryDateStart},'%')
+            and t1.contract_start_time like concat('%',#{staffJoinLeaveRecord.entryDateStart},'%')
         </if>
         <if test="staffJoinLeaveRecord.entryDateEnd != null and staffJoinLeaveRecord.entryDateEnd != '' ">
-            and contract_end_time like concat('%',#{staffJoinLeaveRecord.entryDateEnd},'%')
+            and t1.contract_end_time like concat('%',#{staffJoinLeaveRecord.entryDateEnd},'%')
         </if>
-        order by create_time desc
+        order by t1.create_time desc
     </select>
     <select id="staffJoinLeaveRecordList" resultType="com.ruoyi.staff.pojo.StaffJoinLeaveRecord">
         SELECT
diff --git a/src/main/resources/mapper/staff/StaffOnJobMapper.xml b/src/main/resources/mapper/staff/StaffOnJobMapper.xml
index 25e79b8..643050d 100644
--- a/src/main/resources/mapper/staff/StaffOnJobMapper.xml
+++ b/src/main/resources/mapper/staff/StaffOnJobMapper.xml
@@ -3,20 +3,22 @@
 <mapper namespace="com.ruoyi.staff.mapper.StaffOnJobMapper">
     <select id="staffOnJobListPage" resultType="com.ruoyi.staff.pojo.StaffOnJob">
         SELECT
-        *
-        FROM staff_on_job
+        t1.*,
+        t2.name as deptPositionName
+        FROM staff_on_job t1
+        left join dept_position t2 on t1.dept_position_id = t2.id and t2.type = 2
         where 1=1
         <if test="staffOnJob.staffState != null and staffOnJob.staffState != '' ">
-        AND staff_state = #{staffOnJob.staffState}
+        AND t1.staff_state = #{staffOnJob.staffState}
         </if>
         <if test="staffOnJob.staffName != null and staffOnJob.staffName != '' ">
-            AND staff_name LIKE CONCAT('%',#{staffOnJob.staffName},'%')
+            AND t1.staff_name LIKE CONCAT('%',#{staffOnJob.staffName},'%')
         </if>
         <if test="staffOnJob.entryDateStart != null and staffOnJob.entryDateStart != '' ">
-            AND contract_expire_time &gt;= DATE_FORMAT(#{staffOnJob.entryDateStart},'%Y-%m-%d')
+            AND t1.contract_expire_time &gt;= DATE_FORMAT(#{staffOnJob.entryDateStart},'%Y-%m-%d')
         </if>
         <if test="staffOnJob.entryDateEnd != null and staffOnJob.entryDateEnd != '' ">
-            AND  contract_expire_time &lt;= DATE_FORMAT(#{staffOnJob.entryDateEnd},'%Y-%m-%d')
+            AND  t1.contract_expire_time &lt;= DATE_FORMAT(#{staffOnJob.entryDateEnd},'%Y-%m-%d')
         </if>
     </select>
     <select id="staffOnJobList" resultType="com.ruoyi.staff.pojo.StaffOnJob">

--
Gitblit v1.9.3