| | |
| | | import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.EXPORT; |
| | | import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success; |
| | | import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.*; |
| | | import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId; |
| | | |
| | | @Tag(name = "管理后台 - ERP 付款单") |
| | | @RestController |
| | |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/update-status") |
| | | @Operation(summary = "更新付款单的状态") |
| | | @PreAuthorize("@ss.hasPermission('erp:finance-payment:update-status')") |
| | | public CommonResult<Boolean> updateFinancePaymentStatus(@RequestParam("id") Long id, |
| | | @RequestParam("status") Integer status) { |
| | | financePaymentService.updateFinancePaymentStatus(id, status); |
| | | @PostMapping("/submit") |
| | | @Operation(summary = "提交付款单审批") |
| | | @PreAuthorize("@ss.hasPermission('erp:finance-payment:update')") |
| | | public CommonResult<Boolean> submitFinancePayment(@RequestParam("id") Long id, |
| | | @RequestParam("processDefinitionKey") String processDefinitionKey) { |
| | | Long userId = getLoginUserId(); |
| | | financePaymentService.submitFinancePayment(id, processDefinitionKey, userId); |
| | | return success(true); |
| | | } |
| | | |
| | | @GetMapping("/approve-process-list") |
| | | @Operation(summary = "获取付款单审批流程列表") |
| | | @PreAuthorize("@ss.hasPermission('erp:finance-payment:query')") |
| | | public CommonResult<List<Map<String, Object>>> getApproveProcessList() { |
| | | return success(financePaymentService.getFinancePaymentApproveProcessDefinitionList()); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "删除付款单") |
| | | @Parameter(name = "ids", description = "编号数组", required = true) |