From 538b7dc4a871e99a3e6353ec00e3a9e6b0df7e26 Mon Sep 17 00:00:00 2001
From: BAOLH <baolh@yhzhg.cn>
Date: Wed, 13 Aug 2025 08:18:49 +0000
Subject: [PATCH] 因打卡未闭环导致的工资计算问题修改(限制更新类型)
---
eladmin-master/eladmin-system/src/main/java/me/zhengjie/modules/contract/rest/ContractController.java | 20 +++++++++++++++++++-
1 files changed, 19 insertions(+), 1 deletions(-)
diff --git a/eladmin-master/eladmin-system/src/main/java/me/zhengjie/modules/contract/rest/ContractController.java b/eladmin-master/eladmin-system/src/main/java/me/zhengjie/modules/contract/rest/ContractController.java
index 8dc451e..bea14b9 100644
--- a/eladmin-master/eladmin-system/src/main/java/me/zhengjie/modules/contract/rest/ContractController.java
+++ b/eladmin-master/eladmin-system/src/main/java/me/zhengjie/modules/contract/rest/ContractController.java
@@ -22,6 +22,7 @@
import me.zhengjie.modules.contract.domain.Contract;
import me.zhengjie.modules.contract.service.ContractService;
import me.zhengjie.modules.contract.service.dto.ContractQueryCriteria;
+import me.zhengjie.utils.SecurityUtils;
import org.springframework.data.domain.Pageable;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
@@ -48,10 +49,19 @@
@Log("导出数据")
@ApiOperation("导出数据")
- @GetMapping(value = "/download")
+ @GetMapping(value = "/download/old")
@PreAuthorize("@el.check('contract:download')")
public void exportContract(HttpServletResponse response, ContractQueryCriteria criteria) throws IOException {
+ criteria.setCompanys(SecurityUtils.getCompanyIds());
contractService.download(contractService.queryAll(criteria), response);
+ }
+
+ @Log("导出数据(新)")
+ @ApiOperation("导出数据(新)")
+ @GetMapping(value = "/download")
+ @PreAuthorize("@el.check('contract:download')")
+ public void exportContractNew(HttpServletResponse response, ContractQueryCriteria criteria) throws IOException {
+ contractService.download(criteria, response);
}
@GetMapping
@@ -184,4 +194,12 @@
public void downloadContractAttachments(HttpServletResponse response, Long id) {
contractService.downloadContractAttachments(id, response);
}
+
+ @Log("统计合同信息")
+ @ApiOperation("统计合同信息")
+ @GetMapping(value = "/statistics/{type}")
+ @PreAuthorize("@el.check('contract:list')")
+ public ResponseEntity<Object> contractStatistics(ContractQueryCriteria criteria, @PathVariable Integer type){
+ return new ResponseEntity<>(contractService.contractStatistics(criteria, type), HttpStatus.OK);
+ }
}
\ No newline at end of file
--
Gitblit v1.9.3