|
@@ -34,7 +34,7 @@ import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
|
|
|
|
|
|
|
@Tag(name = "管理后台 - 员工合同信息")
|
|
@Tag(name = "管理后台 - 员工合同信息")
|
|
|
@RestController
|
|
@RestController
|
|
|
-@RequestMapping("/presonnel/relations/contract-info")
|
|
|
|
|
|
|
+@RequestMapping("/presonnel/relations/contract")
|
|
|
@Validated
|
|
@Validated
|
|
|
public class RelationsContractController {
|
|
public class RelationsContractController {
|
|
|
|
|
|
|
@@ -43,14 +43,14 @@ public class RelationsContractController {
|
|
|
|
|
|
|
|
@PostMapping("/create")
|
|
@PostMapping("/create")
|
|
|
@Operation(summary = "创建员工合同信息")
|
|
@Operation(summary = "创建员工合同信息")
|
|
|
- @PreAuthorize("@ss.hasPermission('relations:contract-info:create')")
|
|
|
|
|
|
|
+ @PreAuthorize("@ss.hasPermission('relations:contract:create')")
|
|
|
public CommonResult<Long> createContractInfo(@Valid @RequestBody RelationsContractSaveReqVO createReqVO) {
|
|
public CommonResult<Long> createContractInfo(@Valid @RequestBody RelationsContractSaveReqVO createReqVO) {
|
|
|
return success(contractInfoService.createContractInfo(createReqVO));
|
|
return success(contractInfoService.createContractInfo(createReqVO));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@PutMapping("/update")
|
|
@PutMapping("/update")
|
|
|
@Operation(summary = "更新员工合同信息")
|
|
@Operation(summary = "更新员工合同信息")
|
|
|
- @PreAuthorize("@ss.hasPermission('relations:contract-info:update')")
|
|
|
|
|
|
|
+ @PreAuthorize("@ss.hasPermission('relations:contract:update')")
|
|
|
public CommonResult<Boolean> updateContractInfo(@Valid @RequestBody RelationsContractSaveReqVO updateReqVO) {
|
|
public CommonResult<Boolean> updateContractInfo(@Valid @RequestBody RelationsContractSaveReqVO updateReqVO) {
|
|
|
contractInfoService.updateContractInfo(updateReqVO);
|
|
contractInfoService.updateContractInfo(updateReqVO);
|
|
|
return success(true);
|
|
return success(true);
|
|
@@ -59,7 +59,7 @@ public class RelationsContractController {
|
|
|
@DeleteMapping("/delete")
|
|
@DeleteMapping("/delete")
|
|
|
@Operation(summary = "删除员工合同信息")
|
|
@Operation(summary = "删除员工合同信息")
|
|
|
@Parameter(name = "id", description = "编号", required = true)
|
|
@Parameter(name = "id", description = "编号", required = true)
|
|
|
- @PreAuthorize("@ss.hasPermission('relations:contract-info:delete')")
|
|
|
|
|
|
|
+ @PreAuthorize("@ss.hasPermission('relations:contract:delete')")
|
|
|
public CommonResult<Boolean> deleteContractInfo(@RequestParam("id") Long id) {
|
|
public CommonResult<Boolean> deleteContractInfo(@RequestParam("id") Long id) {
|
|
|
contractInfoService.deleteContractInfo(id);
|
|
contractInfoService.deleteContractInfo(id);
|
|
|
return success(true);
|
|
return success(true);
|
|
@@ -68,7 +68,7 @@ public class RelationsContractController {
|
|
|
@GetMapping("/get")
|
|
@GetMapping("/get")
|
|
|
@Operation(summary = "获得员工合同信息")
|
|
@Operation(summary = "获得员工合同信息")
|
|
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
|
|
- @PreAuthorize("@ss.hasPermission('relations:contract-info:query')")
|
|
|
|
|
|
|
+ @PreAuthorize("@ss.hasPermission('relations:contract:query')")
|
|
|
public CommonResult<RelationsContractRespVO> getContractInfo(@RequestParam("id") Long id) {
|
|
public CommonResult<RelationsContractRespVO> getContractInfo(@RequestParam("id") Long id) {
|
|
|
RelationsContractDO contractInfo = contractInfoService.getContractInfo(id);
|
|
RelationsContractDO contractInfo = contractInfoService.getContractInfo(id);
|
|
|
return success(BeanUtils.toBean(contractInfo, RelationsContractRespVO.class));
|
|
return success(BeanUtils.toBean(contractInfo, RelationsContractRespVO.class));
|
|
@@ -76,7 +76,7 @@ public class RelationsContractController {
|
|
|
|
|
|
|
|
@GetMapping("/page")
|
|
@GetMapping("/page")
|
|
|
@Operation(summary = "获得员工合同信息分页")
|
|
@Operation(summary = "获得员工合同信息分页")
|
|
|
- @PreAuthorize("@ss.hasPermission('relations:contract-info:query')")
|
|
|
|
|
|
|
+ @PreAuthorize("@ss.hasPermission('relations:contract:query')")
|
|
|
public CommonResult<PageResult<RelationsContractRespVO>> getContractInfoPage(@Valid RelationsContractPageReqVO pageReqVO) {
|
|
public CommonResult<PageResult<RelationsContractRespVO>> getContractInfoPage(@Valid RelationsContractPageReqVO pageReqVO) {
|
|
|
PageResult<RelationsContractDO> pageResult = contractInfoService.getContractInfoPage(pageReqVO);
|
|
PageResult<RelationsContractDO> pageResult = contractInfoService.getContractInfoPage(pageReqVO);
|
|
|
return success(BeanUtils.toBean(pageResult, RelationsContractRespVO.class));
|
|
return success(BeanUtils.toBean(pageResult, RelationsContractRespVO.class));
|
|
@@ -84,7 +84,7 @@ public class RelationsContractController {
|
|
|
|
|
|
|
|
@GetMapping("/export-excel")
|
|
@GetMapping("/export-excel")
|
|
|
@Operation(summary = "导出员工合同信息 Excel")
|
|
@Operation(summary = "导出员工合同信息 Excel")
|
|
|
- @PreAuthorize("@ss.hasPermission('relations:contract-info:export')")
|
|
|
|
|
|
|
+ @PreAuthorize("@ss.hasPermission('relations:contract:export')")
|
|
|
@ApiAccessLog(operateType = EXPORT)
|
|
@ApiAccessLog(operateType = EXPORT)
|
|
|
public void exportContractInfoExcel(@Valid RelationsContractPageReqVO pageReqVO,
|
|
public void exportContractInfoExcel(@Valid RelationsContractPageReqVO pageReqVO,
|
|
|
HttpServletResponse response) throws IOException {
|
|
HttpServletResponse response) throws IOException {
|