| | |
| | | |
| | | import com.fzzy.igds.ReportInDetailPR; |
| | | import com.fzzy.igds.ReportOutDetailPR; |
| | | import com.fzzy.igds.SuperInventoryReportPR; |
| | | import com.fzzy.igds.data.InoutParam; |
| | | import com.fzzy.igds.data.SuperInventoryReportData; |
| | | import com.fzzy.igds.data.SuperInventoryReportParam; |
| | | import com.fzzy.igds.domain.Company; |
| | | import com.fzzy.igds.domain.Depot; |
| | | import com.fzzy.igds.domain.Dept; |
| | | import com.fzzy.igds.domain.InoutRecord; |
| | | import com.fzzy.igds.service.InoutRecordService; |
| | | import com.fzzy.igds.service.SysDeptService; |
| | | import com.fzzy.igds.service.*; |
| | | import com.fzzy.igds.utils.ContextUtil; |
| | | import com.ruoyi.common.core.domain.AjaxResult; |
| | | import com.ruoyi.common.core.domain.entity.SysDept; |
| | |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.ArrayList; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | |
| | | /** |
| | |
| | | @Resource |
| | | private SysDeptService sysDeptService; |
| | | |
| | | |
| | | @Resource |
| | | private CoreDeptService coreDeptService; |
| | | @Resource |
| | | private DepotService depotService; |
| | | |
| | | @Resource |
| | | private CoreCompanyService coreCompanyService; |
| | | |
| | | |
| | | @Autowired |
| | | private ReportInDetailPR reportInDetailPR; |
| | | |
| | | @Autowired |
| | | private ReportOutDetailPR reportOutDetailPR; |
| | | @Autowired |
| | | private SuperInventoryReportPR superInventoryReportPR; |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | |
| | | return util.exportExcel(list, sheetName, deptName); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 库存报表导出 |
| | | * @return |
| | | */ |
| | | @RequestMapping("/superInventoryReport-excel") |
| | | @ResponseBody |
| | | public AjaxResult superInventoryReport(SuperInventoryReportParam param) { |
| | | //设置标题 |
| | | String sheetName = "库存报表数据"; |
| | | //查询数据 |
| | | List<SuperInventoryReportData> list = superInventoryReportPR.getReportData(param); |
| | | //获取分库编码对应的分库名称 |
| | | String deptName = ""; |
| | | SysDept subDept = sysDeptService.getCacheDept(null, ContextUtil.subDeptId(null)); |
| | | if (null != subDept) { |
| | | deptName = subDept.getDeptName(); |
| | | } |
| | | |
| | | //导出 |
| | | ExcelUtil<SuperInventoryReportData> util = new ExcelUtil<SuperInventoryReportData>(SuperInventoryReportData.class); |
| | | return util.exportExcel(list, sheetName, deptName); |
| | | } |
| | | |
| | | } |