| | |
| | | * @return |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @Log(title = "在职员工台账分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffOnJobListPage(Page page, StaffOnJob staffOnJob) { |
| | | return AjaxResult.success(staffOnJobService.staffOnJobListPage(page, staffOnJob)); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | @GetMapping("/list") |
| | | @Log(title = "在职员工下拉(新增离职用)", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffOnJobList(StaffOnJob staffOnJob) { |
| | | return AjaxResult.success(staffOnJobService.staffOnJobList(staffOnJob)); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("") |
| | | @Log(title = "新增入职", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody StaffOnJobDto staffOnJob) { |
| | | return AjaxResult.success(staffOnJobService.add(staffOnJob)); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | @PutMapping("/{id}") |
| | | @Log(title = "更新入职信息", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@PathVariable("id") Long id, @RequestBody StaffOnJobDto staffOnJobDto) { |
| | | return AjaxResult.success(staffOnJobService.update(id, staffOnJobDto)); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @Log(title = "删除入职", businessType = BusinessType.DELETE) |
| | | public AjaxResult delStaffOnJobs(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | * @return |
| | | */ |
| | | @GetMapping("/{id}") |
| | | @Log(title = "在职员工详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffOnJobDetail(@PathVariable("id") Long id) { |
| | | return AjaxResult.success(staffOnJobService.staffOnJobDetail(id)); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("/renewContract/{id}") |
| | | @Log(title = "续签合同", businessType = BusinessType.UPDATE) |
| | | public AjaxResult renewContract(@PathVariable("id") Long id, @RequestBody StaffContract staffContract) { |
| | | return AjaxResult.success(staffOnJobService.renewContract(id, staffContract)); |
| | | } |
| | |
| | | * @param staffOnJob |
| | | */ |
| | | @PostMapping("/export") |
| | | @Log(title = "在职员工导出", businessType = BusinessType.EXPORT) |
| | | public void staffOnJobExport(HttpServletResponse response,StaffOnJob staffOnJob) { |
| | | staffOnJobService.staffOnJobExport(response, staffOnJob); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/exportCopy") |
| | | @ApiOperation("word模板合同在职员工导出") |
| | | @Log(title = "word模板合同在职员工导出", businessType = BusinessType.EXPORT) |
| | | public AjaxResult exportCopy(HttpServletResponse response,@RequestBody StaffOnJob staffOnJob) throws Exception{ |
| | | return AjaxResult.success(staffOnJobService.exportCopy(response, staffOnJob)); |
| | | } |