| | |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.framework.web.page.TableDataInfo; |
| | | import com.ruoyi.purchase.dto.InvoicePurchaseDto; |
| | | import com.ruoyi.sales.dto.InvoiceLedgerDto; |
| | | import com.ruoyi.sales.dto.ReceiptPaymentDto; |
| | | import com.ruoyi.sales.dto.ReceiptPaymentRecordDto; |
| | | import com.ruoyi.sales.dto.SalesLedgerDto; |
| | |
| | | import com.ruoyi.sales.service.ReceiptPaymentService; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("/saveOrUpdate") |
| | | @Log(title = "新增回款登记", businessType = BusinessType.INSERT) |
| | | public AjaxResult receiptPaymentSaveOrUpdate (@RequestBody List<ReceiptPayment> receiptPayment) { |
| | | receiptPaymentService.receiptPaymentSaveOrUpdate(receiptPayment); |
| | | return AjaxResult.success(); |
| | |
| | | * @return |
| | | */ |
| | | @PostMapping("/update") |
| | | @Log(title = "修改回款登记", businessType = BusinessType.UPDATE) |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public AjaxResult receiptPaymentUpdate (@RequestBody ReceiptPayment receiptPayment) { |
| | | return AjaxResult.success(receiptPaymentService.receiptPaymentUpdate(receiptPayment)); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @Log(title = "删除回款登记", businessType = BusinessType.DELETE) |
| | | @Transactional(rollbackFor = Exception.class) |
| | | public AjaxResult receiptPaymentDel (@RequestBody List<Integer> ids) { |
| | | return AjaxResult.success(receiptPaymentService.receiptPaymentDel(ids)); |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | @GetMapping("/customerInteractions") |
| | | public AjaxResult customerInteractions (ReceiptPaymentDto receiptPaymentDto) { |
| | | @Log(title = "查询客户往来记录", businessType = BusinessType.OTHER) |
| | | public AjaxResult customerInteractions (InvoiceLedgerDto receiptPaymentDto) { |
| | | return AjaxResult.success(receiptPaymentService.customerInteractions(receiptPaymentDto)); |
| | | } |
| | | |
| | |
| | | * @return |
| | | */ |
| | | @GetMapping("/info") |
| | | @Log(title = "查询回款登记详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult receiptPaymentInfo (Integer id) { |
| | | return AjaxResult.success(receiptPaymentService.receiptPaymentInfo(id)); |
| | | } |
| | |
| | | * 本月回款金额 |
| | | */ |
| | | @GetMapping("/getReceiptAmount") |
| | | @Log(title = "查询本月回款金额", businessType = BusinessType.OTHER) |
| | | public AjaxResult getReceiptAmount() { |
| | | try { |
| | | BigDecimal receiptAmount = receiptPaymentService.getReceiptAmount(); |
| | |
| | | * @return |
| | | */ |
| | | @GetMapping("/bindInvoiceNoRegPage") |
| | | @Log(title = "查询已经绑定发票的开票台账", businessType = BusinessType.OTHER) |
| | | public AjaxResult bindInvoiceNoRegPage(Page page, ReceiptPaymentDto receiptPaymentDto) { |
| | | return AjaxResult.success(receiptPaymentService.bindInvoiceNoRegPage(page,receiptPaymentDto)); |
| | | } |
| | | |
| | | @ApiModelProperty("导出回款登记") |
| | | @PostMapping("/export") |
| | | @Log(title = "导出回款登记", businessType = BusinessType.EXPORT) |
| | | public void export(HttpServletResponse response, String ids) { |
| | | if (ids == null || ids.isEmpty()) { |
| | | receiptPaymentService.exportPaymentList(response, null); |
| | |
| | | * @return |
| | | */ |
| | | @GetMapping("/invoiceInfo") |
| | | @Log(title = "查询开票台账详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceInfo (Integer id) { |
| | | return AjaxResult.success(receiptPaymentService.invoiceInfo(id)); |
| | | } |
| | |
| | | * 本月应收,回款金额 |
| | | */ |
| | | @GetMapping("/getAmountMouth") |
| | | @Log(title = "查询本月应收,回款金额", businessType = BusinessType.OTHER) |
| | | public AjaxResult getAmountMouth() { |
| | | return AjaxResult.success(receiptPaymentService.getAmountMouth()); |
| | | } |
| | |
| | | /** |
| | | * 查询回款记录 |
| | | */ |
| | | @Log(title = "查询回款记录", businessType = BusinessType.OTHER) |
| | | @GetMapping("/receiptPaymentHistoryList") |
| | | public TableDataInfo receiptPaymentHistoryList(ReceiptPaymentDto receiptPaymentDto) { |
| | | startPage(); |
| | |
| | | * 查询回款记录 |
| | | */ |
| | | @GetMapping("/receiptPaymentHistoryListPage") |
| | | @Log(title = "查询回款记录", businessType = BusinessType.OTHER) |
| | | public IPage<ReceiptPaymentDto> receiptPaymentHistoryListPage(Page page, ReceiptPaymentDto receiptPaymentDto) { |
| | | return receiptPaymentService.receiptPaymentHistoryListPage(page,receiptPaymentDto); |
| | | } |