| | |
| | | @Log(title = "财务管理-添加", businessType = BusinessType.INSERT) |
| | | @PostMapping(value = "/add") |
| | | public R<Boolean> add(@RequestBody YcFinancialManagement dto) { |
| | | YcRevenueExpenditureType ycRevenueExpenditureType = ycRevenueExpenditureTypeService.getById(dto.getTypeId()); |
| | | if(Objects.nonNull(ycRevenueExpenditureType)){ |
| | | dto.setRevenueType(ycRevenueExpenditureType.getRevenueType()); |
| | | } |
| | | return R.ok(ycFinancialManagementService.save(dto)); |
| | | } |
| | | |
| | |
| | | @ApiOperation( value = "删除财务管理") |
| | | @Log(title = "财务管理-删除", businessType = BusinessType.DELETE) |
| | | @DeleteMapping(value = "/deleteById") |
| | | public R<Boolean> deleteById(@RequestParam("id") Long id) { |
| | | public R<Boolean> deleteById(@RequestParam("id") Integer id) { |
| | | return R.ok(ycFinancialManagementService.removeById(id)); |
| | | } |
| | | |