From 080b4a3b7f05b39d5453ae73fed5368ced4003c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8C=AB=E7=8C=ABguowen?= <9290821+guowen-the-cat@user.noreply.gitee.com> Date: Wed, 17 Sep 2025 14:17:06 +0800 Subject: [PATCH] =?UTF-8?q?=E7=89=A9=E6=96=99=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/BasProductController.java | 26 +- .../bas/BasProduct/domain/BasProduct.java | 716 +++++++++++++++++- .../BasProduct/mapper/BasProductMapper.java | 31 +- .../service/IBasProductService.java | 54 +- .../service/impl/BasProductServiceImpl.java | 74 +- .../impl/ReceiveStockinServiceImpl.java | 4 +- .../resources/mapper/bas/BasProductMapper.xml | 267 +++++-- ruoyi-ui/src/api/bas/BasProduct.js | 10 +- ruoyi-ui/src/views/bas/basProduct/index.vue | 698 ++++++++++++++--- 9 files changed, 1589 insertions(+), 291 deletions(-) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/controller/BasProductController.java b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/controller/BasProductController.java index 172d059..21e6dce 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/controller/BasProductController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/controller/BasProductController.java @@ -22,10 +22,10 @@ import com.ruoyi.common.utils.poi.ExcelUtil; import com.ruoyi.common.core.page.TableDataInfo; /** - * 物料信息Controller + * 物料管理Controller * * @author gw - * @date 2025-09-11 + * @date 2025-09-17 */ @RestController @RequestMapping("/bas/BasProduct") @@ -35,7 +35,7 @@ public class BasProductController extends BaseController private IBasProductService basProductService; /** - * 查询物料信息列表 + * 查询物料管理列表 */ @PreAuthorize("@ss.hasPermi('bas:BasProduct:list')") @GetMapping("/list") @@ -47,20 +47,20 @@ public class BasProductController extends BaseController } /** - * 导出物料信息列表 + * 导出物料管理列表 */ @PreAuthorize("@ss.hasPermi('bas:BasProduct:export')") - @Log(title = "物料信息", businessType = BusinessType.EXPORT) + @Log(title = "物料管理", businessType = BusinessType.EXPORT) @PostMapping("/export") public void export(HttpServletResponse response, BasProduct basProduct) { List list = basProductService.selectBasProductList(basProduct); ExcelUtil util = new ExcelUtil(BasProduct.class); - util.exportExcel(response, list, "物料信息数据"); + util.exportExcel(response, list, "物料管理数据"); } /** - * 获取物料信息详细信息 + * 获取物料管理详细信息 */ @PreAuthorize("@ss.hasPermi('bas:BasProduct:query')") @GetMapping(value = "/{productGuid}") @@ -70,10 +70,10 @@ public class BasProductController extends BaseController } /** - * 新增物料信息 + * 新增物料管理 */ @PreAuthorize("@ss.hasPermi('bas:BasProduct:add')") - @Log(title = "物料信息", businessType = BusinessType.INSERT) + @Log(title = "物料管理", businessType = BusinessType.INSERT) @PostMapping public AjaxResult add(@RequestBody BasProduct basProduct) { @@ -81,10 +81,10 @@ public class BasProductController extends BaseController } /** - * 修改物料信息 + * 修改物料管理 */ @PreAuthorize("@ss.hasPermi('bas:BasProduct:edit')") - @Log(title = "物料信息", businessType = BusinessType.UPDATE) + @Log(title = "物料管理", businessType = BusinessType.UPDATE) @PutMapping public AjaxResult edit(@RequestBody BasProduct basProduct) { @@ -92,10 +92,10 @@ public class BasProductController extends BaseController } /** - * 删除物料信息 + * 删除物料管理 */ @PreAuthorize("@ss.hasPermi('bas:BasProduct:remove')") - @Log(title = "物料信息", businessType = BusinessType.DELETE) + @Log(title = "物料管理", businessType = BusinessType.DELETE) @DeleteMapping("/{productGuids}") public AjaxResult remove(@PathVariable String[] productGuids) { diff --git a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/domain/BasProduct.java b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/domain/BasProduct.java index 8123942..f81d05f 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/domain/BasProduct.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/domain/BasProduct.java @@ -1,22 +1,16 @@ package com.ruoyi.bas.BasProduct.domain; -import lombok.AllArgsConstructor; -import lombok.Data; -import lombok.NoArgsConstructor; import org.apache.commons.lang3.builder.ToStringBuilder; import org.apache.commons.lang3.builder.ToStringStyle; import com.ruoyi.common.annotation.Excel; import com.ruoyi.common.core.domain.BaseEntity; /** - * 物料信息对象 bas_product - * + * 物料管理对象 bas_product + * * @author gw - * @date 2025-09-11 + * @date 2025-09-17 */ -@Data -@AllArgsConstructor -@NoArgsConstructor public class BasProduct extends BaseEntity { private static final long serialVersionUID = 1L; @@ -28,34 +22,42 @@ public class BasProduct extends BaseEntity @Excel(name = "物料编码") private String productId; - /** 物料名称 */ - @Excel(name = "物料名称") - private String productName; + /** 产品分类 */ + @Excel(name = "产品分类") + private String parentId; - /** 序列号 */ - @Excel(name = "序列号") - private String spare4; + /** 品号描述 */ + @Excel(name = "品号描述") + private String price; - /** 相位 */ - @Excel(name = "相位") - private String spare7; + /** 英文描述 */ + @Excel(name = "英文描述") + private String cargoNo; + + /** 图号 */ + @Excel(name = "图号") + private String unit; + + /** 规格 */ + @Excel(name = "规格") + private String spec; /** 型号 */ @Excel(name = "型号") private String spare1; - /** 净重 */ - @Excel(name = "净重") + /** 单件净重 */ + @Excel(name = "单件净重") private String spare2; - /** 毛重 */ - @Excel(name = "毛重") - private String spare8; - /** 颜色 */ @Excel(name = "颜色") private String spare3; + /** 序列号 */ + @Excel(name = "序列号") + private String spare4; + /** 电压 */ @Excel(name = "电压") private String spare5; @@ -64,27 +66,663 @@ public class BasProduct extends BaseEntity @Excel(name = "功率") private String spare6; - /** $column.columnComment */ - private String parentId; + /** 物料名称 */ + @Excel(name = "物料名称") + private String productName; - /** $column.columnComment */ - private String price; + /** 相位 */ + @Excel(name = "相位") + private String spare7; - /** $column.columnComment */ - private String cargoNo; + /** 毛重 */ + @Excel(name = "毛重") + private String spare8; - /** $column.columnComment */ - private String unit; - - /** $column.columnComment */ - private String spec; - - /** $column.columnComment */ + /** NC号 */ + @Excel(name = "NC号") private String spare9; - private String quantity; + /** 电源线 */ + @Excel(name = "电源线") + private String spare10; - private String lotNo; + /** 插头 */ + @Excel(name = "插头") + private String spare11; + /** 接嘴 */ + @Excel(name = "接嘴") + private String spare12; + /** 快捷码 */ + @Excel(name = "快捷码") + private String spare13; + + /** 库存单位编号 */ + @Excel(name = "库存单位编号") + private String spare14; + + /** 库存单位名称 */ + @Excel(name = "库存单位名称") + private String spare15; + + /** 品号群组 */ + @Excel(name = "品号群组") + private String spare16; + + /** 归类品 */ + @Excel(name = "归类品") + private String spare17; + + /** 计量体系 */ + @Excel(name = "计量体系") + private String spare18; + + /** 群组名称 */ + @Excel(name = "群组名称") + private String spare19; + + /** 批号管理 */ + @Excel(name = "批号管理") + private String spare20; + + /** 状态 */ + @Excel(name = "状态") + private String spare21; + + /** 产品大类 */ + @Excel(name = "产品大类") + private String spare22; + + /** 产品二类 */ + @Excel(name = "产品二类") + private String spare23; + + /** 产品线/产品系列(组码) */ + @Excel(name = "产品线/产品系列", readConverterExp = "组=码") + private String spare24; + + /** BOM状态(组码) */ + @Excel(name = "BOM状态", readConverterExp = "组=码") + private String spare25; + + /** 产品定位(组码) */ + @Excel(name = "产品定位", readConverterExp = "组=码") + private String spare26; + + /** 电脑板型号(组码) */ + @Excel(name = "电脑板型号", readConverterExp = "组=码") + private String spare27; + + /** 非标要求 */ + @Excel(name = "非标要求") + private String spare28; + + /** 品牌(组码) */ + @Excel(name = "品牌", readConverterExp = "组=码") + private String spare29; + + /** 非标颜色 */ + @Excel(name = "非标颜色") + private String spare30; + + /** 主颜色 */ + @Excel(name = "主颜色") + private String spare31; + + /** 辅助颜色 */ + @Excel(name = "辅助颜色") + private String spare32; + + /** 是否标准款(组码) */ + @Excel(name = "是否标准款", readConverterExp = "组=码") + private String spare33; + + /** 包装方式 */ + @Excel(name = "包装方式") + private String spare34; + + /** 主要包装方式 */ + @Excel(name = "主要包装方式") + private String spare35; + + /** 长 */ + @Excel(name = "长") + private String spare36; + + /** 宽 */ + @Excel(name = "宽") + private String spare37; + + /** 高 */ + @Excel(name = "高") + private String spare38; + + /** 包装材积 */ + @Excel(name = "包装材积") + private String spare39; + + public void setProductGuid(String productGuid) + { + this.productGuid = productGuid; + } + + public String getProductGuid() + { + return productGuid; + } + + public void setProductId(String productId) + { + this.productId = productId; + } + + public String getProductId() + { + return productId; + } + + public void setParentId(String parentId) + { + this.parentId = parentId; + } + + public String getParentId() + { + return parentId; + } + + public void setPrice(String price) + { + this.price = price; + } + + public String getPrice() + { + return price; + } + + public void setCargoNo(String cargoNo) + { + this.cargoNo = cargoNo; + } + + public String getCargoNo() + { + return cargoNo; + } + + public void setUnit(String unit) + { + this.unit = unit; + } + + public String getUnit() + { + return unit; + } + + public void setSpec(String spec) + { + this.spec = spec; + } + + public String getSpec() + { + return spec; + } + + public void setSpare1(String spare1) + { + this.spare1 = spare1; + } + + public String getSpare1() + { + return spare1; + } + + public void setSpare2(String spare2) + { + this.spare2 = spare2; + } + + public String getSpare2() + { + return spare2; + } + + public void setSpare3(String spare3) + { + this.spare3 = spare3; + } + + public String getSpare3() + { + return spare3; + } + + public void setSpare4(String spare4) + { + this.spare4 = spare4; + } + + public String getSpare4() + { + return spare4; + } + + public void setSpare5(String spare5) + { + this.spare5 = spare5; + } + + public String getSpare5() + { + return spare5; + } + + public void setSpare6(String spare6) + { + this.spare6 = spare6; + } + + public String getSpare6() + { + return spare6; + } + + public void setProductName(String productName) + { + this.productName = productName; + } + + public String getProductName() + { + return productName; + } + + public void setSpare7(String spare7) + { + this.spare7 = spare7; + } + + public String getSpare7() + { + return spare7; + } + + public void setSpare8(String spare8) + { + this.spare8 = spare8; + } + + public String getSpare8() + { + return spare8; + } + + public void setSpare9(String spare9) + { + this.spare9 = spare9; + } + + public String getSpare9() + { + return spare9; + } + + public void setSpare10(String spare10) + { + this.spare10 = spare10; + } + + public String getSpare10() + { + return spare10; + } + + public void setSpare11(String spare11) + { + this.spare11 = spare11; + } + + public String getSpare11() + { + return spare11; + } + + public void setSpare12(String spare12) + { + this.spare12 = spare12; + } + + public String getSpare12() + { + return spare12; + } + + public void setSpare13(String spare13) + { + this.spare13 = spare13; + } + + public String getSpare13() + { + return spare13; + } + + public void setSpare14(String spare14) + { + this.spare14 = spare14; + } + + public String getSpare14() + { + return spare14; + } + + public void setSpare15(String spare15) + { + this.spare15 = spare15; + } + + public String getSpare15() + { + return spare15; + } + + public void setSpare16(String spare16) + { + this.spare16 = spare16; + } + + public String getSpare16() + { + return spare16; + } + + public void setSpare17(String spare17) + { + this.spare17 = spare17; + } + + public String getSpare17() + { + return spare17; + } + + public void setSpare18(String spare18) + { + this.spare18 = spare18; + } + + public String getSpare18() + { + return spare18; + } + + public void setSpare19(String spare19) + { + this.spare19 = spare19; + } + + public String getSpare19() + { + return spare19; + } + + public void setSpare20(String spare20) + { + this.spare20 = spare20; + } + + public String getSpare20() + { + return spare20; + } + + public void setSpare21(String spare21) + { + this.spare21 = spare21; + } + + public String getSpare21() + { + return spare21; + } + + public void setSpare22(String spare22) + { + this.spare22 = spare22; + } + + public String getSpare22() + { + return spare22; + } + + public void setSpare23(String spare23) + { + this.spare23 = spare23; + } + + public String getSpare23() + { + return spare23; + } + + public void setSpare24(String spare24) + { + this.spare24 = spare24; + } + + public String getSpare24() + { + return spare24; + } + + public void setSpare25(String spare25) + { + this.spare25 = spare25; + } + + public String getSpare25() + { + return spare25; + } + + public void setSpare26(String spare26) + { + this.spare26 = spare26; + } + + public String getSpare26() + { + return spare26; + } + + public void setSpare27(String spare27) + { + this.spare27 = spare27; + } + + public String getSpare27() + { + return spare27; + } + + public void setSpare28(String spare28) + { + this.spare28 = spare28; + } + + public String getSpare28() + { + return spare28; + } + + public void setSpare29(String spare29) + { + this.spare29 = spare29; + } + + public String getSpare29() + { + return spare29; + } + + public void setSpare30(String spare30) + { + this.spare30 = spare30; + } + + public String getSpare30() + { + return spare30; + } + + public void setSpare31(String spare31) + { + this.spare31 = spare31; + } + + public String getSpare31() + { + return spare31; + } + + public void setSpare32(String spare32) + { + this.spare32 = spare32; + } + + public String getSpare32() + { + return spare32; + } + + public void setSpare33(String spare33) + { + this.spare33 = spare33; + } + + public String getSpare33() + { + return spare33; + } + + public void setSpare34(String spare34) + { + this.spare34 = spare34; + } + + public String getSpare34() + { + return spare34; + } + + public void setSpare35(String spare35) + { + this.spare35 = spare35; + } + + public String getSpare35() + { + return spare35; + } + + public void setSpare36(String spare36) + { + this.spare36 = spare36; + } + + public String getSpare36() + { + return spare36; + } + + public void setSpare37(String spare37) + { + this.spare37 = spare37; + } + + public String getSpare37() + { + return spare37; + } + + public void setSpare38(String spare38) + { + this.spare38 = spare38; + } + + public String getSpare38() + { + return spare38; + } + + public void setSpare39(String spare39) + { + this.spare39 = spare39; + } + + public String getSpare39() + { + return spare39; + } + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("productGuid", getProductGuid()) + .append("productId", getProductId()) + .append("parentId", getParentId()) + .append("price", getPrice()) + .append("cargoNo", getCargoNo()) + .append("unit", getUnit()) + .append("spec", getSpec()) + .append("remark", getRemark()) + .append("spare1", getSpare1()) + .append("spare2", getSpare2()) + .append("spare3", getSpare3()) + .append("spare4", getSpare4()) + .append("spare5", getSpare5()) + .append("spare6", getSpare6()) + .append("productName", getProductName()) + .append("spare7", getSpare7()) + .append("spare8", getSpare8()) + .append("spare9", getSpare9()) + .append("spare10", getSpare10()) + .append("spare11", getSpare11()) + .append("spare12", getSpare12()) + .append("spare13", getSpare13()) + .append("spare14", getSpare14()) + .append("spare15", getSpare15()) + .append("spare16", getSpare16()) + .append("spare17", getSpare17()) + .append("spare18", getSpare18()) + .append("spare19", getSpare19()) + .append("spare20", getSpare20()) + .append("spare21", getSpare21()) + .append("spare22", getSpare22()) + .append("spare23", getSpare23()) + .append("spare24", getSpare24()) + .append("spare25", getSpare25()) + .append("spare26", getSpare26()) + .append("spare27", getSpare27()) + .append("spare28", getSpare28()) + .append("spare29", getSpare29()) + .append("spare30", getSpare30()) + .append("spare31", getSpare31()) + .append("spare32", getSpare32()) + .append("spare33", getSpare33()) + .append("spare34", getSpare34()) + .append("spare35", getSpare35()) + .append("spare36", getSpare36()) + .append("spare37", getSpare37()) + .append("spare38", getSpare38()) + .append("spare39", getSpare39()) + .toString(); + } } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/mapper/BasProductMapper.java b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/mapper/BasProductMapper.java index bec161f..7160b98 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/mapper/BasProductMapper.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/mapper/BasProductMapper.java @@ -4,55 +4,56 @@ import java.util.List; import com.ruoyi.bas.BasProduct.domain.BasProduct; /** - * 物料信息Mapper接口 + * 物料管理Mapper接口 * * @author gw - * @date 2025-09-11 + * @date 2025-09-17 */ public interface BasProductMapper { /** - * 查询物料信息 + * 查询物料管理 * - * @param productGuid 物料信息主键 - * @return 物料信息 + * @param productGuid 物料管理主键 + * @return 物料管理 */ public BasProduct selectBasProductByProductGuid(String productGuid); + public BasProduct selectBasProductByProductId(String productId); /** - * 查询物料信息列表 + * 查询物料管理列表 * - * @param basProduct 物料信息 - * @return 物料信息集合 + * @param basProduct 物料管理 + * @return 物料管理集合 */ public List selectBasProductList(BasProduct basProduct); /** - * 新增物料信息 + * 新增物料管理 * - * @param basProduct 物料信息 + * @param basProduct 物料管理 * @return 结果 */ public int insertBasProduct(BasProduct basProduct); /** - * 修改物料信息 + * 修改物料管理 * - * @param basProduct 物料信息 + * @param basProduct 物料管理 * @return 结果 */ public int updateBasProduct(BasProduct basProduct); /** - * 删除物料信息 + * 删除物料管理 * - * @param productGuid 物料信息主键 + * @param productGuid 物料管理主键 * @return 结果 */ public int deleteBasProductByProductGuid(String productGuid); /** - * 批量删除物料信息 + * 批量删除物料管理 * * @param productGuids 需要删除的数据主键集合 * @return 结果 diff --git a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/service/IBasProductService.java b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/service/IBasProductService.java index 1d9ee4f..666d5f6 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/service/IBasProductService.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/service/IBasProductService.java @@ -4,62 +4,62 @@ import java.util.List; import com.ruoyi.bas.BasProduct.domain.BasProduct; /** - * 物料信息Service接口 - * + * 物料管理Service接口 + * * @author gw - * @date 2025-09-11 + * @date 2025-09-17 */ public interface IBasProductService { /** - * 查询物料信息 - * - * @param productGuid 物料信息主键 - * @return 物料信息 + * 查询物料管理 + * + * @param productGuid 物料管理主键 + * @return 物料管理 */ public BasProduct selectBasProductByProductGuid(String productGuid); + public BasProduct selectBasProductByProductId(String productId); + + List selectBasProductListByProductIds(List productIds); + /** - * 查询物料信息列表 - * - * @param basProduct 物料信息 - * @return 物料信息集合 + * 查询物料管理列表 + * + * @param basProduct 物料管理 + * @return 物料管理集合 */ public List selectBasProductList(BasProduct basProduct); /** - * 新增物料信息 - * - * @param basProduct 物料信息 + * 新增物料管理 + * + * @param basProduct 物料管理 * @return 结果 */ public int insertBasProduct(BasProduct basProduct); /** - * 修改物料信息 - * - * @param basProduct 物料信息 + * 修改物料管理 + * + * @param basProduct 物料管理 * @return 结果 */ public int updateBasProduct(BasProduct basProduct); /** - * 批量删除物料信息 - * - * @param productGuids 需要删除的物料信息主键集合 + * 批量删除物料管理 + * + * @param productGuids 需要删除的物料管理主键集合 * @return 结果 */ public int deleteBasProductByProductGuids(String[] productGuids); /** - * 删除物料信息信息 - * - * @param productGuid 物料信息主键 + * 删除物料管理信息 + * + * @param productGuid 物料管理主键 * @return 结果 */ public int deleteBasProductByProductGuid(String productGuid); - - BasProduct selectBasProductByProductId(String productId); - - List selectBasProductListByProductIds(List collect); } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/service/impl/BasProductServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/service/impl/BasProductServiceImpl.java index 1dafa83..83b91d8 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/service/impl/BasProductServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/bas/BasProduct/service/impl/BasProductServiceImpl.java @@ -1,8 +1,6 @@ package com.ruoyi.bas.BasProduct.service.impl; import java.util.List; - -import cn.hutool.core.util.IdUtil; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import com.ruoyi.bas.BasProduct.mapper.BasProductMapper; @@ -10,22 +8,22 @@ import com.ruoyi.bas.BasProduct.domain.BasProduct; import com.ruoyi.bas.BasProduct.service.IBasProductService; /** - * 物料信息Service业务层处理 - * + * 物料管理Service业务层处理 + * * @author gw - * @date 2025-09-11 + * @date 2025-09-17 */ @Service -public class BasProductServiceImpl implements IBasProductService +public class BasProductServiceImpl implements IBasProductService { @Autowired private BasProductMapper basProductMapper; /** - * 查询物料信息 - * - * @param productGuid 物料信息主键 - * @return 物料信息 + * 查询物料管理 + * + * @param productGuid 物料管理主键 + * @return 物料管理 */ @Override public BasProduct selectBasProductByProductGuid(String productGuid) @@ -33,11 +31,23 @@ public class BasProductServiceImpl implements IBasProductService return basProductMapper.selectBasProductByProductGuid(productGuid); } + @Override + public BasProduct selectBasProductByProductId(String productId) + { + return basProductMapper.selectBasProductByProductId(productId); + } + + @Override + public List selectBasProductListByProductIds(List productIds) + { + return null; + } + /** - * 查询物料信息列表 - * - * @param basProduct 物料信息 - * @return 物料信息 + * 查询物料管理列表 + * + * @param basProduct 物料管理 + * @return 物料管理 */ @Override public List selectBasProductList(BasProduct basProduct) @@ -46,22 +56,22 @@ public class BasProductServiceImpl implements IBasProductService } /** - * 新增物料信息 - * - * @param basProduct 物料信息 + * 新增物料管理 + * + * @param basProduct 物料管理 * @return 结果 */ @Override public int insertBasProduct(BasProduct basProduct) { - basProduct.setProductGuid(IdUtil.fastSimpleUUID()); + basProduct.setProductGuid(basProduct.getProductId()); return basProductMapper.insertBasProduct(basProduct); } /** - * 修改物料信息 - * - * @param basProduct 物料信息 + * 修改物料管理 + * + * @param basProduct 物料管理 * @return 结果 */ @Override @@ -71,9 +81,9 @@ public class BasProductServiceImpl implements IBasProductService } /** - * 批量删除物料信息 - * - * @param productGuids 需要删除的物料信息主键 + * 批量删除物料管理 + * + * @param productGuids 需要删除的物料管理主键 * @return 结果 */ @Override @@ -83,9 +93,9 @@ public class BasProductServiceImpl implements IBasProductService } /** - * 删除物料信息信息 - * - * @param productGuid 物料信息主键 + * 删除物料管理信息 + * + * @param productGuid 物料管理主键 * @return 结果 */ @Override @@ -93,14 +103,4 @@ public class BasProductServiceImpl implements IBasProductService { return basProductMapper.deleteBasProductByProductGuid(productGuid); } - - @Override - public BasProduct selectBasProductByProductId(String productId) { - return null; - } - - @Override - public List selectBasProductListByProductIds(List collect) { - return List.of(); - } } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/receive/stockin/service/impl/ReceiveStockinServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/receive/stockin/service/impl/ReceiveStockinServiceImpl.java index af8315e..5949730 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/receive/stockin/service/impl/ReceiveStockinServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/receive/stockin/service/impl/ReceiveStockinServiceImpl.java @@ -181,8 +181,8 @@ public class ReceiveStockinServiceImpl implements IReceiveStockinService List result = iBasProductService.selectBasProductListByProductIds(collect); for (BasProduct basProduct : result) { Optional first = list.stream().filter(x -> x.getProductId().equals(basProduct.getProductId())).findFirst(); - first.ifPresent(receiveProductVo -> basProduct.setQuantity(receiveProductVo.getQuantity())); - first.ifPresent(receiveProductVo -> basProduct.setLotNo(receiveProductVo.getLotNo())); +// first.ifPresent(receiveProductVo -> basProduct.setQuantity(receiveProductVo.getQuantity())); +// first.ifPresent(receiveProductVo -> basProduct.setLotNo(receiveProductVo.getLotNo())); first.ifPresent(receiveProductVo -> basProduct.setSpare3(receiveProductVo.getCartonNo())); first.ifPresent(receiveProductVo -> basProduct.setSpare4(receiveProductVo.getPackingMethod())); } diff --git a/ruoyi-admin/src/main/resources/mapper/bas/BasProductMapper.xml b/ruoyi-admin/src/main/resources/mapper/bas/BasProductMapper.xml index 4570b74..8c572db 100644 --- a/ruoyi-admin/src/main/resources/mapper/bas/BasProductMapper.xml +++ b/ruoyi-admin/src/main/resources/mapper/bas/BasProductMapper.xml @@ -7,41 +7,107 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - select product_guid, product_id, product_name, spare4, spare7, spare1, spare2, spare8, spare3, spare5, spare6, remark, parent_id, price, cargo_no, unit, spec, spare9 from bas_product + select product_guid, product_id, parent_id, price, cargo_no, unit, spec, remark, spare1, spare2, spare3, spare4, spare5, spare6, product_name, spare7, spare8, spare9, spare10, spare11, spare12, spare13, spare14, spare15, spare16, spare17, spare18, spare19, spare20, spare21, spare22, spare23, spare24, spare25, spare26, spare27, spare28, spare29, spare30, spare31, spare32, spare33, spare34, spare35, spare36, spare37, spare38, spare39 from bas_product @@ -49,71 +115,164 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where product_guid = #{productGuid} - + insert into bas_product product_guid, - product_id, - product_name, - spare4, - spare7, - spare1, - spare2, - spare8, - spare3, - spare5, - spare6, - remark, + product_id, parent_id, price, cargo_no, unit, spec, + remark, + spare1, + spare2, + spare3, + spare4, + spare5, + spare6, + product_name, + spare7, + spare8, spare9, + spare10, + spare11, + spare12, + spare13, + spare14, + spare15, + spare16, + spare17, + spare18, + spare19, + spare20, + spare21, + spare22, + spare23, + spare24, + spare25, + spare26, + spare27, + spare28, + spare29, + spare30, + spare31, + spare32, + spare33, + spare34, + spare35, + spare36, + spare37, + spare38, + spare39, #{productGuid}, - #{productId}, - #{productName}, - #{spare4}, - #{spare7}, - #{spare1}, - #{spare2}, - #{spare8}, - #{spare3}, - #{spare5}, - #{spare6}, - #{remark}, + #{productId}, #{parentId}, #{price}, #{cargoNo}, #{unit}, #{spec}, + #{remark}, + #{spare1}, + #{spare2}, + #{spare3}, + #{spare4}, + #{spare5}, + #{spare6}, + #{productName}, + #{spare7}, + #{spare8}, #{spare9}, + #{spare10}, + #{spare11}, + #{spare12}, + #{spare13}, + #{spare14}, + #{spare15}, + #{spare16}, + #{spare17}, + #{spare18}, + #{spare19}, + #{spare20}, + #{spare21}, + #{spare22}, + #{spare23}, + #{spare24}, + #{spare25}, + #{spare26}, + #{spare27}, + #{spare28}, + #{spare29}, + #{spare30}, + #{spare31}, + #{spare32}, + #{spare33}, + #{spare34}, + #{spare35}, + #{spare36}, + #{spare37}, + #{spare38}, + #{spare39}, update bas_product - product_id = #{productId}, - product_name = #{productName}, - spare4 = #{spare4}, - spare7 = #{spare7}, - spare1 = #{spare1}, - spare2 = #{spare2}, - spare8 = #{spare8}, - spare3 = #{spare3}, - spare5 = #{spare5}, - spare6 = #{spare6}, - remark = #{remark}, + product_id = #{productId}, parent_id = #{parentId}, price = #{price}, cargo_no = #{cargoNo}, unit = #{unit}, spec = #{spec}, + remark = #{remark}, + spare1 = #{spare1}, + spare2 = #{spare2}, + spare3 = #{spare3}, + spare4 = #{spare4}, + spare5 = #{spare5}, + spare6 = #{spare6}, + product_name = #{productName}, + spare7 = #{spare7}, + spare8 = #{spare8}, spare9 = #{spare9}, + spare10 = #{spare10}, + spare11 = #{spare11}, + spare12 = #{spare12}, + spare13 = #{spare13}, + spare14 = #{spare14}, + spare15 = #{spare15}, + spare16 = #{spare16}, + spare17 = #{spare17}, + spare18 = #{spare18}, + spare19 = #{spare19}, + spare20 = #{spare20}, + spare21 = #{spare21}, + spare22 = #{spare22}, + spare23 = #{spare23}, + spare24 = #{spare24}, + spare25 = #{spare25}, + spare26 = #{spare26}, + spare27 = #{spare27}, + spare28 = #{spare28}, + spare29 = #{spare29}, + spare30 = #{spare30}, + spare31 = #{spare31}, + spare32 = #{spare32}, + spare33 = #{spare33}, + spare34 = #{spare34}, + spare35 = #{spare35}, + spare36 = #{spare36}, + spare37 = #{spare37}, + spare38 = #{spare38}, + spare39 = #{spare39}, where product_guid = #{productGuid} diff --git a/ruoyi-ui/src/api/bas/BasProduct.js b/ruoyi-ui/src/api/bas/BasProduct.js index 3184cc4..3c9a8ef 100644 --- a/ruoyi-ui/src/api/bas/BasProduct.js +++ b/ruoyi-ui/src/api/bas/BasProduct.js @@ -1,6 +1,6 @@ import request from '@/utils/request' -// 查询物料信息列表 +// 查询物料管理列表 export function listBasProduct(query) { return request({ url: '/bas/BasProduct/list', @@ -9,7 +9,7 @@ export function listBasProduct(query) { }) } -// 查询物料信息详细 +// 查询物料管理详细 export function getBasProduct(productGuid) { return request({ url: '/bas/BasProduct/' + productGuid, @@ -17,7 +17,7 @@ export function getBasProduct(productGuid) { }) } -// 新增物料信息 +// 新增物料管理 export function addBasProduct(data) { return request({ url: '/bas/BasProduct', @@ -26,7 +26,7 @@ export function addBasProduct(data) { }) } -// 修改物料信息 +// 修改物料管理 export function updateBasProduct(data) { return request({ url: '/bas/BasProduct', @@ -35,7 +35,7 @@ export function updateBasProduct(data) { }) } -// 删除物料信息 +// 删除物料管理 export function delBasProduct(productGuid) { return request({ url: '/bas/BasProduct/' + productGuid, diff --git a/ruoyi-ui/src/views/bas/basProduct/index.vue b/ruoyi-ui/src/views/bas/basProduct/index.vue index da23ce4..e57051f 100644 --- a/ruoyi-ui/src/views/bas/basProduct/index.vue +++ b/ruoyi-ui/src/views/bas/basProduct/index.vue @@ -9,6 +9,94 @@ @keyup.enter.native="handleQuery" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 搜索 重置 @@ -135,19 +423,54 @@ - + - + + + + + + + + - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +