chenshudong 1 ヶ月 前
コミット
d1959134d5

+ 13 - 0
airport-personnel/src/main/java/com/sundot/airport/personnel/domain/PersonnelMonthlyAssessmentIndicatorDetail.java

@@ -1,6 +1,7 @@
1 1
 package com.sundot.airport.personnel.domain;
2 2
 
3 3
 import java.math.BigDecimal;
4
+import java.util.List;
4 5
 
5 6
 import com.baomidou.mybatisplus.annotation.IdType;
6 7
 import com.baomidou.mybatisplus.annotation.TableId;
@@ -78,6 +79,9 @@ public class PersonnelMonthlyAssessmentIndicatorDetail extends BaseEntity {
78 79
     @Excel(name = "奖罚金额(元)")
79 80
     private BigDecimal amountResult;
80 81
 
82
+    /** 奖罚明细列表 */
83
+    private List<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList;
84
+
81 85
     public void setTenantId(String tenantId) {
82 86
         this.tenantId = tenantId;
83 87
     }
@@ -198,6 +202,14 @@ public class PersonnelMonthlyAssessmentIndicatorDetail extends BaseEntity {
198 202
         return amountResult;
199 203
     }
200 204
 
205
+    public List<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> getPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailList() {
206
+        return personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList;
207
+    }
208
+
209
+    public void setPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailList(List<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList) {
210
+        this.personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList = personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList;
211
+    }
212
+
201 213
     @Override
202 214
     public String toString() {
203 215
         return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
@@ -221,6 +233,7 @@ public class PersonnelMonthlyAssessmentIndicatorDetail extends BaseEntity {
221 233
                 .append("occurCount", getOccurCount())
222 234
                 .append("scoreResult", getScoreResult())
223 235
                 .append("amountResult", getAmountResult())
236
+                .append("personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList", getPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailList())
224 237
                 .toString();
225 238
     }
226 239
 }

+ 15 - 0
airport-personnel/src/main/java/com/sundot/airport/personnel/domain/PersonnelNonCadreMonthlyAssessment.java

@@ -1,8 +1,10 @@
1 1
 package com.sundot.airport.personnel.domain;
2 2
 
3 3
 import java.math.BigDecimal;
4
+import java.util.List;
4 5
 
5 6
 import com.baomidou.mybatisplus.annotation.IdType;
7
+import com.baomidou.mybatisplus.annotation.TableField;
6 8
 import com.baomidou.mybatisplus.annotation.TableId;
7 9
 import com.baomidou.mybatisplus.annotation.TableName;
8 10
 import org.apache.commons.lang3.builder.ToStringBuilder;
@@ -154,6 +156,10 @@ public class PersonnelNonCadreMonthlyAssessment extends BaseEntity {
154 156
     @Excel(name = "豁免原因备注")
155 157
     private String exemptionReasonRemark;
156 158
 
159
+    /** 指标明细列表 */
160
+    @TableField(exist = false)
161
+    private List<PersonnelMonthlyAssessmentIndicatorDetail> personnelMonthlyAssessmentIndicatorDetailList;
162
+
157 163
     public void setTenantId(String tenantId) {
158 164
         this.tenantId = tenantId;
159 165
     }
@@ -426,6 +432,14 @@ public class PersonnelNonCadreMonthlyAssessment extends BaseEntity {
426 432
         return exemptionReasonRemark;
427 433
     }
428 434
 
435
+    public List<PersonnelMonthlyAssessmentIndicatorDetail> getPersonnelMonthlyAssessmentIndicatorDetailList() {
436
+        return personnelMonthlyAssessmentIndicatorDetailList;
437
+    }
438
+
439
+    public void setPersonnelMonthlyAssessmentIndicatorDetailList(List<PersonnelMonthlyAssessmentIndicatorDetail> personnelMonthlyAssessmentIndicatorDetailList) {
440
+        this.personnelMonthlyAssessmentIndicatorDetailList = personnelMonthlyAssessmentIndicatorDetailList;
441
+    }
442
+
429 443
     @Override
430 444
     public String toString() {
431 445
         return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
@@ -468,6 +482,7 @@ public class PersonnelNonCadreMonthlyAssessment extends BaseEntity {
468 482
                 .append("applicationMethodRemark", getApplicationMethodRemark())
469 483
                 .append("exemption", getExemption())
470 484
                 .append("exemptionReasonRemark", getExemptionReasonRemark())
485
+                .append("personnelMonthlyAssessmentIndicatorDetailList", getPersonnelMonthlyAssessmentIndicatorDetailList())
471 486
                 .toString();
472 487
     }
473 488
 }

+ 126 - 5
airport-personnel/src/main/java/com/sundot/airport/personnel/service/impl/PersonnelNonCadreMonthlyAssessmentServiceImpl.java

@@ -1,14 +1,24 @@
1 1
 package com.sundot.airport.personnel.service.impl;
2 2
 
3 3
 import java.util.List;
4
+import java.util.Map;
5
+import java.util.stream.Collectors;
4 6
 
7
+import cn.hutool.core.collection.CollUtil;
8
+import cn.hutool.core.util.ObjUtil;
9
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
5 10
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
6 11
 import com.sundot.airport.common.utils.DateUtils;
12
+import com.sundot.airport.personnel.domain.PersonnelMonthlyAssessmentIndicatorDetail;
13
+import com.sundot.airport.personnel.domain.PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail;
14
+import com.sundot.airport.personnel.service.IPersonnelMonthlyAssessmentIndicatorDetailService;
15
+import com.sundot.airport.personnel.service.IPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailService;
7 16
 import org.springframework.beans.factory.annotation.Autowired;
8 17
 import org.springframework.stereotype.Service;
9 18
 import com.sundot.airport.personnel.mapper.PersonnelNonCadreMonthlyAssessmentMapper;
10 19
 import com.sundot.airport.personnel.domain.PersonnelNonCadreMonthlyAssessment;
11 20
 import com.sundot.airport.personnel.service.IPersonnelNonCadreMonthlyAssessmentService;
21
+import org.springframework.transaction.annotation.Transactional;
12 22
 
13 23
 /**
14 24
  * 非干部月度考核Service业务层处理
@@ -20,6 +30,10 @@ import com.sundot.airport.personnel.service.IPersonnelNonCadreMonthlyAssessmentS
20 30
 public class PersonnelNonCadreMonthlyAssessmentServiceImpl extends ServiceImpl<PersonnelNonCadreMonthlyAssessmentMapper, PersonnelNonCadreMonthlyAssessment> implements IPersonnelNonCadreMonthlyAssessmentService {
21 31
     @Autowired
22 32
     private PersonnelNonCadreMonthlyAssessmentMapper personnelNonCadreMonthlyAssessmentMapper;
33
+    @Autowired
34
+    private IPersonnelMonthlyAssessmentIndicatorDetailService personnelMonthlyAssessmentIndicatorDetailService;
35
+    @Autowired
36
+    private IPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailService personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService;
23 37
 
24 38
     /**
25 39
      * 查询非干部月度考核
@@ -29,7 +43,30 @@ public class PersonnelNonCadreMonthlyAssessmentServiceImpl extends ServiceImpl<P
29 43
      */
30 44
     @Override
31 45
     public PersonnelNonCadreMonthlyAssessment selectPersonnelNonCadreMonthlyAssessmentById(Long id) {
32
-        return personnelNonCadreMonthlyAssessmentMapper.selectPersonnelNonCadreMonthlyAssessmentById(id);
46
+        PersonnelNonCadreMonthlyAssessment result = personnelNonCadreMonthlyAssessmentMapper.selectPersonnelNonCadreMonthlyAssessmentById(id);
47
+        if (ObjUtil.isNull(result)) {
48
+            return result;
49
+        }
50
+        // 指标明细列表
51
+        LambdaQueryWrapper<PersonnelMonthlyAssessmentIndicatorDetail> detailQueryWrapper = new LambdaQueryWrapper<>();
52
+        detailQueryWrapper.eq(PersonnelMonthlyAssessmentIndicatorDetail::getSourceId, result.getId());
53
+        List<PersonnelMonthlyAssessmentIndicatorDetail> personnelMonthlyAssessmentIndicatorDetailList = personnelMonthlyAssessmentIndicatorDetailService.getBaseMapper().selectList(detailQueryWrapper);
54
+        if (CollUtil.isEmpty(personnelMonthlyAssessmentIndicatorDetailList)) {
55
+            return result;
56
+        }
57
+        result.setPersonnelMonthlyAssessmentIndicatorDetailList(personnelMonthlyAssessmentIndicatorDetailList);
58
+        // 奖罚明细列表
59
+        LambdaQueryWrapper<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> rewardPunishmentDetailQueryWrapper = new LambdaQueryWrapper<>();
60
+        rewardPunishmentDetailQueryWrapper.in(PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail::getSourceId, personnelMonthlyAssessmentIndicatorDetailList.stream().map(PersonnelMonthlyAssessmentIndicatorDetail::getId).toArray());
61
+        List<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList = personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.getBaseMapper().selectList(rewardPunishmentDetailQueryWrapper);
62
+        if (CollUtil.isEmpty(personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList)) {
63
+            return result;
64
+        }
65
+        Map<Long, List<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail>> rewardPunishmentDetailMap = personnelMonthlyAssessmentIndicatorRewardPunishmentDetailList.stream().collect(Collectors.groupingBy(PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail::getSourceId));
66
+        personnelMonthlyAssessmentIndicatorDetailList.forEach(item -> {
67
+            item.setPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailList(rewardPunishmentDetailMap.get(item.getId()));
68
+        });
69
+        return result;
33 70
     }
34 71
 
35 72
     /**
@@ -49,10 +86,28 @@ public class PersonnelNonCadreMonthlyAssessmentServiceImpl extends ServiceImpl<P
49 86
      * @param personnelNonCadreMonthlyAssessment 非干部月度考核
50 87
      * @return 结果
51 88
      */
89
+    @Transactional(rollbackFor = Exception.class)
52 90
     @Override
53 91
     public int insertPersonnelNonCadreMonthlyAssessment(PersonnelNonCadreMonthlyAssessment personnelNonCadreMonthlyAssessment) {
54 92
         personnelNonCadreMonthlyAssessment.setCreateTime(DateUtils.getNowDate());
55
-        return personnelNonCadreMonthlyAssessmentMapper.insertPersonnelNonCadreMonthlyAssessment(personnelNonCadreMonthlyAssessment);
93
+        int result = personnelNonCadreMonthlyAssessmentMapper.insertPersonnelNonCadreMonthlyAssessment(personnelNonCadreMonthlyAssessment);
94
+        if (CollUtil.isNotEmpty(personnelNonCadreMonthlyAssessment.getPersonnelMonthlyAssessmentIndicatorDetailList())) {
95
+            personnelNonCadreMonthlyAssessment.getPersonnelMonthlyAssessmentIndicatorDetailList().forEach(personnelMonthlyAssessmentIndicatorDetail -> {
96
+                personnelMonthlyAssessmentIndicatorDetail.setSourceId(personnelNonCadreMonthlyAssessment.getId());
97
+                personnelMonthlyAssessmentIndicatorDetail.setCreateBy(personnelNonCadreMonthlyAssessment.getCreateBy());
98
+                personnelMonthlyAssessmentIndicatorDetail.setCreateTime(DateUtils.getNowDate());
99
+                personnelMonthlyAssessmentIndicatorDetailService.insertPersonnelMonthlyAssessmentIndicatorDetail(personnelMonthlyAssessmentIndicatorDetail);
100
+                if (CollUtil.isNotEmpty(personnelMonthlyAssessmentIndicatorDetail.getPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailList())) {
101
+                    personnelMonthlyAssessmentIndicatorDetail.getPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailList().forEach(personnelMonthlyAssessmentIndicatorRewardPunishmentDetail -> {
102
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetail.setSourceId(personnelMonthlyAssessmentIndicatorDetail.getId());
103
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetail.setCreateBy(personnelMonthlyAssessmentIndicatorDetail.getCreateBy());
104
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetail.setCreateTime(DateUtils.getNowDate());
105
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.insertPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail(personnelMonthlyAssessmentIndicatorRewardPunishmentDetail);
106
+                    });
107
+                }
108
+            });
109
+        }
110
+        return result;
56 111
     }
57 112
 
58 113
     /**
@@ -61,10 +116,46 @@ public class PersonnelNonCadreMonthlyAssessmentServiceImpl extends ServiceImpl<P
61 116
      * @param personnelNonCadreMonthlyAssessment 非干部月度考核
62 117
      * @return 结果
63 118
      */
119
+    @Transactional(rollbackFor = Exception.class)
64 120
     @Override
65 121
     public int updatePersonnelNonCadreMonthlyAssessment(PersonnelNonCadreMonthlyAssessment personnelNonCadreMonthlyAssessment) {
66 122
         personnelNonCadreMonthlyAssessment.setUpdateTime(DateUtils.getNowDate());
67
-        return personnelNonCadreMonthlyAssessmentMapper.updatePersonnelNonCadreMonthlyAssessment(personnelNonCadreMonthlyAssessment);
123
+        int result = personnelNonCadreMonthlyAssessmentMapper.updatePersonnelNonCadreMonthlyAssessment(personnelNonCadreMonthlyAssessment);
124
+        // 删除旧数据
125
+        LambdaQueryWrapper<PersonnelMonthlyAssessmentIndicatorDetail> detailQueryWrapper = new LambdaQueryWrapper<>();
126
+        detailQueryWrapper.eq(PersonnelMonthlyAssessmentIndicatorDetail::getSourceId, personnelNonCadreMonthlyAssessment.getId());
127
+        List<PersonnelMonthlyAssessmentIndicatorDetail> personnelMonthlyAssessmentIndicatorDetailListOld = personnelMonthlyAssessmentIndicatorDetailService.getBaseMapper().selectList(detailQueryWrapper);
128
+        if (CollUtil.isNotEmpty(personnelMonthlyAssessmentIndicatorDetailListOld)) {
129
+            personnelMonthlyAssessmentIndicatorDetailService.removeBatchByIds(personnelMonthlyAssessmentIndicatorDetailListOld);
130
+            LambdaQueryWrapper<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> rewardPunishmentDetailQueryWrapper = new LambdaQueryWrapper<>();
131
+            rewardPunishmentDetailQueryWrapper.in(PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail::getSourceId, personnelMonthlyAssessmentIndicatorDetailListOld.stream().map(PersonnelMonthlyAssessmentIndicatorDetail::getId).toArray());
132
+            List<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld = personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.getBaseMapper().selectList(rewardPunishmentDetailQueryWrapper);
133
+            if (CollUtil.isNotEmpty(personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld)) {
134
+                personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.removeBatchByIds(personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld);
135
+            }
136
+        }
137
+        // 新增新数据
138
+        if (CollUtil.isNotEmpty(personnelNonCadreMonthlyAssessment.getPersonnelMonthlyAssessmentIndicatorDetailList())) {
139
+            personnelNonCadreMonthlyAssessment.getPersonnelMonthlyAssessmentIndicatorDetailList().forEach(personnelMonthlyAssessmentIndicatorDetail -> {
140
+                personnelMonthlyAssessmentIndicatorDetail.setSourceId(personnelNonCadreMonthlyAssessment.getId());
141
+                personnelMonthlyAssessmentIndicatorDetail.setCreateBy(personnelNonCadreMonthlyAssessment.getCreateBy());
142
+                personnelMonthlyAssessmentIndicatorDetail.setCreateTime(DateUtils.getNowDate());
143
+                personnelMonthlyAssessmentIndicatorDetail.setUpdateBy(personnelNonCadreMonthlyAssessment.getCreateBy());
144
+                personnelMonthlyAssessmentIndicatorDetail.setUpdateTime(DateUtils.getNowDate());
145
+                personnelMonthlyAssessmentIndicatorDetailService.insertPersonnelMonthlyAssessmentIndicatorDetail(personnelMonthlyAssessmentIndicatorDetail);
146
+                if (CollUtil.isNotEmpty(personnelMonthlyAssessmentIndicatorDetail.getPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailList())) {
147
+                    personnelMonthlyAssessmentIndicatorDetail.getPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetailList().forEach(personnelMonthlyAssessmentIndicatorRewardPunishmentDetail -> {
148
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetail.setSourceId(personnelMonthlyAssessmentIndicatorDetail.getId());
149
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetail.setCreateBy(personnelMonthlyAssessmentIndicatorDetail.getCreateBy());
150
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetail.setCreateTime(DateUtils.getNowDate());
151
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetail.setUpdateBy(personnelMonthlyAssessmentIndicatorDetail.getCreateBy());
152
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetail.setUpdateTime(DateUtils.getNowDate());
153
+                        personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.insertPersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail(personnelMonthlyAssessmentIndicatorRewardPunishmentDetail);
154
+                    });
155
+                }
156
+            });
157
+        }
158
+        return result;
68 159
     }
69 160
 
70 161
     /**
@@ -73,9 +164,25 @@ public class PersonnelNonCadreMonthlyAssessmentServiceImpl extends ServiceImpl<P
73 164
      * @param ids 需要删除的非干部月度考核主键
74 165
      * @return 结果
75 166
      */
167
+    @Transactional(rollbackFor = Exception.class)
76 168
     @Override
77 169
     public int deletePersonnelNonCadreMonthlyAssessmentByIds(Long[] ids) {
78
-        return personnelNonCadreMonthlyAssessmentMapper.deletePersonnelNonCadreMonthlyAssessmentByIds(ids);
170
+        int result = personnelNonCadreMonthlyAssessmentMapper.deletePersonnelNonCadreMonthlyAssessmentByIds(ids);
171
+        for (Long id : ids) {
172
+            LambdaQueryWrapper<PersonnelMonthlyAssessmentIndicatorDetail> detailQueryWrapper = new LambdaQueryWrapper<>();
173
+            detailQueryWrapper.eq(PersonnelMonthlyAssessmentIndicatorDetail::getSourceId, id);
174
+            List<PersonnelMonthlyAssessmentIndicatorDetail> personnelMonthlyAssessmentIndicatorDetailListOld = personnelMonthlyAssessmentIndicatorDetailService.getBaseMapper().selectList(detailQueryWrapper);
175
+            if (CollUtil.isNotEmpty(personnelMonthlyAssessmentIndicatorDetailListOld)) {
176
+                personnelMonthlyAssessmentIndicatorDetailService.removeBatchByIds(personnelMonthlyAssessmentIndicatorDetailListOld);
177
+                LambdaQueryWrapper<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> rewardPunishmentDetailQueryWrapper = new LambdaQueryWrapper<>();
178
+                rewardPunishmentDetailQueryWrapper.in(PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail::getSourceId, personnelMonthlyAssessmentIndicatorDetailListOld.stream().map(PersonnelMonthlyAssessmentIndicatorDetail::getId).toArray());
179
+                List<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld = personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.getBaseMapper().selectList(rewardPunishmentDetailQueryWrapper);
180
+                if (CollUtil.isNotEmpty(personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld)) {
181
+                    personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.removeBatchByIds(personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld);
182
+                }
183
+            }
184
+        }
185
+        return result;
79 186
     }
80 187
 
81 188
     /**
@@ -84,8 +191,22 @@ public class PersonnelNonCadreMonthlyAssessmentServiceImpl extends ServiceImpl<P
84 191
      * @param id 非干部月度考核主键
85 192
      * @return 结果
86 193
      */
194
+    @Transactional(rollbackFor = Exception.class)
87 195
     @Override
88 196
     public int deletePersonnelNonCadreMonthlyAssessmentById(Long id) {
89
-        return personnelNonCadreMonthlyAssessmentMapper.deletePersonnelNonCadreMonthlyAssessmentById(id);
197
+        int result = personnelNonCadreMonthlyAssessmentMapper.deletePersonnelNonCadreMonthlyAssessmentById(id);
198
+        LambdaQueryWrapper<PersonnelMonthlyAssessmentIndicatorDetail> detailQueryWrapper = new LambdaQueryWrapper<>();
199
+        detailQueryWrapper.eq(PersonnelMonthlyAssessmentIndicatorDetail::getSourceId, id);
200
+        List<PersonnelMonthlyAssessmentIndicatorDetail> personnelMonthlyAssessmentIndicatorDetailListOld = personnelMonthlyAssessmentIndicatorDetailService.getBaseMapper().selectList(detailQueryWrapper);
201
+        if (CollUtil.isNotEmpty(personnelMonthlyAssessmentIndicatorDetailListOld)) {
202
+            personnelMonthlyAssessmentIndicatorDetailService.removeBatchByIds(personnelMonthlyAssessmentIndicatorDetailListOld);
203
+            LambdaQueryWrapper<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> rewardPunishmentDetailQueryWrapper = new LambdaQueryWrapper<>();
204
+            rewardPunishmentDetailQueryWrapper.in(PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail::getSourceId, personnelMonthlyAssessmentIndicatorDetailListOld.stream().map(PersonnelMonthlyAssessmentIndicatorDetail::getId).toArray());
205
+            List<PersonnelMonthlyAssessmentIndicatorRewardPunishmentDetail> personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld = personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.getBaseMapper().selectList(rewardPunishmentDetailQueryWrapper);
206
+            if (CollUtil.isNotEmpty(personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld)) {
207
+                personnelMonthlyAssessmentIndicatorRewardPunishmentDetailService.removeBatchByIds(personnelMonthlyAssessmentIndicatorRewardPunishmentDetailListOld);
208
+            }
209
+        }
210
+        return result;
90 211
     }
91 212
 }