Sfoglia il codice sorgente

ledger_security_test字段删除和调整、相关代码调整、一键导入功能导入模版调整调整

wangxx 2 settimane fa
parent
commit
24fb48e819

+ 2 - 3
airport-admin/src/main/java/com/sundot/airport/web/controller/ledger/LedgerTemplateController.java

@@ -80,9 +80,8 @@ public class LedgerTemplateController extends BaseController {
80
         nm.put("securityTest", "安保测试记录表(部门)");
80
         nm.put("securityTest", "安保测试记录表(部门)");
81
         hm.put("securityTest", 2);
81
         hm.put("securityTest", 2);
82
         cm.put("securityTest", new String[]{
82
         cm.put("securityTest", new String[]{
83
-            "开展时间","测试区域","测试通道","测试项目","被测试人员","被测试岗位","测试物品","图片或视频",
84
-            "是否通过","层级","整改措施","扣分","整改材料","班组","推送队室质控员","推送质控队长",
85
-            "队室内勤","推送按钮","队室负责人"
83
+            "开展时间","测试区域","测试通道","测试人员","测试项目","被测试人员","被测试岗位",
84
+            "测试物品","图片或视频","是否通过","层级","整改措施","","整改材料"
86
         });
85
         });
87
 
86
 
88
         // 7. 通道过检率 (横向月份列, 2行表头)
87
         // 7. 通道过检率 (横向月份列, 2行表头)

+ 48 - 86
airport-ledger/src/main/java/com/sundot/airport/ledger/domain/LedgerSecurityTest.java

@@ -21,7 +21,7 @@ public class LedgerSecurityTest extends BaseEntity {
21
     private Long id;
21
     private Long id;
22
 
22
 
23
     @JsonFormat(pattern = "yyyy-MM-dd")
23
     @JsonFormat(pattern = "yyyy-MM-dd")
24
-    @Excel(name = "测试日期", width = 20, dateFormat = "yyyy-MM-dd")
24
+    @Excel(name = "开展时间", width = 20, dateFormat = "yyyy-MM-dd")
25
     private Date recordDate;
25
     private Date recordDate;
26
 
26
 
27
     @Excel(name = "测试区域")
27
     @Excel(name = "测试区域")
@@ -35,24 +35,22 @@ public class LedgerSecurityTest extends BaseEntity {
35
 
35
 
36
     private Long deptId;
36
     private Long deptId;
37
 
37
 
38
-    @Excel(name = "队室/班组")
39
     private String teamName;
38
     private String teamName;
40
 
39
 
41
     private Long teamId;
40
     private Long teamId;
42
 
41
 
43
-    @Excel(name = "小组")
44
     private String groupName;
42
     private String groupName;
45
 
43
 
46
     private Long groupId;
44
     private Long groupId;
47
 
45
 
48
     private Long areaId;
46
     private Long areaId;
49
 
47
 
50
-    @Excel(name = "测试人")
48
+    @Excel(name = "测试人")
51
     private String testerName;
49
     private String testerName;
52
 
50
 
53
     private Long testerId;
51
     private Long testerId;
54
 
52
 
55
-    @Excel(name = "被测人")
53
+    @Excel(name = "被测")
56
     private String testedName;
54
     private String testedName;
57
 
55
 
58
     private Long testedId;
56
     private Long testedId;
@@ -65,36 +63,24 @@ public class LedgerSecurityTest extends BaseEntity {
65
     @Excel(name = "测试项目")
63
     @Excel(name = "测试项目")
66
     private String testItem;
64
     private String testItem;
67
 
65
 
68
-    @Excel(name = "测试结果")
66
+    @Excel(name = "测试物品")
69
     private String testResult;
67
     private String testResult;
70
 
68
 
71
-    @Excel(name = "问题描述")
69
+    @Excel(name = "图片或视频")
70
+    private String evidenceFile;
71
+
72
+    @Excel(name = "是否通过")
72
     private String problemDesc;
73
     private String problemDesc;
73
 
74
 
74
-    @Excel(name = "处理结果")
75
-    private String resultHandling;
75
+    @Excel(name = "层级")
76
+    private String testLevel;
76
 
77
 
77
-    @Excel(name = "复查地点及时间")
78
-    private String reviewLocationTime;
78
+    @Excel(name = "整改措施")
79
+    private String resultHandling;
79
 
80
 
80
     @Excel(name = "整改材料")
81
     @Excel(name = "整改材料")
81
     private String reviewMaterial;
82
     private String reviewMaterial;
82
 
83
 
83
-    @Excel(name = "推送队室质控员")
84
-    private String pushTeamQc;
85
-
86
-    @Excel(name = "推送质控队长")
87
-    private String pushQcCaptain;
88
-
89
-    @Excel(name = "队室内勤")
90
-    private String teamInternalDuty;
91
-
92
-    @Excel(name = "点击推送至相关人员")
93
-    private String pushToRelevant;
94
-
95
-    @Excel(name = "队室负责人")
96
-    private String teamLeader;
97
-
98
     @Excel(name = "扣分")
84
     @Excel(name = "扣分")
99
     private BigDecimal deductScore;
85
     private BigDecimal deductScore;
100
 
86
 
@@ -107,12 +93,6 @@ public class LedgerSecurityTest extends BaseEntity {
107
     @Excel(name = "评分指标")
93
     @Excel(name = "评分指标")
108
     private String scoreIndicator;
94
     private String scoreIndicator;
109
 
95
 
110
-    @Excel(name = "佐证附件")
111
-    private String evidenceFile;
112
-
113
-    @Excel(name = "备注")
114
-    private String remark;
115
-
116
     private String importBatch;
96
     private String importBatch;
117
 
97
 
118
     @Excel(name = "数据来源")
98
     @Excel(name = "数据来源")
@@ -127,36 +107,72 @@ public class LedgerSecurityTest extends BaseEntity {
127
     public Date getRecordDate() { return recordDate; }
107
     public Date getRecordDate() { return recordDate; }
128
     public void setRecordDate(Date recordDate) { this.recordDate = recordDate; }
108
     public void setRecordDate(Date recordDate) { this.recordDate = recordDate; }
129
 
109
 
110
+    public String getRegion() { return region; }
111
+    public void setRegion(String region) { this.region = region; }
112
+
113
+    public String getChannel() { return channel; }
114
+    public void setChannel(String channel) { this.channel = channel; }
115
+
130
     public String getDeptName() { return deptName; }
116
     public String getDeptName() { return deptName; }
131
     public void setDeptName(String deptName) { this.deptName = deptName; }
117
     public void setDeptName(String deptName) { this.deptName = deptName; }
132
 
118
 
119
+    public Long getDeptId() { return deptId; }
120
+    public void setDeptId(Long deptId) { this.deptId = deptId; }
121
+
133
     public String getTeamName() { return teamName; }
122
     public String getTeamName() { return teamName; }
134
     public void setTeamName(String teamName) { this.teamName = teamName; }
123
     public void setTeamName(String teamName) { this.teamName = teamName; }
135
 
124
 
125
+    public Long getTeamId() { return teamId; }
126
+    public void setTeamId(Long teamId) { this.teamId = teamId; }
127
+
136
     public String getGroupName() { return groupName; }
128
     public String getGroupName() { return groupName; }
137
     public void setGroupName(String groupName) { this.groupName = groupName; }
129
     public void setGroupName(String groupName) { this.groupName = groupName; }
138
 
130
 
131
+    public Long getGroupId() { return groupId; }
132
+    public void setGroupId(Long groupId) { this.groupId = groupId; }
133
+
134
+    public Long getAreaId() { return areaId; }
135
+    public void setAreaId(Long areaId) { this.areaId = areaId; }
136
+
139
     public String getTesterName() { return testerName; }
137
     public String getTesterName() { return testerName; }
140
     public void setTesterName(String testerName) { this.testerName = testerName; }
138
     public void setTesterName(String testerName) { this.testerName = testerName; }
141
 
139
 
140
+    public Long getTesterId() { return testerId; }
141
+    public void setTesterId(Long testerId) { this.testerId = testerId; }
142
+
142
     public String getTestedName() { return testedName; }
143
     public String getTestedName() { return testedName; }
143
     public void setTestedName(String testedName) { this.testedName = testedName; }
144
     public void setTestedName(String testedName) { this.testedName = testedName; }
144
 
145
 
146
+    public Long getTestedId() { return testedId; }
147
+    public void setTestedId(Long testedId) { this.testedId = testedId; }
148
+
145
     public String getTestType() { return testType; }
149
     public String getTestType() { return testType; }
146
     public void setTestType(String testType) { this.testType = testType; }
150
     public void setTestType(String testType) { this.testType = testType; }
147
 
151
 
152
+    public Long getPositionId() { return positionId; }
153
+    public void setPositionId(Long positionId) { this.positionId = positionId; }
154
+
148
     public String getTestItem() { return testItem; }
155
     public String getTestItem() { return testItem; }
149
     public void setTestItem(String testItem) { this.testItem = testItem; }
156
     public void setTestItem(String testItem) { this.testItem = testItem; }
150
 
157
 
151
     public String getTestResult() { return testResult; }
158
     public String getTestResult() { return testResult; }
152
     public void setTestResult(String testResult) { this.testResult = testResult; }
159
     public void setTestResult(String testResult) { this.testResult = testResult; }
153
 
160
 
161
+    public String getEvidenceFile() { return evidenceFile; }
162
+    public void setEvidenceFile(String evidenceFile) { this.evidenceFile = evidenceFile; }
163
+
154
     public String getProblemDesc() { return problemDesc; }
164
     public String getProblemDesc() { return problemDesc; }
155
     public void setProblemDesc(String problemDesc) { this.problemDesc = problemDesc; }
165
     public void setProblemDesc(String problemDesc) { this.problemDesc = problemDesc; }
156
 
166
 
167
+    public String getTestLevel() { return testLevel; }
168
+    public void setTestLevel(String testLevel) { this.testLevel = testLevel; }
169
+
157
     public String getResultHandling() { return resultHandling; }
170
     public String getResultHandling() { return resultHandling; }
158
     public void setResultHandling(String resultHandling) { this.resultHandling = resultHandling; }
171
     public void setResultHandling(String resultHandling) { this.resultHandling = resultHandling; }
159
 
172
 
173
+    public String getReviewMaterial() { return reviewMaterial; }
174
+    public void setReviewMaterial(String reviewMaterial) { this.reviewMaterial = reviewMaterial; }
175
+
160
     public BigDecimal getDeductScore() { return deductScore; }
176
     public BigDecimal getDeductScore() { return deductScore; }
161
     public void setDeductScore(BigDecimal deductScore) { this.deductScore = deductScore; }
177
     public void setDeductScore(BigDecimal deductScore) { this.deductScore = deductScore; }
162
 
178
 
@@ -169,66 +185,12 @@ public class LedgerSecurityTest extends BaseEntity {
169
     public String getScoreIndicator() { return scoreIndicator; }
185
     public String getScoreIndicator() { return scoreIndicator; }
170
     public void setScoreIndicator(String scoreIndicator) { this.scoreIndicator = scoreIndicator; }
186
     public void setScoreIndicator(String scoreIndicator) { this.scoreIndicator = scoreIndicator; }
171
 
187
 
172
-    public String getEvidenceFile() { return evidenceFile; }
173
-    public void setEvidenceFile(String evidenceFile) { this.evidenceFile = evidenceFile; }
174
-
175
-    public String getRemark() { return remark; }
176
-    public void setRemark(String remark) { this.remark = remark; }
177
-
178
     public String getImportBatch() { return importBatch; }
188
     public String getImportBatch() { return importBatch; }
179
     public void setImportBatch(String importBatch) { this.importBatch = importBatch; }
189
     public void setImportBatch(String importBatch) { this.importBatch = importBatch; }
180
 
190
 
181
     public String getSourceType() { return sourceType; }
191
     public String getSourceType() { return sourceType; }
182
     public void setSourceType(String sourceType) { this.sourceType = sourceType; }
192
     public void setSourceType(String sourceType) { this.sourceType = sourceType; }
183
 
193
 
184
-    public String getRegion() { return region; }
185
-    public void setRegion(String region) { this.region = region; }
186
-
187
-    public String getChannel() { return channel; }
188
-    public void setChannel(String channel) { this.channel = channel; }
189
-
190
-    public Long getDeptId() { return deptId; }
191
-    public void setDeptId(Long deptId) { this.deptId = deptId; }
192
-
193
-    public Long getTeamId() { return teamId; }
194
-    public void setTeamId(Long teamId) { this.teamId = teamId; }
195
-
196
-    public Long getGroupId() { return groupId; }
197
-    public void setGroupId(Long groupId) { this.groupId = groupId; }
198
-
199
-    public Long getAreaId() { return areaId; }
200
-    public void setAreaId(Long areaId) { this.areaId = areaId; }
201
-
202
-    public Long getTesterId() { return testerId; }
203
-    public void setTesterId(Long testerId) { this.testerId = testerId; }
204
-
205
-    public Long getTestedId() { return testedId; }
206
-    public void setTestedId(Long testedId) { this.testedId = testedId; }
207
-
208
-    public Long getPositionId() { return positionId; }
209
-    public void setPositionId(Long positionId) { this.positionId = positionId; }
210
-
211
-    public String getReviewLocationTime() { return reviewLocationTime; }
212
-    public void setReviewLocationTime(String reviewLocationTime) { this.reviewLocationTime = reviewLocationTime; }
213
-
214
-    public String getReviewMaterial() { return reviewMaterial; }
215
-    public void setReviewMaterial(String reviewMaterial) { this.reviewMaterial = reviewMaterial; }
216
-
217
-    public String getPushTeamQc() { return pushTeamQc; }
218
-    public void setPushTeamQc(String pushTeamQc) { this.pushTeamQc = pushTeamQc; }
219
-
220
-    public String getPushQcCaptain() { return pushQcCaptain; }
221
-    public void setPushQcCaptain(String pushQcCaptain) { this.pushQcCaptain = pushQcCaptain; }
222
-
223
-    public String getTeamInternalDuty() { return teamInternalDuty; }
224
-    public void setTeamInternalDuty(String teamInternalDuty) { this.teamInternalDuty = teamInternalDuty; }
225
-
226
-    public String getPushToRelevant() { return pushToRelevant; }
227
-    public void setPushToRelevant(String pushToRelevant) { this.pushToRelevant = pushToRelevant; }
228
-
229
-    public String getTeamLeader() { return teamLeader; }
230
-    public void setTeamLeader(String teamLeader) { this.teamLeader = teamLeader; }
231
-
232
     public String getSyncFlag() { return syncFlag; }
194
     public String getSyncFlag() { return syncFlag; }
233
     public void setSyncFlag(String syncFlag) { this.syncFlag = syncFlag; }
195
     public void setSyncFlag(String syncFlag) { this.syncFlag = syncFlag; }
234
 }
196
 }

+ 18 - 57
airport-ledger/src/main/java/com/sundot/airport/ledger/service/impl/LedgerCombinedImportServiceImpl.java

@@ -487,69 +487,30 @@ public class LedgerCombinedImportServiceImpl implements ILedgerCombinedImportSer
487
     }
487
     }
488
 
488
 
489
     /** 6. 安保测试记录表(部门)→ ledger_security_test
489
     /** 6. 安保测试记录表(部门)→ ledger_security_test
490
-     * 导入顺序:开展时间(0) 测试区域(1) 测试通道(2) 测试项目(3) 被测试人员(4) 被测试岗位(5)
491
-     *          测试物品(6) 开展项目图片或视频(7) 是否通过(8) 层级(9) 整改措施(10)
492
-     *          复查地点及时间(11) 整改材料(12) 班组(13) 推送队室质控员(14) 推送质控队长(15)
493
-     *          队室内勤(16) 点击推送至相关人员(17) 队室负责人(18)
490
+     * 导入顺序:开展时间(0) 测试区域(1) 测试通道(2) 测试人员(3) 测试项目(4)
491
+     *          被测试人员(5) 被测试岗位(6) 测试物品(7) 图片或视频(8) 是否通过(9)
492
+     *          层级(10) 整改措施(11) (12空) 整改材料(13)
494
      */
493
      */
495
     private int doSecurityTest(Sheet sheet, String batchNo, String username) {
494
     private int doSecurityTest(Sheet sheet, String batchNo, String username) {
496
         List<LedgerSecurityTest> list = new ArrayList<>();
495
         List<LedgerSecurityTest> list = new ArrayList<>();
497
         for (Object[] c : dataRows(sheet, 2)) {
496
         for (Object[] c : dataRows(sheet, 2)) {
498
             LedgerSecurityTest o = new LedgerSecurityTest();
497
             LedgerSecurityTest o = new LedgerSecurityTest();
499
-            
500
-            // 按照新的导入顺序映射字段
501
-            o.setRecordDate(date(c, 0));  // 开展时间
502
-            o.setRegion(str(c, 1));       // 测试区域
503
-            o.setChannel(str(c, 2));      // 测试通道
504
-            o.setTestItem(str(c, 3));     // 测试项目
505
-            
506
-            // 被测试人员
507
-            String testedName = str(c, 4);
498
+
499
+            o.setRecordDate(date(c, 0));        // 开展时间
500
+            o.setRegion(str(c, 1));             // 测试区域
501
+            o.setChannel(str(c, 2));            // 测试通道
502
+            o.setTesterName(str(c, 3));         // 测试人员
503
+            o.setTestItem(str(c, 4));           // 测试项目
504
+            String testedName = str(c, 5);      // 被测试人员
508
             o.setTestedName(testedName);
505
             o.setTestedName(testedName);
509
-            
510
-            // 被测试岗位
511
-            o.setTestType(str(c, 5));
512
-            
513
-            // 测试物品→problemDesc
514
-            o.setProblemDesc(str(c, 6));
515
-            
516
-            // 开展项目图片或视频→evidenceFile
517
-            o.setEvidenceFile(str(c, 7));
518
-            
519
-            // 是否通过→testResult
520
-            o.setTestResult(str(c, 8));
521
-            
522
-            // 层级→scoreIndicator
523
-            o.setScoreIndicator(str(c, 9));
524
-            
525
-            // 整改措施→resultHandling
526
-            o.setResultHandling(str(c, 10));
527
-            
528
-            // 复查地点及时间
529
-            o.setReviewLocationTime(str(c, 11));
530
-            
531
-            // 整改材料
532
-            o.setReviewMaterial(str(c, 12));
533
-            
534
-            // 班组→teamName
535
-            String teamName = str(c, 13);
536
-            o.setTeamName(teamName);
537
-            
538
-            // 推送队室质控员
539
-            o.setPushTeamQc(str(c, 14));
540
-            
541
-            // 推送质控队长
542
-            o.setPushQcCaptain(str(c, 15));
543
-            
544
-            // 队室内勤
545
-            o.setTeamInternalDuty(str(c, 16));
546
-            
547
-            // 点击推送至相关人员
548
-            o.setPushToRelevant(str(c, 17));
549
-            
550
-            // 队室负责人
551
-            o.setTeamLeader(str(c, 18));
552
-            
506
+            o.setTestType(str(c, 6));           // 被测试岗位
507
+            o.setTestResult(str(c, 7));         // 测试物品
508
+            o.setEvidenceFile(str(c, 8));       // 图片或视频
509
+            o.setProblemDesc(str(c, 9));        // 是否通过
510
+            o.setTestLevel(str(c, 10));          // 层级
511
+            o.setResultHandling(str(c, 11));    // 整改措施
512
+            o.setReviewMaterial(str(c, 13));    // 整改材料
513
+
553
             // 使用缓存查找组织信息(根据被测人名称)
514
             // 使用缓存查找组织信息(根据被测人名称)
554
             if (testedName != null && !testedName.trim().isEmpty()) {
515
             if (testedName != null && !testedName.trim().isEmpty()) {
555
                 Map<String, Object> orgInfo = resolveOrgInfoByNameWithCache(testedName);
516
                 Map<String, Object> orgInfo = resolveOrgInfoByNameWithCache(testedName);

+ 7 - 13
airport-ledger/src/main/resources/mapper/ledger/LedgerSecurityTestMapper.xml

@@ -22,21 +22,15 @@
22
         <result property="positionId" column="position_id" />
22
         <result property="positionId" column="position_id" />
23
         <result property="testItem" column="test_item" />
23
         <result property="testItem" column="test_item" />
24
         <result property="testResult" column="test_result" />
24
         <result property="testResult" column="test_result" />
25
+        <result property="evidenceFile" column="evidence_file" />
25
         <result property="problemDesc" column="problem_desc" />
26
         <result property="problemDesc" column="problem_desc" />
27
+        <result property="testLevel" column="test_level" />
26
         <result property="resultHandling" column="result_handling" />
28
         <result property="resultHandling" column="result_handling" />
27
-        <result property="reviewLocationTime" column="review_location_time" />
28
         <result property="reviewMaterial" column="review_material" />
29
         <result property="reviewMaterial" column="review_material" />
29
-        <result property="pushTeamQc" column="push_team_qc" />
30
-        <result property="pushQcCaptain" column="push_qc_captain" />
31
-        <result property="teamInternalDuty" column="team_internal_duty" />
32
-        <result property="pushToRelevant" column="push_to_relevant" />
33
-        <result property="teamLeader" column="team_leader" />
34
         <result property="deductScore" column="deduct_score" />
30
         <result property="deductScore" column="deduct_score" />
35
         <result property="addScore" column="add_score" />
31
         <result property="addScore" column="add_score" />
36
         <result property="scoreDimension" column="score_dimension" />
32
         <result property="scoreDimension" column="score_dimension" />
37
         <result property="scoreIndicator" column="score_indicator" />
33
         <result property="scoreIndicator" column="score_indicator" />
38
-        <result property="evidenceFile" column="evidence_file" />
39
-        <result property="remark" column="remark" />
40
         <result property="importBatch" column="import_batch" />
34
         <result property="importBatch" column="import_batch" />
41
         <result property="sourceType" column="source_type" />
35
         <result property="sourceType" column="source_type" />
42
         <result property="createBy"   column="create_by"   />
36
         <result property="createBy"   column="create_by"   />
@@ -49,9 +43,9 @@
49
     <sql id="selectVo">
43
     <sql id="selectVo">
50
         SELECT id, record_date, region, channel, dept_name, dept_id, team_name, team_id, group_name, group_id, area_id,
44
         SELECT id, record_date, region, channel, dept_name, dept_id, team_name, team_id, group_name, group_id, area_id,
51
                tester_name, tester_id, tested_name, tested_id, test_type, position_id, test_item, test_result,
45
                tester_name, tester_id, tested_name, tested_id, test_type, position_id, test_item, test_result,
52
-               problem_desc, result_handling, review_location_time, review_material, push_team_qc, push_qc_captain,
53
-               team_internal_duty, push_to_relevant, team_leader, deduct_score, add_score, score_dimension,
54
-               score_indicator, evidence_file, remark, import_batch, source_type, create_by, create_time, update_by, update_time, sync_flag
46
+               evidence_file, problem_desc, test_level, result_handling, review_material,
47
+               deduct_score, add_score, score_dimension, score_indicator,
48
+               import_batch, source_type, create_by, create_time, update_by, update_time, sync_flag
55
         FROM ledger_security_test
49
         FROM ledger_security_test
56
         WHERE del_flag = '0'
50
         WHERE del_flag = '0'
57
     </sql>
51
     </sql>
@@ -63,10 +57,10 @@
63
         <if test="testedName != null and testedName != ''">AND tested_name LIKE CONCAT('%', #{testedName}, '%')</if>
57
         <if test="testedName != null and testedName != ''">AND tested_name LIKE CONCAT('%', #{testedName}, '%')</if>
64
         <if test="syncFlag != null and syncFlag != ''">AND sync_flag = #{syncFlag}</if>
58
         <if test="syncFlag != null and syncFlag != ''">AND sync_flag = #{syncFlag}</if>
65
         <if test="params != null and params.beginTime != null and params.beginTime != ''">
59
         <if test="params != null and params.beginTime != null and params.beginTime != ''">
66
-            AND (record_date &gt;= #{params.beginTime} OR approve_date &gt;= #{params.beginTime} OR exam_date &gt;= #{params.beginTime})
60
+            AND record_date &gt;= #{params.beginTime}
67
         </if>
61
         </if>
68
         <if test="params != null and params.endTime != null and params.endTime != ''">
62
         <if test="params != null and params.endTime != null and params.endTime != ''">
69
-            AND (record_date &lt;= #{params.endTime} OR approve_date &lt;= #{params.endTime} OR exam_date &lt;= #{params.endTime})
63
+            AND record_date &lt;= #{params.endTime}
70
         </if>
64
         </if>
71
         ORDER BY id DESC
65
         ORDER BY id DESC
72
     </select>
66
     </select>