| | |
| | | |
| | | import com.baomidou.dynamic.datasource.annotation.DS; |
| | | |
| | | import com.example.erp.dto.pp.DamageReportDTO; |
| | | import com.example.erp.dto.pp.ScheduleProductionScheduleDTO; |
| | | import com.example.erp.dto.pp.TeamOutputDTO; |
| | | import com.example.erp.dto.pp.*; |
| | | import com.example.erp.entity.pp.DamageDetails; |
| | | import com.example.erp.entity.pp.Report; |
| | | import com.example.erp.mapper.pp.ProductionSchedulingMapper; |
| | |
| | | return map; |
| | | } |
| | | |
| | | public Map<String, Object> crossProcessBreakingSv(Integer pageNum, Integer pageSize, List<String> selectDate, DamageDetails damageDetails) { |
| | | public Map<String, Object> crossProcessBreakingSv(Integer pageNum, Integer pageSize, List<String> selectDate, CrossProcessBreakingDTO crossProcessBreakingDTO) { |
| | | Integer offset = (pageNum - 1) * pageSize; |
| | | String endDate = LocalDate.now().toString(); |
| | | String startDate = LocalDate.now().minusDays(15).toString(); |
| | |
| | | } |
| | | } |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("data", reportMapper.getProcessBreaking(offset, pageSize, startDate, endDate, damageDetails)); |
| | | map.put("total", reportMapper.getProcessBreakingTotal(offset, pageSize, startDate, endDate, damageDetails)); |
| | | map.put("data", reportMapper.getProcessBreaking(offset, pageSize, startDate, endDate, crossProcessBreakingDTO)); |
| | | map.put("total", reportMapper.getProcessBreakingTotal(offset, pageSize, startDate, endDate, crossProcessBreakingDTO)); |
| | | List<String> list = new ArrayList<>(); |
| | | list.add(startDate); |
| | | list.add(endDate); |
| | | map.put("selectDate", list); |
| | | // map.put("total",orderMapper.getPageTotal(offset, pageSize, startDate, endDate, orderDetail)); |
| | | return map; |
| | | } |
| | | |
| | | public Map<String, Object> workInProgressSv(Date selectTime1, Date selectTime2, String orderId, String inputProject, String selectProcesses, String optionVal, Report report) { |
| | | |
| | | public Map<String, Object> workInProgressSv(Integer pageNum, Integer pageSize, String orderId, String inputProject, String selectProcesses, String optionVal, WorkInProgressDTO workInProgressDTO) { |
| | | Integer offset = (pageNum - 1) * pageSize; |
| | | if ("null".equals(orderId)) { |
| | | orderId = ""; |
| | | } |
| | |
| | | Map<String, Object> map = new HashMap<>(); |
| | | if (optionVal.equals("1")){ |
| | | /* 根据销售单号汇总*/ |
| | | map.put("data", reportMapper.workInProgressOrderMp(selectTime1, selectTime2, orderId, inputProject, selectProcesses, report)); |
| | | map.put("data", reportMapper.workInProgressOrderMp(offset, pageSize, orderId, inputProject, selectProcesses, workInProgressDTO)); |
| | | map.put("total", reportMapper.workInProgressOrderTotal(offset, pageSize, orderId, inputProject, selectProcesses, workInProgressDTO)); |
| | | |
| | | }else if(optionVal.equals("2")){ |
| | | /* 根流程卡号汇总*/ |
| | | map.put("data", reportMapper.workInProgressProcessMp(selectTime1, selectTime2, orderId, inputProject, selectProcesses, report)); |
| | | map.put("data", reportMapper.workInProgressProcessMp(offset, pageSize, orderId, inputProject, selectProcesses, workInProgressDTO)); |
| | | map.put("total", reportMapper.workInProgressProcessTotal(offset, pageSize, orderId, inputProject, selectProcesses, workInProgressDTO)); |
| | | } else if (optionVal.equals("3")) { |
| | | |
| | | } else { |
| | | //没有选择分组 |
| | | map.put("data", reportMapper.workInProgressMp(offset, pageSize, orderId, inputProject, selectProcesses, workInProgressDTO)); |
| | | map.put("total", reportMapper.workInProgressTotal(offset, pageSize, orderId, inputProject, selectProcesses, workInProgressDTO)); |
| | | |
| | | map.put("data", reportMapper.workInProgressMp(selectTime1, selectTime2, orderId, inputProject, selectProcesses, report)); |
| | | } |
| | | map.put("process", productionSchedulingMapper.selectProcess()); |
| | | return map; |
| | |
| | | } |
| | | |
| | | public List exportDamageReportSv(List<LocalDate> dates) { |
| | | |
| | | return reportMapper.exportDamageReportMp(dates); |
| | | } |
| | | |
| | |
| | | } |
| | | |
| | | public List exportWorkInProgressSv(Map<String, Object> dates) { |
| | | List<LocalDate> date= (List<LocalDate>) dates.get("date"); |
| | | String process= (String) dates.get("processes"); |
| | | String inputVal= (String) dates.get("inputVal"); |
| | | String project= (String) dates.get("project"); |
| | |
| | | if ("null".equals(project)) { |
| | | project = ""; |
| | | } |
| | | return reportMapper.exportWorkInProgressMp(date,process,inputVal,project); |
| | | return reportMapper.exportWorkInProgressMp(process,inputVal,project); |
| | | } |
| | | |
| | | public List exportTaskCompletionStatusSv(Map<String, Object> dates) { |
| | |
| | | } |
| | | |
| | | public Map<String, Object> teamOutputSv(Integer pageNum, Integer pageSize, Date selectTime1, Date selectTime2, String selectProcesses, TeamOutputDTO teamOutputDTO) { |
| | | if (selectProcesses.equals("全部")){ |
| | | selectProcesses=""; |
| | | } |
| | | Integer offset = (pageNum - 1) * pageSize; |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("data", reportMapper.teamOutputMp(offset, pageSize, selectTime1, selectTime2,selectProcesses, teamOutputDTO)); |
| | |
| | | } |
| | | |
| | | public List exportScheduleReportSv(Map<String, Object> dates) { |
| | | List<LocalDate> date= (List<LocalDate>) dates.get("date"); |
| | | List<LocalDate> date= (List<LocalDate>) dates.get("date1"); |
| | | String process= (String) dates.get("processes"); |
| | | return reportMapper.exportScheduleReportMp(date,process); |
| | | } |
| | | |
| | | public List exportTeamOutputSv(Map<String, Object> dates) { |
| | | List<LocalDate> date= (List<LocalDate>) dates.get("date"); |
| | | String process= (String) dates.get("processes"); |
| | | if (process.equals("全部")){ |
| | | process=""; |
| | | } |
| | | return reportMapper.exportTeamOutputMp(date,process); |
| | | } |
| | | } |