huminmin
10 天以前 d2038a623e02c2d7bb6b95a908832c0432adf2f0
src/main/java/com/ruoyi/sales/controller/ReceiptPaymentController.java
@@ -10,6 +10,7 @@
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;
@@ -18,6 +19,7 @@
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;
@@ -40,7 +42,8 @@
     * @return
     */
    @PostMapping("/saveOrUpdate")
    public AjaxResult receiptPaymentSaveOrUpdate (@RequestBody ReceiptPayment receiptPayment) {
    @Log(title = "新增回款登记", businessType = BusinessType.INSERT)
    public AjaxResult receiptPaymentSaveOrUpdate (@RequestBody List<ReceiptPayment> receiptPayment) {
        receiptPaymentService.receiptPaymentSaveOrUpdate(receiptPayment);
        return AjaxResult.success();
    }
@@ -51,6 +54,8 @@
     * @return
     */
    @PostMapping("/update")
    @Log(title = "修改回款登记", businessType = BusinessType.UPDATE)
    @Transactional(rollbackFor = Exception.class)
    public AjaxResult receiptPaymentUpdate (@RequestBody ReceiptPayment receiptPayment) {
        return AjaxResult.success(receiptPaymentService.receiptPaymentUpdate(receiptPayment));
    }
@@ -61,6 +66,8 @@
     * @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));
    }
@@ -71,7 +78,8 @@
     * @return
     */
    @GetMapping("/customerInteractions")
    public AjaxResult customerInteractions (ReceiptPaymentDto receiptPaymentDto) {
    @Log(title = "查询客户往来记录", businessType = BusinessType.OTHER)
    public AjaxResult customerInteractions (InvoiceLedgerDto receiptPaymentDto) {
        return AjaxResult.success(receiptPaymentService.customerInteractions(receiptPaymentDto));
    }
@@ -81,6 +89,7 @@
     * @return
     */
    @GetMapping("/info")
    @Log(title = "查询回款登记详情", businessType = BusinessType.OTHER)
    public AjaxResult receiptPaymentInfo (Integer id) {
        return AjaxResult.success(receiptPaymentService.receiptPaymentInfo(id));
    }
@@ -89,6 +98,7 @@
     * 本月回款金额
     */
    @GetMapping("/getReceiptAmount")
    @Log(title = "查询本月回款金额", businessType = BusinessType.OTHER)
    public AjaxResult getReceiptAmount() {
        try {
            BigDecimal receiptAmount = receiptPaymentService.getReceiptAmount();
@@ -105,12 +115,14 @@
     * @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);
@@ -130,6 +142,7 @@
     * @return
     */
    @GetMapping("/invoiceInfo")
    @Log(title = "查询开票台账详情", businessType = BusinessType.OTHER)
    public AjaxResult invoiceInfo (Integer id) {
        return AjaxResult.success(receiptPaymentService.invoiceInfo(id));
    }
@@ -138,6 +151,7 @@
     * 本月应收,回款金额
     */
    @GetMapping("/getAmountMouth")
    @Log(title = "查询本月应收,回款金额", businessType = BusinessType.OTHER)
    public AjaxResult getAmountMouth() {
        return  AjaxResult.success(receiptPaymentService.getAmountMouth());
    }
@@ -145,6 +159,7 @@
    /**
     * 查询回款记录
     */
    @Log(title = "查询回款记录", businessType = BusinessType.OTHER)
    @GetMapping("/receiptPaymentHistoryList")
    public TableDataInfo receiptPaymentHistoryList(ReceiptPaymentDto receiptPaymentDto) {
        startPage();
@@ -156,6 +171,7 @@
     * 查询回款记录
     */
    @GetMapping("/receiptPaymentHistoryListPage")
    @Log(title = "查询回款记录", businessType = BusinessType.OTHER)
    public IPage<ReceiptPaymentDto> receiptPaymentHistoryListPage(Page page, ReceiptPaymentDto receiptPaymentDto) {
        return receiptPaymentService.receiptPaymentHistoryListPage(page,receiptPaymentDto);
    }