xml导入

This commit is contained in:
lym
2024-09-10 15:47:46 +08:00
parent a38c2ece52
commit b7acf4d436
41 changed files with 586 additions and 267 deletions
@@ -7,5 +7,5 @@ package com.cf.imes.module.manage.enums;
*/
public interface DictTypeConstants {
String PLATE_TEXTURE = "plate_texture_type";// 板件纹
String PLATE_TEXTURE = "plate_texture_type";// 板件纹
}
@@ -117,10 +117,10 @@ public class PlateController {
public void importTemplate(HttpServletResponse response) throws IOException {
// 手动创建导出 demo
List<PlateImportExcelVO> list = Arrays.asList(
PlateImportExcelVO.builder().goodsId("SP1123456").goodsName("尼龙板").material("PVC").width(String.valueOf(1200.000)).height(String.valueOf(2400.000))
.thickness(String.valueOf(18)).brand("黑天鹅").spec("1200*2400*18").remark("板材样本").color("黑色").texture("").build(),
PlateImportExcelVO.builder().goodsId("SP1123457").goodsName("电木").material("塑料").width(String.valueOf(1800.000)).height(String.valueOf(2800.000))
.thickness(String.valueOf(24)).brand("东粤橡塑厂").spec("1800*2800*24").remark("测试").color("黑色").texture("").build()
PlateImportExcelVO.builder().goodsId("SP1123456").goodsName("5mm-多层板-高级灰").material("多层板").width(String.valueOf(1220)).height(String.valueOf(2440))
.thickness(String.valueOf(5)).brand("AAA").spec("2440*1220*5").remark("板材样本").color("高级灰").texture("").build(),
PlateImportExcelVO.builder().goodsId("SP1123457").goodsName("白玉木兰-欧松").material("欧松板").width(String.valueOf(1220)).height(String.valueOf(2750))
.thickness(String.valueOf(18)).brand("鸿达树").spec("2750*1220*18").remark("测试").color("白玉木兰").texture("").build()
);
// 输出
ExcelUtils.write(response, "板材导入模板.xlsx", "板材列表", PlateImportExcelVO.class, list);
@@ -66,7 +66,7 @@ public class RemainPlateController {
@Operation(summary = "余料板批量核销")
@PreAuthorize("@ss.hasPermission('placeorder:remain')")
public CommonResult<Boolean> updateRemainPlate(@RequestBody RemainPlateUptReqVO updateReqVO) {
remainPlateService.updateRemainPlateStatus(updateReqVO.getId(),
remainPlateService.updateRemainPlateStatus(updateReqVO.getIds(),
updateReqVO.getStatus(),
updateReqVO.getUseType(),
updateReqVO.getPlanId());
@@ -77,7 +77,7 @@ public class RemainPlateController {
@Operation(summary = "余料板批量释放")
@PreAuthorize("@ss.hasPermission('placeorder:remain')")
public CommonResult<Boolean> revertRemainPlate(@RequestBody RemainPlateUptReqVO updateReqVO) {
remainPlateService.revertRemainPlateStatus(updateReqVO.getId(),updateReqVO.getStatus());
remainPlateService.revertRemainPlateStatus(updateReqVO.getIds(),updateReqVO.getStatus());
return success(true);
}
@@ -10,7 +10,7 @@ import java.util.Set;
public class RemainPlateUptReqVO {
@Schema(description = "余料板集", example = "16470")
private Set<Long> id;
private Set<Long> ids;
@Schema(description = "余料板状态,0未使用,1使用中", example = "1")
private Integer status;