| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.servlet.http.HttpServletResponse; |
| | | import java.math.BigDecimal; |
| | | import java.util.List; |
| | | |
| | | /** |
| | |
| | | |
| | | /** |
| | | * 查询销售台账不分页 |
| | | * |
| | | * @param salesLedgerDto |
| | | * @return |
| | | */ |
| | | @GetMapping("/listNoPage") |
| | | public AjaxResult listNoPage(SalesLedgerDto salesLedgerDto){ |
| | | public AjaxResult listNoPage(SalesLedgerDto salesLedgerDto) { |
| | | List<SalesLedger> list = salesLedgerService.selectSalesLedgerList(salesLedgerDto); |
| | | return AjaxResult.success(list); |
| | | } |
| | |
| | | } |
| | | return toAjax(commonFileService.deleteSalesLedgerByIds(ids)); |
| | | } |
| | | |
| | | /** |
| | | * 本月销售合同金额 |
| | | */ |
| | | @GetMapping("/getContractAmount") |
| | | public AjaxResult getContractAmount() { |
| | | try { |
| | | BigDecimal contractAmount = salesLedgerService.getContractAmount(); |
| | | return AjaxResult.success(contractAmount != null ? contractAmount : BigDecimal.ZERO); |
| | | } catch (Exception e) { |
| | | return AjaxResult.error("获取合同金额失败:" + e.getMessage()); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 客户合同金额TOP5统计 |
| | | */ |
| | | @GetMapping("/getTopFiveList") |
| | | public AjaxResult getTopFiveList() { |
| | | return AjaxResult.success(salesLedgerService.getTopFiveList()); |
| | | } |
| | | |
| | | /** |
| | | * 近半年开票,回款金额 |
| | | */ |
| | | @GetMapping("/getAmountHalfYear") |
| | | public AjaxResult getAmountHalfYear() { |
| | | return AjaxResult.success(salesLedgerService.getAmountHalfYear()); |
| | | } |
| | | } |