| | |
| | | @RequiresPermissions("partPlan:list") |
| | | @GetMapping("/list") |
| | | public TableDataInfo list(ApsPartPlan apsPartPlan) { |
| | | startPage(); |
| | | // startPage(); |
| | | List<ApsPartPlan> list = apsPartPlanService.selectApsPartPlanList(apsPartPlan); |
| | | return getDataTable(list); |
| | | } |
| | |
| | | public AjaxResult importData(MultipartFile file) throws Exception { |
| | | ExcelUtil<ApsPartPlanTemp> util = new ExcelUtil<ApsPartPlanTemp>(ApsPartPlanTemp.class); |
| | | List<ApsPartPlanTemp> apsPartPlans = util.importExcel(file.getInputStream()); |
| | | |
| | | //判断导入数据是否为空 |
| | | if (apsPartPlans.size() > 0) { |
| | | String batchNum= IdUtils.fastUUID(); |
| | | List<SysDictData> list = DictUtils.getDictCache("aps_is_suspended"); |
| | |
| | | break; |
| | | } |
| | | } |
| | | //插入版本号 |
| | | apsPartPlans.get(i).setBatchNumber(batchNum); |
| | | //插入临时表 |
| | | apsPartPlanTempService.insertApsPartPlanTemp(apsPartPlans.get(i)); |
| | | } |
| | | return AjaxResult.success(batchNum); |
| | |
| | | return AjaxResult.error("模板内容为空"); |
| | | } |
| | | } |
| | | /*** |
| | | * @Description: 确认上传 |
| | | * @Param: [apsPartPlan] |
| | | * @return: com.aps.common.core.web.domain.AjaxResult |
| | | * @Author: wwj |
| | | * @Date: 2025/4/9 |
| | | */ |
| | | @GetMapping("/confirmPart") |
| | | public AjaxResult confirmPart(ApsPartPlanTemp apsPartPlanTemp) { |
| | | return toAjax(apsPartPlanService.confirmPart(apsPartPlanTemp)); |
| | | } |
| | | |
| | | |
| | | |
| | | } |