增加产品bom字段

This commit is contained in:
weihongyang 2020-01-03 10:27:02 +08:00
rodzic b8c8a97523
commit a7a4df7db1
5 zmienionych plików z 19 dodań i 10 usunięć

Wyświetl plik

@ -8,6 +8,10 @@
<packaging>pom</packaging>
<version>1.0.0-SNAPSHOT</version>
<modules>
<module>wms-produce-manage</module>
</modules>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
@ -15,9 +19,6 @@
<relativePath/>
</parent>
<modules>
<module>wms-produce-manage</module>
</modules>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

Wyświetl plik

@ -106,7 +106,7 @@
</select>
<select id="findListByTerm" resultMap="ProPrcessBomDTOResultMap">
SELECT u.unit_name,mappb.id,mamp.product_code, mamp.product_name,mamp.specification,mapb.specification AS
SELECT u.unit_name,mappb.id,mappb.product_process_name,mamp.product_code, mamp.product_name,mamp.specification,mapb.specification AS
work_specification,mapb.process_content, COUNT(mapb.process_step) process_step
FROM mt_alone_product_process_bom mappb
LEFT JOIN mt_alone_machining_product mamp ON mappb.product_id = mamp.id

Wyświetl plik

@ -28,6 +28,9 @@ public class ProductProcessBomParams extends QueryParams {
private String productNum;
private String productProcessName;
/**
*添加时间
@ -148,4 +151,12 @@ public class ProductProcessBomParams extends QueryParams {
public void setProductBomId(String productBomId) {
this.productBomId = productBomId;
}
public String getProductProcessName() {
return productProcessName;
}
public void setProductProcessName(String productProcessName) {
this.productProcessName = productProcessName;
}
}

Wyświetl plik

@ -61,6 +61,7 @@ public class ProductProcessBomServiceImpl extends AbstractService<ProductProcess
productProcessBom.setSpecification(params.getSpecification());
productProcessBom.setProductId(params.getProductId());
productProcessBom.setProcessContent(params.getProcessContent());
productProcessBom.setProductProcessName(params.getProductProcessName());
productProcessBomMapper.insert(productProcessBom);
for (ProcessBomParams processBomParams:params.getProcessBomParamsList()) {
ProcessBom processBom = new ProcessBom();
@ -107,7 +108,7 @@ public class ProductProcessBomServiceImpl extends AbstractService<ProductProcess
for (ProcessBomParams processBomParams:params.getProcessBomParamsList()) {
ProcessBom processBom = new ProcessBom();
processBom.setId(processBomParams.getId());
processBom.setCreateTime(processBomParams.getCreateTime());
processBom.setUpdateTime(new Date());
processBom.setProcessName(processBomParams.getProcessName());
processBom.setProductProcessId(processBomParams.getProductProcessId());
processBom.setSpecification(processBomParams.getSpecification());
@ -123,7 +124,7 @@ public class ProductProcessBomServiceImpl extends AbstractService<ProductProcess
for (ProcessMaterialsBomParams processMaterialsBomParams:params.getProcessBomParamsList().get(i).getProcessMaterialsBomParamsList()){
ProcessMaterialsBom processMaterialsBom = new ProcessMaterialsBom();
processMaterialsBom.setId(processMaterialsBomParams.getId());
processMaterialsBom.setCreateTime(new Date());
processMaterialsBom.setUpdateTime(new Date());
processMaterialsBom.setProcessBomId(processMaterialsBomParams.getProcessBomId());
processMaterialsBom.setMaterialsId(processMaterialsBomParams.getMaterialsId());
processMaterialsBom.setCode(processMaterialsBomParams.getCode());

Wyświetl plik

@ -85,10 +85,6 @@ public class ProductProcessBomController {
}
productProcessBomParams.setCreateTime(new Date());
productProcessBomParams.setCompanyId(currentUser.getCompanyId());
// productProcessBomParams.setProductId(1);
// productProcessBomParams.setProcessContent("1");
// productProcessBomParams.setSpecification("1");
productProcessBomService.updateProductProcessBom(productProcessBomParams);
return ResultGenerator.genSuccessResult();
}