| | |
| | | |
| | | @GetMapping("/approveAndDeviceTodos") |
| | | @ApiOperation("审批协同,设备报修待办事项") |
| | | @Log(title = "审批协同,设备报修待办事项", businessType = BusinessType.OTHER) |
| | | public AjaxResult approveAndDeviceTodos(){ |
| | | Map<String, Object> map = homeService.approveAndDeviceTodos(); |
| | | return AjaxResult.success(map); |
| | |
| | | |
| | | @GetMapping("/noticesCount") |
| | | @ApiOperation("未过期的公告数量") |
| | | @Log(title = "未过期的公告数量", businessType = BusinessType.OTHER) |
| | | public AjaxResult noticesCount(){ |
| | | Long count = homeService.noticesCount(); |
| | | return AjaxResult.success(count); |
| | |
| | | |
| | | @GetMapping("/deptStaffDistribution") |
| | | @ApiOperation("各部门人员分布") |
| | | @Log(title = "各部门人员分布", businessType = BusinessType.OTHER) |
| | | public AjaxResult deptStaffDistribution() { |
| | | DeptStaffDistributionDto dto = homeService.deptStaffDistribution(); |
| | | return AjaxResult.success(dto); |
| | |
| | | |
| | | @GetMapping("/summaryStatistics") |
| | | @ApiOperation("员工-客户-供应商总数") |
| | | @Log(title = "员工-客户-供应商总数", businessType = BusinessType.OTHER) |
| | | public AjaxResult summaryStatistics() { |
| | | HomeSummaryDto homeSummaryDto = homeService.summaryStatistics(); |
| | | return AjaxResult.success(homeSummaryDto); |
| | |
| | | /********************************************************营销采购类**************************************************/ |
| | | @GetMapping("/supplierPurchaseRanking") |
| | | @ApiOperation("供应商采购排名") |
| | | @Log(title = "供应商采购排名", businessType = BusinessType.OTHER) |
| | | public AjaxResult supplierPurchaseRanking(@DefaultType Integer type) { |
| | | List<SupplierPurchaseRankingDto> list = homeService.supplierPurchaseRanking(type); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/customerRevenueAnalysis") |
| | | @ApiOperation("客户营收贡献数值分析") |
| | | @Log(title = "客户营收贡献数值分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult customerRevenueAnalysis(Long customerId, @DefaultType Integer type) { |
| | | CustomerRevenueAnalysisDto dto = homeService.customerRevenueAnalysis(customerId, type); |
| | | return AjaxResult.success(dto); |
| | |
| | | |
| | | @GetMapping("/customerContributionRanking") |
| | | @ApiOperation("客户金额贡献排名") |
| | | @Log(title = "客户金额贡献排名", businessType = BusinessType.OTHER) |
| | | public AjaxResult customerContributionRanking(@DefaultType Integer type) { |
| | | List<CustomerContributionRankingDto> list = homeService.customerContributionRanking(type); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/productSalesAnalysis") |
| | | @ApiOperation("各产品销售金额分析") |
| | | @Log(title = "各产品销售金额分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult productSalesAnalysis() { |
| | | List<MapDto> list = homeService.productSalesAnalysis(); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/rawMaterialPurchaseAmountRatio") |
| | | @ApiOperation("原材料采购金额占比") |
| | | @Log(title = "原材料采购金额占比", businessType = BusinessType.OTHER) |
| | | public AjaxResult rawMaterialPurchaseAmountRatio(){ |
| | | List<MapDto> list = homeService.rawMaterialPurchaseAmountRatio(); |
| | | return AjaxResult.success(list); |
| | |
| | | /********************************************************生产类*****************************************************/ |
| | | @GetMapping("/inputOutputAnalysis") |
| | | @ApiOperation("投入产出分析") |
| | | @Log(title = "投入产出分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult inputOutputAnalysis(@DefaultType Integer type){ |
| | | List<InputOutputAnalysisDto> list = homeService.inputOutputAnalysis(type); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/processOutputAnalysis") |
| | | @ApiOperation("工序产出分析") |
| | | @Log(title = "工序产出分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult processOutputAnalysis(@DefaultType Integer type){ |
| | | List<MapDto> list = homeService.processOutputAnalysis(type); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/workOrderEfficiencyAnalysis") |
| | | @ApiOperation("工单执行效率分析") |
| | | @Log(title = "工单执行效率分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult workOrderEfficiencyAnalysis(@DefaultType Integer type){ |
| | | List<WorkOrderEfficiencyDto> list = homeService.workOrderEfficiencyAnalysis(type); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/productionAccountingAnalysis") |
| | | @ApiOperation("生产核算分析") |
| | | @Log(title = "生产核算分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult productionAccountingAnalysis(@DefaultType Integer type){ |
| | | List<ProductionAccountingDto> list = homeService.productionAccountingAnalysis(type); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/orderCount") |
| | | @ApiOperation("订单数") |
| | | @Log(title = "订单数", businessType = BusinessType.OTHER) |
| | | public AjaxResult orderCount(){ |
| | | return AjaxResult.success(homeService.orderCount()); |
| | | } |
| | | |
| | | @GetMapping("/progressStatistics") |
| | | @ApiOperation("各生产订单的完成进度统计") |
| | | @Log(title = "各生产订单的完成进度统计", businessType = BusinessType.OTHER) |
| | | public AjaxResult progressStatistics(){ |
| | | ProductionProgressDto productionProgressDto = homeService.productionProgress(); |
| | | return AjaxResult.success(productionProgressDto); |
| | |
| | | |
| | | @GetMapping("/workInProcessTurnover") |
| | | @ApiOperation("在制品周转情况") |
| | | @Log(title = "在制品周转情况", businessType = BusinessType.OTHER) |
| | | public AjaxResult workInProcessTurnover(){ |
| | | ProductionTurnoverDto productionTurnoverDto = homeService.workInProcessTurnover(); |
| | | return AjaxResult.success(productionTurnoverDto); |
| | |
| | | |
| | | @GetMapping("/processDataProductionStatistics") |
| | | @ApiOperation("工序数据生产统计数据") |
| | | @Log(title = "工序数据生产统计数据", businessType = BusinessType.OTHER) |
| | | public AjaxResult processDataProductionStatistics(@DefaultType Integer type,@RequestParam(required = false) List<Long> processIds) { |
| | | List<processDataProductionStatisticsDto> list = homeService.processDataProductionStatistics(type, processIds); |
| | | return AjaxResult.success(list); |
| | |
| | | /********************************************************质量类*****************************************************/ |
| | | @GetMapping("/rawMaterialDetection") |
| | | @ApiOperation("原材料检测") |
| | | @Log(title = "原材料检测", businessType = BusinessType.OTHER) |
| | | public AjaxResult rawMaterialDetection(@DefaultType Integer type){ |
| | | return AjaxResult.success(homeService.rawMaterialDetection(type)); |
| | | } |
| | | |
| | | @GetMapping("/processDetection") |
| | | @ApiOperation("过程检测") |
| | | @Log(title = "过程检测", businessType = BusinessType.OTHER) |
| | | public AjaxResult processDetection(@DefaultType Integer type){ |
| | | return AjaxResult.success(homeService.processDetection(type)); |
| | | } |
| | | |
| | | @GetMapping("/factoryDetection") |
| | | @ApiOperation("成品出厂检测") |
| | | @Log(title = "成品出厂检测", businessType = BusinessType.OTHER) |
| | | public AjaxResult factoryDetection(@DefaultType Integer type){ |
| | | return AjaxResult.success(homeService.factoryDetection(type)); |
| | | } |
| | | |
| | | @GetMapping("/qualityInspectionCount") |
| | | @ApiOperation("质量检验数量") |
| | | @Log(title = "质量检验数量", businessType = BusinessType.OTHER) |
| | | public AjaxResult qualityInspectionCount(){ |
| | | QualityInspectionCountDto qualityInspectionCountDto = homeService.qualityInspectionCount(); |
| | | return AjaxResult.success(qualityInspectionCountDto); |
| | |
| | | |
| | | @GetMapping("/nonComplianceWarning") |
| | | @ApiOperation("不合格预警") |
| | | @Log(title = "不合格预警", businessType = BusinessType.OTHER) |
| | | public AjaxResult nonComplianceWarning(){ |
| | | NonComplianceWarningDto nonComplianceWarningDto = homeService.nonComplianceWarning(); |
| | | return AjaxResult.success(nonComplianceWarningDto); |
| | |
| | | |
| | | @GetMapping("/completedInspectionCount") |
| | | @ApiOperation("完成检验数") |
| | | @Log(title = "完成检验数", businessType = BusinessType.OTHER) |
| | | public AjaxResult completedInspectionCount(){ |
| | | List<CompletedInspectionCountDto> list = homeService.completedInspectionCount(); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/unqualifiedProductRanking") |
| | | @ApiOperation("不合格产品排名") |
| | | @Log(title = "不合格产品排名", businessType = BusinessType.OTHER) |
| | | public AjaxResult unqualifiedProductRanking(){ |
| | | List<UnqualifiedProductRankDto> list = homeService.unqualifiedProductRanking(); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/unqualifiedProductProcessingAnalysis") |
| | | @ApiOperation("不合格检品处理分析") |
| | | @Log(title = "不合格检品处理分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult unqualifiedProductProcessingAnalysis(){ |
| | | List<MapDto> list = homeService.unqualifiedProductProcessingAnalysis(); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/qualityInspectionStatistics") |
| | | @ApiOperation("质量统计") |
| | | @Log(title = "质量统计", businessType = BusinessType.OTHER) |
| | | public AjaxResult qualityInspectionStatistics(@DefaultType Integer type) { |
| | | QualityStatisticsDto dto = homeService.qualityInspectionStatistics(type); |
| | | return AjaxResult.success(dto); |
| | |
| | | /********************************************************财务类*****************************************************/ |
| | | @GetMapping("/incomeExpenseAnalysis") |
| | | @ApiOperation("支收对比分析") |
| | | @Log(title = "支收对比分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult incomeExpenseAnalysis(@DefaultType Integer type) { |
| | | List<Map<String, Object>> result = homeService.incomeExpenseAnalysis(type); |
| | | return AjaxResult.success(result); |
| | |
| | | |
| | | @GetMapping("/profitTrendAnalysis") |
| | | @ApiOperation("利润趋势分析") |
| | | @Log(title = "利润趋势分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult profitTrendAnalysis(){ |
| | | List<MapDto> list = homeService.profitTrendAnalysis(); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/expenseCompositionAnalysis") |
| | | @ApiOperation("构成分析") |
| | | @Log(title = "构成分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult expenseCompositionAnalysis(@DefaultType Integer type) { |
| | | List<MapDto> list = homeService.expenseCompositionAnalysis(type); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/monthlyIncome") |
| | | @ApiOperation("月度收入") |
| | | @Log(title = "月度收入", businessType = BusinessType.OTHER) |
| | | public AjaxResult monthlyIncome(){ |
| | | MonthlyIncomeDto dto = homeService.monthlyIncome(); |
| | | return AjaxResult.success(dto); |
| | |
| | | |
| | | @GetMapping("/monthlyExpenditure") |
| | | @ApiOperation("月度支出") |
| | | @Log(title = "月度支出", businessType = BusinessType.OTHER) |
| | | public AjaxResult monthlyExpenditure(){ |
| | | MonthlyExpenditureDto dto = homeService.monthlyExpenditure(); |
| | | return AjaxResult.success(dto); |
| | |
| | | |
| | | @GetMapping("/productCategoryDistribution") |
| | | @ApiOperation("产品大类分布") |
| | | @Log(title = "产品大类分布", businessType = BusinessType.OTHER) |
| | | public AjaxResult productCategoryDistribution() { |
| | | ProductCategoryDistributionDto dto = homeService.productCategoryDistribution(); |
| | | return AjaxResult.success(dto); |
| | |
| | | |
| | | @GetMapping("/salesPurchaseStorageProductCount") |
| | | @ApiOperation("销售-采购-储存产品数") |
| | | @Log(title = "销售-采购-储存产品数", businessType = BusinessType.OTHER) |
| | | public AjaxResult salesPurchaseStorageProductCount(){ |
| | | List<MapDto> list = homeService.salesPurchaseStorageProductCount(); |
| | | return AjaxResult.success(list); |
| | |
| | | |
| | | @GetMapping("/productInOutAnalysis") |
| | | @ApiOperation("产品出入库分析") |
| | | @Log(title = "产品出入库分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult productInOutAnalysis(@DefaultType Integer type){ |
| | | List<Map<String, Object>> result = homeService.productInOutAnalysis(type); |
| | | return AjaxResult.success(result); |
| | |
| | | |
| | | @GetMapping("/productTurnoverDays") |
| | | @ApiOperation("产品周转天数") |
| | | @Log(title = "产品周转天数", businessType = BusinessType.OTHER) |
| | | public AjaxResult productTurnoverDays(){ |
| | | List<MapDto> list = homeService.productTurnoverDays(); |
| | | return AjaxResult.success(list); |
| | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.common.enums.StockInQualifiedRecordTypeEnum; |
| | | import com.ruoyi.common.enums.StockOutQualifiedRecordTypeEnum; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.procurementrecord.service.ProcurementRecordService; |
| | | import com.ruoyi.procurementrecord.utils.StockUtils; |
| | |
| | | */ |
| | | @PostMapping("/add") |
| | | @ApiOperation("新增检验") |
| | | @Log(title = "新增检验", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody QualityInspectDto qualityInspectDto) { |
| | | return AjaxResult.success(qualityInspectService.add(qualityInspectDto)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除检验") |
| | | @Log(title = "删除检验", businessType = BusinessType.DELETE) |
| | | public AjaxResult delQualityInspect(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | */ |
| | | @GetMapping("/{id}") |
| | | @ApiOperation("检验单详情") |
| | | @Log(title = "检验单详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult QualityInspectDetail(@PathVariable("id") Integer id) { |
| | | return AjaxResult.success(qualityInspectService.getDetailById(id)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperation("修改检验单") |
| | | @Log(title = "修改检验单", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@RequestBody QualityInspectDto qualityInspectDto) { |
| | | return AjaxResult.success(qualityInspectService.updateQualityInspect(qualityInspectDto)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("检验单分页查询") |
| | | @Log(title = "检验单分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult qualityInspectListPage(Page page, QualityInspect qualityInspect) { |
| | | return AjaxResult.success(qualityInspectService.qualityInspectListPage(page, qualityInspect)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/export") |
| | | @ApiOperation("导出检验单") |
| | | @Log(title = "导出检验单", businessType = BusinessType.EXPORT) |
| | | public void qualityInspectExport(HttpServletResponse response,QualityInspect qualityInspect) { |
| | | qualityInspectService.qualityInspectExport(response, qualityInspect); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/submit") |
| | | @ApiOperation("提交检验单") |
| | | @Log(title = "提交检验单", businessType = BusinessType.UPDATE) |
| | | public AjaxResult submit(@RequestBody QualityInspect qualityInspect) { |
| | | return AjaxResult.success(qualityInspectService.submit(qualityInspect)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/down") |
| | | @ApiOperation("下载检验单附件") |
| | | @Log(title = "下载检验单附件", businessType = BusinessType.OTHER) |
| | | public void down(HttpServletResponse response,@RequestBody QualityInspect qualityInspect) { |
| | | qualityInspectService.down(response, qualityInspect); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/downOutReport") |
| | | @ApiOperation("下载出库检验报告") |
| | | @Log(title = "下载出库检验报告", businessType = BusinessType.OTHER) |
| | | public void downOutReport(HttpServletResponse response, @RequestBody QualityInspect qualityInspect) { |
| | | qualityInspectService.downOutReport(response, qualityInspect); |
| | | } |
| | |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.quality.pojo.QualityInspect; |
| | | import com.ruoyi.quality.pojo.QualityInspectFile; |
| | |
| | | */ |
| | | @PostMapping("/add") |
| | | @ApiOperation("新增检验附件") |
| | | @Log(title = "新增检验附件", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody QualityInspectFile qualityInspectFile) { |
| | | return AjaxResult.success(qualityInspectFileService.save(qualityInspectFile)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除检验附件") |
| | | @Log(title = "删除检验附件", businessType = BusinessType.DELETE) |
| | | public AjaxResult delQualityUnqualified(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("检验附件分页查询") |
| | | @Log(title = "检验附件分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult qualityInspectFileListPage(Page page, QualityInspectFile qualityInspectFile) { |
| | | return AjaxResult.success(qualityInspectFileService.qualityInspectFileListPage(page, qualityInspectFile)); |
| | | } |
| | |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.quality.pojo.QualityInspect; |
| | | import com.ruoyi.quality.pojo.QualityInspectFile; |
| | |
| | | */ |
| | | @GetMapping("/{inspectId}") |
| | | @ApiOperation("检验参数项详情") |
| | | @Log(title = "检验参数项详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult QualityInspectParamDetail(@PathVariable("inspectId") Integer inspectId) { |
| | | return AjaxResult.success(qualityInspectParamService.qualityInspectParamDetail(inspectId)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperation("修改检验参数项") |
| | | @Log(title = "修改检验参数项", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@RequestBody List<QualityInspectParam> qualityInspectParams) { |
| | | return AjaxResult.success(qualityInspectParamService.updateBatchById(qualityInspectParams)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除检验参数项") |
| | | @Log(title = "删除检验参数项", businessType = BusinessType.DELETE) |
| | | public AjaxResult delQualityUnqualified(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | package com.ruoyi.quality.controller; |
| | | |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.quality.service.QualityReportService; |
| | | import io.swagger.annotations.Api; |
| | |
| | | */ |
| | | @ApiOperation("获取检验统计数据") |
| | | @GetMapping("/getInspectStatistics") |
| | | @Log(title = "获取检验统计数据", businessType = BusinessType.OTHER) |
| | | public AjaxResult getInspectStatistics() { |
| | | return AjaxResult.success(qualityReportService.getInspectStatistics()); |
| | | } |
| | |
| | | */ |
| | | @ApiOperation("获取合格率统计数据") |
| | | @GetMapping("/getPassRateStatistics") |
| | | @Log(title = "获取合格率统计数据", businessType = BusinessType.OTHER) |
| | | public AjaxResult getPassRateStatistics() { |
| | | return AjaxResult.success(qualityReportService.getPassRateStatistics()); |
| | | } |
| | |
| | | */ |
| | | @ApiOperation("获取月度合格率统计数据") |
| | | @GetMapping("/getMonthlyPassRateStatistics") |
| | | @Log(title = "获取月度合格率统计数据", businessType = BusinessType.OTHER) |
| | | public AjaxResult getMonthlyPassRateStatistics(@RequestParam("year") String year) { |
| | | return AjaxResult.success(qualityReportService.getMonthlyPassRateStatistics(year)); |
| | | } |
| | |
| | | */ |
| | | @ApiOperation("获取年度总合格率统计数据") |
| | | @GetMapping("/getYearlyPassRateStatistics") |
| | | @Log(title = "获取年度总合格率统计数据", businessType = BusinessType.OTHER) |
| | | public AjaxResult getYearlyPassRateStatistics(@RequestParam("year") String year) { |
| | | return AjaxResult.success(qualityReportService.getYearlyPassRateStatistics(year)); |
| | | } |
| | |
| | | */ |
| | | @ApiOperation("获取月度完成明细数据") |
| | | @GetMapping("/getMonthlyCompletionDetails") |
| | | @Log(title = "获取月度完成明细数据", businessType = BusinessType.OTHER) |
| | | public AjaxResult getMonthlyCompletionDetails(@RequestParam("year") String year) { |
| | | return AjaxResult.success(qualityReportService.getMonthlyCompletionDetails(year)); |
| | | } |
| | |
| | | */ |
| | | @ApiOperation("获取热点检测指标统计") |
| | | @GetMapping("/getTopParameters") |
| | | @Log(title = "获取热点检测指标统计", businessType = BusinessType.OTHER) |
| | | public AjaxResult getTopParameters(@RequestParam("modelType") Integer modelType) { |
| | | return AjaxResult.success(qualityReportService.getTopParameters(modelType)); |
| | | } |
| | |
| | | package com.ruoyi.quality.controller; |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.quality.pojo.QualityTestStandardBinding; |
| | | import com.ruoyi.quality.pojo.QualityTestStandardParam; |
| | |
| | | */ |
| | | @PostMapping("/add") |
| | | @ApiOperation("新增检测标准主表与产品关联表") |
| | | @Log(title = "新增检测标准主表与产品关联表", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody List<QualityTestStandardBinding> qualityTestStandardBindings) { |
| | | return AjaxResult.success(qualityTestStandardBindingService.add(qualityTestStandardBindings)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除检测标准主表与产品关联表") |
| | | @Log(title = "删除检测标准主表与产品关联表", businessType = BusinessType.DELETE) |
| | | public AjaxResult delQualityTestStandard(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperation("检测指标维护查询") |
| | | @Log(title = "检测指标维护查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult listBinding(Long testStandardId) { |
| | | return AjaxResult.success(qualityTestStandardBindingService.listBinding(testStandardId)); |
| | | } |
| | |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.quality.pojo.QualityTestStandard; |
| | | import com.ruoyi.quality.pojo.QualityTestStandardParam; |
| | |
| | | */ |
| | | @PostMapping("/add") |
| | | @ApiOperation("新增检测标准") |
| | | @Log(title = "新增检测标准", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody QualityTestStandard qualityTestStandard) { |
| | | return AjaxResult.success(qualityTestStandardService.save(qualityTestStandard)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除检测标准") |
| | | @Log(title = "删除检测标准", businessType = BusinessType.DELETE) |
| | | public AjaxResult delQualityTestStandard(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperation("修改检测标准") |
| | | @Log(title = "修改检测标准", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@RequestBody QualityTestStandard qualityTestStandard) { |
| | | return AjaxResult.success(qualityTestStandardService.updateById(qualityTestStandard)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("检测标准分页查询") |
| | | @Log(title = "检测标准分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult qualityTestStandardListPage(Page page, QualityTestStandard qualityTestStandard) { |
| | | return AjaxResult.success(qualityTestStandardService.qualityTestStandardListPage(page, qualityTestStandard)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/copyParam") |
| | | @ApiOperation("复制检测标准参数") |
| | | @Log(title = "复制检测标准参数", businessType = BusinessType.OTHER) |
| | | public AjaxResult copyParam(@RequestBody QualityTestStandard qualityTestStandard) { |
| | | return AjaxResult.success(qualityTestStandardService.copyParam(qualityTestStandard)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/qualityTestStandardAudit") |
| | | @ApiOperation("批量审核检测标准") |
| | | @Log(title = "批量审核检测标准", businessType = BusinessType.OTHER) |
| | | public AjaxResult qualityTestStandardAudit(@RequestBody List<QualityTestStandard> qualityTestStandards) { |
| | | return AjaxResult.success(qualityTestStandardService.updateBatchById(qualityTestStandards)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/getQualityTestStandardByProductId") |
| | | @ApiOperation("根据产品id查询相关的检验标准") |
| | | @Log(title = "根据产品id查询相关的检验标准", businessType = BusinessType.OTHER) |
| | | public AjaxResult getQualityTestStandardByProductId(@Nonnull Long productId, @Nonnull Integer inspectType, String process) { |
| | | return AjaxResult.success(qualityTestStandardService.getQualityTestStandardByProductId(productId,inspectType,process)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/getQualityTestStandardParamByTestStandardId") |
| | | @ApiOperation("根据检测标准id查询相关的检验标准参数") |
| | | @Log(title = "根据检测标准id查询相关的检验标准参数", businessType = BusinessType.OTHER) |
| | | public AjaxResult getQualityTestStandardParamByTestStandardId(Long testStandardId) { |
| | | return AjaxResult.success(qualityTestStandardParamService.list(Wrappers.<QualityTestStandardParam>lambdaQuery().eq(QualityTestStandardParam::getTestStandardId, testStandardId))); |
| | | } |
| | |
| | | |
| | | import com.baomidou.mybatisplus.core.toolkit.Wrappers; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.quality.pojo.QualityTestStandard; |
| | | import com.ruoyi.quality.pojo.QualityTestStandardParam; |
| | |
| | | */ |
| | | @PostMapping("/add") |
| | | @ApiOperation("新增检测标准参数") |
| | | @Log(title = "新增检测标准参数", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody QualityTestStandardParam qualityTestStandardParam) { |
| | | return AjaxResult.success(qualityTestStandardParamService.save(qualityTestStandardParam)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除检测标准参数") |
| | | @Log(title = "删除检测标准参数", businessType = BusinessType.DELETE) |
| | | public AjaxResult delQualityTestStandard(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperation("修改检测标准参数") |
| | | @Log(title = "修改检测标准参数", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@RequestBody QualityTestStandardParam qualityTestStandardParam) { |
| | | return AjaxResult.success(qualityTestStandardParamService.updateById(qualityTestStandardParam)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperation("查询检测标准参数") |
| | | @Log(title = "查询检测标准参数", businessType = BusinessType.OTHER) |
| | | public AjaxResult list(Long testStandardId) { |
| | | return AjaxResult.success(qualityTestStandardParamService.list(Wrappers.<QualityTestStandardParam>lambdaQuery().eq(QualityTestStandardParam::getTestStandardId,testStandardId))); |
| | | } |
| | |
| | | package com.ruoyi.quality.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.quality.pojo.QualityUnqualified; |
| | | import com.ruoyi.quality.service.IQualityUnqualifiedService; |
| | |
| | | */ |
| | | @PostMapping("/add") |
| | | @ApiOperation("新增不合格管理") |
| | | @Log(title = "新增不合格管理", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody QualityUnqualified qualityUnqualified) { |
| | | qualityUnqualified.setInspectState(0); |
| | | return AjaxResult.success(qualityUnqualifiedService.save(qualityUnqualified)); |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除不合格管理") |
| | | @Log(title = "删除不合格管理", businessType = BusinessType.DELETE) |
| | | public AjaxResult delQualityUnqualified(@RequestBody List<Integer> ids) { |
| | | qualityUnqualifiedService.listByIds(ids).stream().forEach(qualityUnqualified -> { |
| | | if (qualityUnqualified.getInspectState() == 1) { |
| | |
| | | */ |
| | | @GetMapping("/{id}") |
| | | @ApiOperation("不合格管理详情") |
| | | @Log(title = "不合格管理详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult QualityUnqualifiedDetail(@PathVariable("id") Integer id) { |
| | | return AjaxResult.success(qualityUnqualifiedService.getUnqualified(id)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperation("不合格管理修改") |
| | | @Log(title = "不合格管理详情", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@RequestBody QualityUnqualified qualityUnqualified) { |
| | | return AjaxResult.success(qualityUnqualifiedService.updateById(qualityUnqualified)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("不合格管理分页查询") |
| | | @Log(title = "不合格管理分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult qualityUnqualifiedListPage(Page page, QualityUnqualified qualityUnqualified) { |
| | | return AjaxResult.success(qualityUnqualifiedService.qualityUnqualifiedListPage(page, qualityUnqualified)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/export") |
| | | @ApiOperation("不合格管理导出") |
| | | @Log(title = "不合格管理导出", businessType = BusinessType.EXPORT) |
| | | public void qualityUnqualifiedExport(HttpServletResponse response, QualityUnqualified qualityUnqualified) { |
| | | qualityUnqualifiedService.qualityUnqualifiedExport(response, qualityUnqualified); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/deal") |
| | | @ApiOperation("不合格管理处理") |
| | | @Log(title = "不合格管理处理", businessType = BusinessType.OTHER) |
| | | public AjaxResult deal(@RequestBody QualityUnqualified qualityUnqualified) { |
| | | return AjaxResult.success(qualityUnqualifiedService.deal(qualityUnqualified)); |
| | | } |
| | | |
| | | @GetMapping("/downloadReturnRecord") |
| | | @ApiOperation("下载不合格管理处理记录") |
| | | @Log(title = "下载不合格管理处理记录", businessType = BusinessType.OTHER) |
| | | public void downloadReturnRecord(@RequestParam("id") Long id,HttpServletResponse response) throws IOException { |
| | | qualityUnqualifiedService.downloadReturnRecord(id,response); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/saveOrUpdate") |
| | | @ApiOperation("开票台账新增") |
| | | @Log(title = "开票台账新增", businessType = BusinessType.UPDATE) |
| | | public AjaxResult invoiceLedgerSaveOrUpdate(@RequestBody InvoiceRegistrationProductDto productDto) { |
| | | invoiceLedgerService.invoiceLedgerSaveOrUpdate(productDto); |
| | | return AjaxResult.success(); |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("开票台账删除") |
| | | @Log(title = "开票台账删除", businessType = BusinessType.DELETE) |
| | | public AjaxResult invoiceLedgerDel(@RequestBody List<Integer> ids) { |
| | | invoiceLedgerService.invoiceLedgerDel(ids); |
| | | return AjaxResult.success(); |
| | |
| | | */ |
| | | @GetMapping("/page") |
| | | @ApiOperation("开票台账分页查询") |
| | | @Log(title = "开票台账分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceLedgerPage(Page page, InvoiceLedgerDto invoiceLedgerDto) { |
| | | return AjaxResult.success(invoiceLedgerService.invoiceLedgerPage(page, invoiceLedgerDto)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/fileList") |
| | | @ApiOperation("开票台账文件查询") |
| | | @Log(title = "开票台账文件查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceLedgerFileList(Integer invoiceLedgerId) { |
| | | return AjaxResult.success(invoiceLedgerService.invoiceLedgerFileList(invoiceLedgerId)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/uploadFile") |
| | | @ApiOperation("开票台账文件上传") |
| | | @Log(title = "开票台账文件上传", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceLedgerUploadFile(MultipartFile file) { |
| | | try { |
| | | return AjaxResult.success(invoiceLedgerService.invoiceLedgerUploadFile(file)); |
| | |
| | | */ |
| | | @PostMapping("/export") |
| | | @ApiOperation("开票台账导出") |
| | | @Log(title = "开票台账导出", businessType = BusinessType.EXPORT) |
| | | public void invoiceLedgerExport(HttpServletResponse response, InvoiceRegistrationProductDto invoiceRegistrationProductDto) { |
| | | invoiceLedgerService.invoiceLedgerExport(response, invoiceRegistrationProductDto); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/info") |
| | | @ApiOperation("开票台账详情") |
| | | @Log(title = "开票台账详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceLedgerInfo(Integer id) { |
| | | return AjaxResult.success(invoiceLedgerService.invoiceLedgerDetail(id)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/commitFile") |
| | | @ApiOperation("文件提交") |
| | | @Log(title = "文件提交", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceLedgerCommitFile(@RequestBody InvoiceLedgerDto invoiceLedgerDto) { |
| | | try { |
| | | invoiceLedgerService.invoiceLedgerCommitFile(invoiceLedgerDto); |
| | |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperation("开票台账查询") |
| | | @Log(title = "开票台账查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceLedgerList(InvoiceLedgerDto invoiceLedgerDto) { |
| | | return AjaxResult.success(invoiceLedgerService.invoiceLedgerList(invoiceLedgerDto)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/salesAccount") |
| | | @ApiOperation("客户销售记录") |
| | | @Log(title = "客户销售记录", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceLedgerSalesAccount(Page page, InvoiceLedgerDto invoiceLedgerDto) { |
| | | return AjaxResult.success(invoiceLedgerService.invoiceLedgerSalesAccount(page,invoiceLedgerDto)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/getInvoiceAmount") |
| | | @ApiOperation("本月开票金额") |
| | | @Log(title = "本月开票金额", businessType = BusinessType.OTHER) |
| | | public AjaxResult getInvoiceAmount() { |
| | | try { |
| | | BigDecimal amount = invoiceLedgerService.getInvoiceAmount(); |
| | |
| | | */ |
| | | @GetMapping("/registrationProductPage") |
| | | @ApiOperation("产品开票记录查询") |
| | | @Log(title = "产品开票记录查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult registrationProductPage(Page page, InvoiceRegistrationProductDto registrationProductDto) { |
| | | |
| | | return AjaxResult.success(invoiceLedgerService.registrationProductPage(page,registrationProductDto)); |
| | |
| | | */ |
| | | @GetMapping("/invoiceLedgerProductInfo") |
| | | @ApiOperation("产品开票详情") |
| | | @Log(title = "产品开票详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult invoiceLedgerProductDetail(Integer id) { |
| | | return AjaxResult.success(invoiceLedgerService.invoiceLedgerProductDetail(id)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("delInvoiceLedger/{invoiceRegistrationProductId}") |
| | | @ApiOperation("开票台账删除") |
| | | @Log(title = "开票台账删除", businessType = BusinessType.DELETE) |
| | | public AjaxResult delInvoiceLedger(@PathVariable Integer invoiceRegistrationProductId) { |
| | | try { |
| | | invoiceLedgerService.delInvoiceLedger(invoiceRegistrationProductId); |
| | |
| | | * @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") |
| | | @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); |
| | | } |
| | |
| | | |
| | | @ApiOperation("导出销售台账模板") |
| | | @PostMapping("/exportTemplate") |
| | | @Log(title = "导出销售台账模板", businessType = BusinessType.EXPORT) |
| | | public void exportTemplate(HttpServletResponse response) { |
| | | // 1. 模板文件在resources/static下的路径 |
| | | String templatePath = "static/销售台账导入模板.xlsx"; |
| | |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperation("查询销售台账列表") |
| | | @Log(title = "查询销售台账列表", businessType = BusinessType.OTHER) |
| | | public TableDataInfo list(Page page, SalesLedgerDto salesLedgerDto) { |
| | | startPage(); |
| | | List<SalesLedger> list = salesLedgerService.selectSalesLedgerList(salesLedgerDto); |
| | |
| | | */ |
| | | @GetMapping("/getSalesLedgerWithProducts") |
| | | @ApiOperation("查询销售台账和产品父子列表") |
| | | @Log(title = "查询销售台账和产品父子列表", businessType = BusinessType.OTHER) |
| | | public SalesLedgerDto getSalesLedgerWithProducts(SalesLedgerDto salesLedgerDto) { |
| | | return salesLedgerService.getSalesLedgerWithProducts(salesLedgerDto); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/listNoPage") |
| | | @ApiOperation("查询销售台账不分页") |
| | | @Log(title = "查询销售台账不分页", businessType = BusinessType.OTHER) |
| | | public AjaxResult listNoPage(SalesLedgerDto salesLedgerDto) { |
| | | List<SalesLedger> list = salesLedgerService.selectSalesLedgerList(salesLedgerDto); |
| | | return AjaxResult.success(list); |
| | |
| | | * 回款登记分页查询 |
| | | */ |
| | | @GetMapping("/listPageSalesLedger") |
| | | @Log(title = "回款登记分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult listPage(Page page, SalesLedgerProductDto salesLedgerProduct) { |
| | | IPage<SalesLedgerProductDto> list = salesLedgerProductService.listPage(page,salesLedgerProduct); |
| | | return AjaxResult.success(list); |
| | |
| | | * 付款登记分页查询 |
| | | */ |
| | | @GetMapping("/listPagePurchaseLedger") |
| | | @Log(title = "付款登记分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult listPagePurchaseLedger(Page page, SalesLedgerProductDto salesLedgerProduct) { |
| | | IPage<SalesLedgerProductDto> list = salesLedgerProductService.listPagePurchaseLedger(page,salesLedgerProduct); |
| | | return AjaxResult.success(list); |
| | |
| | | * 查询产品信息列表 |
| | | */ |
| | | @GetMapping("/list") |
| | | @Log(title = "查询产品信息列表", businessType = BusinessType.OTHER) |
| | | public AjaxResult list(SalesLedgerProduct salesLedgerProduct) { |
| | | List<SalesLedgerProduct> list = salesLedgerProductService.selectSalesLedgerProductList(salesLedgerProduct); |
| | | list.forEach(item -> { |
| | |
| | | * 获取产品信息详细信息 |
| | | */ |
| | | @GetMapping(value = "/{id}") |
| | | @Log(title = "查询产品信息详细信息", businessType = BusinessType.OTHER) |
| | | public AjaxResult getInfo(@PathVariable("id") Long id) |
| | | { |
| | | return success(salesLedgerProductService.selectSalesLedgerProductById(id)); |
| | |
| | | |
| | | //根据产品id获取bom判断库存是否充足 |
| | | @GetMapping("/judgmentInventory") |
| | | @Log(title = "判断库存是否充足", businessType = BusinessType.OTHER) |
| | | public R judgmentInventory(SalesLedgerProduct salesLedgerProduct) { |
| | | return salesLedgerProductService.judgmentInventory(salesLedgerProduct); |
| | | } |
| | |
| | | package com.ruoyi.staff.controller; |
| | | |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.staff.service.AnalyticsService; |
| | | import io.swagger.annotations.Api; |
| | |
| | | |
| | | @GetMapping("/reason") |
| | | @ApiOperation("员工离职原因分析") |
| | | @Log(title = "员工离职原因分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffLeaveReasonAnalytics() { |
| | | return AjaxResult.success(analyticsService.staffLeaveReasonAnalytics()); |
| | | } |
| | | |
| | | @GetMapping("/monthly_turnover_rate") |
| | | @ApiOperation("12个月员工离职率分析") |
| | | @Log(title = "12个月员工离职率分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult getMonthlyTurnoverRateFor12Months() { |
| | | return AjaxResult.success(analyticsService.getMonthlyTurnoverRateFor12Months()); |
| | | } |
| | | |
| | | @GetMapping("/total_statistic") |
| | | @ApiOperation("员工总统计分析") |
| | | @Log(title = "员工总统计分析", businessType = BusinessType.OTHER) |
| | | public AjaxResult getTotalStatistic() { |
| | | return AjaxResult.success(analyticsService.getTotalStatistic()); |
| | | } |
| | |
| | | |
| | | @GetMapping("/list") |
| | | @ApiOperation("查询银行管理表列表") |
| | | @Log(title = "银行管理表", businessType = BusinessType.OTHER) |
| | | public AjaxResult list() { |
| | | return AjaxResult.success(bankService.list()); |
| | | } |
| | |
| | | package com.ruoyi.staff.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.staff.pojo.HolidayApplication; |
| | | import com.ruoyi.staff.service.HolidayApplicationService; |
| | |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("请假申请分页查询") |
| | | @Log(title = "请假申请分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult listPage(Page page, HolidayApplication holidayApplication){ |
| | | return AjaxResult.success(holidayApplicationService.listPage(page, holidayApplication)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/add") |
| | | @ApiOperation("新增请假申请") |
| | | @Log(title = "新增请假申请", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody HolidayApplication holidayApplication){ |
| | | return AjaxResult.success(holidayApplicationService.save(holidayApplication)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperation("修改请假申请") |
| | | @Log(title = "修改请假申请", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@RequestBody HolidayApplication holidayApplication){ |
| | | return AjaxResult.success(holidayApplicationService.updateById(holidayApplication)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/delete/{id}") |
| | | @ApiOperation("删除请假申请") |
| | | @Log(title = "删除请假申请", businessType = BusinessType.DELETE) |
| | | public AjaxResult delete(@PathVariable("id") Long id){ |
| | | return AjaxResult.success(holidayApplicationService.removeById(id)); |
| | | } |
| | |
| | | package com.ruoyi.staff.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.framework.web.domain.R; |
| | | import com.ruoyi.staff.dto.PersonalAttendanceRecordsDto; |
| | |
| | | |
| | | @ApiOperation("新增/修改人员打卡规则配置") |
| | | @PostMapping("/add") |
| | | @Log(title = "新增/修改人员打卡规则配置", businessType = BusinessType.INSERT) |
| | | public R add(@RequestBody PersonalAttendanceLocationConfig personalAttendanceLocationConfig){ |
| | | return R.ok(personalAttendanceLocationConfigService.saveOrUpdate(personalAttendanceLocationConfig)); |
| | | } |
| | | |
| | | @ApiOperation("分页查询人员打卡规则配置") |
| | | @GetMapping("/listPage") |
| | | @Log(title = "分页查询人员打卡规则配置", businessType = BusinessType.OTHER) |
| | | public R listPage(Page page){ |
| | | return R.ok(personalAttendanceLocationConfigService.page(page)); |
| | | } |
| | |
| | | |
| | | @ApiOperation("删除人员打卡规则配置") |
| | | @DeleteMapping("/del") |
| | | @Log(title = "删除人员打卡规则配置", businessType = BusinessType.DELETE) |
| | | public R del(@RequestBody List<Integer> ids) { |
| | | return R.ok(personalAttendanceLocationConfigService.removeBatchByIds(ids)); |
| | | } |
| | |
| | | package com.ruoyi.staff.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.staff.dto.PersonalAttendanceRecordsDto; |
| | | import com.ruoyi.staff.pojo.PersonalAttendanceRecords; |
| | |
| | | |
| | | @ApiOperation("新增打卡签到") |
| | | @PostMapping("") |
| | | @Log(title = "新增打卡签到", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody PersonalAttendanceRecordsDto personalAttendanceRecordsDto){ |
| | | return AjaxResult.success(personalAttendanceRecordsService.add(personalAttendanceRecordsDto)); |
| | | } |
| | | |
| | | @ApiOperation("分页查询打卡签到") |
| | | @GetMapping("/listPage") |
| | | @Log(title = "分页查询打卡签到", businessType = BusinessType.OTHER) |
| | | public AjaxResult listPage(Page page, PersonalAttendanceRecordsDto personalAttendanceRecordsDto){ |
| | | return AjaxResult.success(personalAttendanceRecordsService.listPage(page, personalAttendanceRecordsDto)); |
| | | } |
| | | |
| | | @ApiOperation("获取当前人的考勤相关数据") |
| | | @GetMapping("/today") |
| | | @Log(title = "获取当前人的考勤相关数据", businessType = BusinessType.OTHER) |
| | | public AjaxResult todayInfo(PersonalAttendanceRecordsDto personalAttendanceRecordsDto){ |
| | | return AjaxResult.success(personalAttendanceRecordsService.todayInfo(personalAttendanceRecordsDto)); |
| | | } |
| | | |
| | | @ApiOperation("导出打卡签到") |
| | | @PostMapping("/export") |
| | | @Log(title = "导出打卡签到", businessType = BusinessType.EXPORT) |
| | | public void export(HttpServletResponse response, PersonalAttendanceRecordsDto personalAttendanceRecordsDto) { |
| | | personalAttendanceRecordsService.export(response, personalAttendanceRecordsDto); |
| | | } |
| | |
| | | import com.alibaba.excel.write.style.HorizontalCellStyleStrategy; |
| | | import com.alibaba.excel.write.style.column.LongestMatchColumnWidthStyleStrategy; |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.R; |
| | | import com.ruoyi.staff.dto.PerformanceShiftAddDto; |
| | | import com.ruoyi.staff.pojo.PersonalAttendanceLocationConfig; |
| | |
| | | |
| | | @ApiOperation("人员排班") |
| | | @PostMapping("/add") |
| | | @Log(title = "人员排班", businessType = BusinessType.INSERT) |
| | | public R add(@RequestBody PerformanceShiftAddDto performanceShiftAddDto){ |
| | | return R.ok(personalShiftService.performanceShiftAdd(performanceShiftAddDto)); |
| | | } |
| | | |
| | | @ApiOperation(value = "月份分页查询") |
| | | @GetMapping("page") |
| | | @Log(title = "月份分页查询", businessType = BusinessType.OTHER) |
| | | public R performanceShiftPage(Integer size, Integer current, String time, String userName, Integer sysDeptId) { |
| | | return R.ok(personalShiftService.performanceShiftPage(new Page<>(current, size), time, userName, sysDeptId)); |
| | | } |
| | | |
| | | @ApiOperation(value = "年份分页查询") |
| | | @GetMapping("pageYear") |
| | | @Log(title = "年份分页查询", businessType = BusinessType.OTHER) |
| | | public R performanceShiftPageYear(Integer size, Integer current, String time, String userName, Integer sysDeptId) { |
| | | return R.ok(personalShiftService.performanceShiftPageYear(new Page<>(current, size), time, userName, sysDeptId)); |
| | | } |
| | | |
| | | @ApiOperation(value = "班次状态修改") |
| | | @PostMapping("update") |
| | | @Log(title = "班次状态修改", businessType = BusinessType.UPDATE) |
| | | public R performanceShiftUpdate(@RequestBody PersonalShift personalShift) { |
| | | personalShiftService.performanceShiftUpdate(personalShift); |
| | | return R.ok(); |
| | |
| | | |
| | | @ApiOperation(value = "导出") |
| | | @GetMapping("export") |
| | | @Log(title = "导出", businessType = BusinessType.EXPORT) |
| | | public void exportToExcel(@NotNull(message = "时间不能为空!") String time, String userName, Integer sysDeptId, Boolean isMonth, HttpServletResponse response) throws Exception { |
| | | Map<Object, Object> data; |
| | | response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); |
| | |
| | | |
| | | @GetMapping("/listPage") |
| | | @ApiOperation(value = "分页查询") |
| | | @Log(title = "分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult listPage(Page page, SchemeApplicableStaff schemeApplicableStaff) { |
| | | return schemeApplicableStaffService.listPage(page,schemeApplicableStaff); |
| | | } |
| | |
| | | package com.ruoyi.staff.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.staff.pojo.StaffContract; |
| | | import com.ruoyi.staff.service.StaffContractService; |
| | |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("员工合同分页查询") |
| | | @Log(title = "员工合同分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffContractListPage(Page page, StaffContract staffContract) { |
| | | return AjaxResult.success(staffContractService.staffContractListPage(page, staffContract)); |
| | | } |
| | |
| | | package com.ruoyi.staff.controller; |
| | | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.ruoyi.framework.aspectj.lang.annotation.Log; |
| | | import com.ruoyi.framework.aspectj.lang.enums.BusinessType; |
| | | import com.ruoyi.framework.web.domain.AjaxResult; |
| | | import com.ruoyi.staff.dto.StaffLeaveDto; |
| | | import com.ruoyi.staff.service.StaffLeaveService; |
| | |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("新增离职分页查询") |
| | | @Log(title = "新增离职分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffLeaveListPage(Page page, StaffLeaveDto staffLeaveDto) { |
| | | return AjaxResult.success(staffLeaveService.staffLeaveListPage(page, staffLeaveDto)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("") |
| | | @ApiOperation("新增离职") |
| | | @Log(title = "新增离职", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody StaffLeaveDto staffLeaveDto) { |
| | | return AjaxResult.success(staffLeaveService.add(staffLeaveDto)); |
| | | } |
| | |
| | | */ |
| | | @PutMapping("/{id}") |
| | | @ApiOperation("更新离职信息") |
| | | @Log(title = "更新离职信息", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@PathVariable("id") Long id, @RequestBody StaffLeaveDto staffLeaveDto) { |
| | | return AjaxResult.success(staffLeaveService.update(id, staffLeaveDto)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除入职") |
| | | @Log(title = "删除入职", businessType = BusinessType.DELETE) |
| | | public AjaxResult del(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | */ |
| | | @PostMapping("/export") |
| | | @ApiOperation("离职导出") |
| | | @Log(title = "离职导出", businessType = BusinessType.EXPORT) |
| | | public void export(HttpServletResponse response, StaffLeaveDto staffLeaveDto) { |
| | | staffLeaveService.export(response, staffLeaveDto); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("在职员工台账分页查询") |
| | | @Log(title = "在职员工台账分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffOnJobListPage(Page page, StaffOnJob staffOnJob) { |
| | | return AjaxResult.success(staffOnJobService.staffOnJobListPage(page, staffOnJob)); |
| | | } |
| | |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperation("在职员工下拉(新增离职用)") |
| | | @Log(title = "在职员工下拉(新增离职用)", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffOnJobList(StaffOnJob staffOnJob) { |
| | | return AjaxResult.success(staffOnJobService.staffOnJobList(staffOnJob)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("") |
| | | @ApiOperation("新增入职") |
| | | @Log(title = "新增入职", businessType = BusinessType.INSERT) |
| | | public AjaxResult add(@RequestBody StaffOnJobDto staffOnJob) { |
| | | return AjaxResult.success(staffOnJobService.add(staffOnJob)); |
| | | } |
| | |
| | | */ |
| | | @PutMapping("/{id}") |
| | | @ApiOperation("更新入职信息") |
| | | @Log(title = "更新入职信息", businessType = BusinessType.UPDATE) |
| | | public AjaxResult update(@PathVariable("id") Long id, @RequestBody StaffOnJobDto staffOnJobDto) { |
| | | return AjaxResult.success(staffOnJobService.update(id, staffOnJobDto)); |
| | | } |
| | |
| | | */ |
| | | @DeleteMapping("/del") |
| | | @ApiOperation("删除入职") |
| | | @Log(title = "删除入职", businessType = BusinessType.DELETE) |
| | | public AjaxResult delStaffOnJobs(@RequestBody List<Integer> ids) { |
| | | if(CollectionUtils.isEmpty(ids)){ |
| | | return AjaxResult.error("请选择至少一条数据"); |
| | |
| | | */ |
| | | @GetMapping("/{id}") |
| | | @ApiOperation("在职员工详情") |
| | | @Log(title = "在职员工详情", businessType = BusinessType.OTHER) |
| | | public AjaxResult staffOnJobDetail(@PathVariable("id") Long id) { |
| | | return AjaxResult.success(staffOnJobService.staffOnJobDetail(id)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/renewContract/{id}") |
| | | @ApiOperation("续签合同") |
| | | @Log(title = "续签合同", businessType = BusinessType.UPDATE) |
| | | public AjaxResult renewContract(@PathVariable("id") Long id, @RequestBody StaffContract staffContract) { |
| | | return AjaxResult.success(staffOnJobService.renewContract(id, staffContract)); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/export") |
| | | @ApiOperation("在职员工导出") |
| | | @Log(title = "在职员工导出", businessType = BusinessType.EXPORT) |
| | | public void staffOnJobExport(HttpServletResponse response,StaffOnJob staffOnJob) { |
| | | staffOnJobService.staffOnJobExport(response, staffOnJob); |
| | | } |
| | |
| | | */ |
| | | @PostMapping("/exportCopy") |
| | | @ApiOperation("word模板合同在职员工导出") |
| | | @Log(title = "word模板合同在职员工导出", businessType = BusinessType.EXPORT) |
| | | public AjaxResult exportCopy(HttpServletResponse response,@RequestBody StaffOnJob staffOnJob) throws Exception{ |
| | | return AjaxResult.success(staffOnJobService.exportCopy(response, staffOnJob)); |
| | | } |
| | |
| | | |
| | | @GetMapping("/listPage") |
| | | @ApiOperation("员工工资主表分页查询") |
| | | @Log(title = "员工工资主表分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult listPage(Page page, StaffSalaryMain staffSalaryMain) { |
| | | return staffSalaryMainService.listPage(page, staffSalaryMain); |
| | | } |
| | | |
| | | @ApiOperation("通过部门ids获取用户信息计算每个员工的工资") |
| | | @PostMapping("/calculateSalary") |
| | | @Log(title = "通过部门ids获取用户信息计算每个员工的工资", businessType = BusinessType.OTHER) |
| | | public AjaxResult calculateSalary(@RequestBody CalculateSalaryDto calculateSalaryDto) { |
| | | return staffSalaryMainService.calculateSalary(calculateSalaryDto); |
| | | } |
| | |
| | | |
| | | @PostMapping("/listPage") |
| | | @ApiOperation("排班分页查询") |
| | | @Log(title = "排班分页查询", businessType = BusinessType.OTHER) |
| | | public AjaxResult listPage(@RequestBody SearchSchedulingVo vo){ |
| | | return AjaxResult.success(staffSchedulingService.listPage(vo)); |
| | | } |
| | | |
| | | @PostMapping("/save") |
| | | @ApiOperation("保存排班") |
| | | @Log(title = "保存排班", businessType = BusinessType.UPDATE) |
| | | public AjaxResult save(@RequestBody @Validated SaveStaffSchedulingDto saveStaffSchedulingDto){ |
| | | staffSchedulingService.saveStaffScheduling(saveStaffSchedulingDto); |
| | | return AjaxResult.success(); |
| | |
| | | |
| | | @DeleteMapping("/delByIds") |
| | | @ApiOperation("批量删除排班") |
| | | @Log(title = "批量删除排班", businessType = BusinessType.DELETE) |
| | | public AjaxResult delByIds(@RequestBody List<Integer> ids){ |
| | | staffSchedulingService.removeByIds(ids); |
| | | return AjaxResult.success(); |
| | |
| | | |
| | | @DeleteMapping("/del/{id}") |
| | | @ApiOperation("删除排班") |
| | | @Log(title = "删除排班", businessType = BusinessType.DELETE) |
| | | public AjaxResult del(@PathVariable("id") Integer id){ |
| | | staffSchedulingService.removeById(id); |
| | | return AjaxResult.success(); |
| | |
| | | */ |
| | | @GetMapping("/getCurrentUserLatestScheduling") |
| | | @ApiOperation("获取当前用户最新排班记录") |
| | | @Log(title = "获取当前用户最新排班记录", businessType = BusinessType.OTHER) |
| | | public AjaxResult getCurrentUserLatestScheduling(){ |
| | | return AjaxResult.success(staffSchedulingService.getCurrentUserLatestScheduling()); |
| | | } |