8 changed files with 502 additions and 0 deletions
-
1.idea/MyBatisCodeHelperDatasource.xml
-
33src/main/java/com/spring/modules/sampleManagement/controller/TechnicalSpecificationController.java
-
27src/main/java/com/spring/modules/sampleManagement/dao/TechnicalSpecificationMapper.java
-
127src/main/java/com/spring/modules/sampleManagement/data/PlmTechnicalSpecificationSheetData.java
-
235src/main/java/com/spring/modules/sampleManagement/entity/PlmTechnicalSpecificationSheet.java
-
24src/main/java/com/spring/modules/sampleManagement/service/Impl/TechnicalSpecificationServiceImpl.java
-
20src/main/java/com/spring/modules/sampleManagement/service/TechnicalSpecificationService.java
-
35src/main/resources/mapper/sampleManagement/TechnicalSpecificationMapper.xml
@ -0,0 +1,33 @@ |
|||
package com.spring.modules.sampleManagement.controller; |
|||
|
|||
|
|||
|
|||
import com.spring.common.utils.PageUtils; |
|||
import com.spring.common.utils.R; |
|||
import com.spring.modules.project.data.PlmProjectInfoData; |
|||
import com.spring.modules.sampleManagement.data.PlmTechnicalSpecificationSheetData; |
|||
import com.spring.modules.sampleManagement.service.TechnicalSpecificationService; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Controller; |
|||
|
|||
import org.springframework.web.bind.annotation.PostMapping; |
|||
import org.springframework.web.bind.annotation.RequestBody; |
|||
import org.springframework.web.bind.annotation.RequestMapping; |
|||
import org.springframework.web.bind.annotation.ResponseBody; |
|||
|
|||
|
|||
@RequestMapping("/technicalSpecification") |
|||
@Controller |
|||
public class TechnicalSpecificationController { |
|||
|
|||
@Autowired |
|||
private TechnicalSpecificationService technicalSpecificationService; |
|||
|
|||
@PostMapping(value="/technicalSpecificationListSearch") |
|||
@ResponseBody |
|||
public R technicalSpecificationListSearch(@RequestBody PlmTechnicalSpecificationSheetData data){ |
|||
PageUtils page = technicalSpecificationService.technicalSpecificationListSearch(data); |
|||
return R.ok().put("page", page); |
|||
} |
|||
|
|||
} |
|||
@ -0,0 +1,27 @@ |
|||
package com.spring.modules.sampleManagement.dao; |
|||
|
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
|||
import com.spring.modules.project.data.PlmProjectInfoData; |
|||
import com.spring.modules.sampleManagement.data.PlmTechnicalSpecificationSheetData; |
|||
import org.apache.ibatis.annotations.Mapper; |
|||
import org.apache.ibatis.annotations.Param; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Repository; |
|||
|
|||
@Mapper |
|||
@Repository |
|||
public interface TechnicalSpecificationMapper { |
|||
|
|||
/** |
|||
* @Description TODO |
|||
* @Title technicalSpecificationListSearch |
|||
* @param page |
|||
* @param inData |
|||
* @author rq |
|||
* @date 2023/9/25 17:45 |
|||
* @return IPage<PlmTechnicalSpecificationSheetData> |
|||
* @throw |
|||
*/ |
|||
IPage<PlmTechnicalSpecificationSheetData> technicalSpecificationListSearch(Page<PlmTechnicalSpecificationSheetData> page, @Param("query") PlmTechnicalSpecificationSheetData inData); |
|||
} |
|||
@ -0,0 +1,127 @@ |
|||
package com.spring.modules.sampleManagement.data; |
|||
|
|||
import com.spring.modules.sampleManagement.entity.PlmTechnicalSpecificationSheet; |
|||
import org.apache.ibatis.type.Alias; |
|||
|
|||
import java.util.List; |
|||
@Alias("PlmTechnicalSpecificationSheetData") |
|||
public class PlmTechnicalSpecificationSheetData extends PlmTechnicalSpecificationSheet { |
|||
|
|||
private String partType; |
|||
private String partTypeDesc; |
|||
private String statusDesc; |
|||
private String partName; |
|||
private String partDesc; |
|||
private String finalPartNo; |
|||
private String quotationOfficer; |
|||
private String engineer; |
|||
private String technician; |
|||
private String customerId; |
|||
private List<String> quotationOfficerList; |
|||
private List<String> engineerList; |
|||
private List<String> technicianList; |
|||
|
|||
public String getPartType() { |
|||
return partType; |
|||
} |
|||
|
|||
public void setPartType(String partType) { |
|||
this.partType = partType; |
|||
} |
|||
|
|||
public String getStatusDesc() { |
|||
return statusDesc; |
|||
} |
|||
|
|||
public void setStatusDesc(String statusDesc) { |
|||
this.statusDesc = statusDesc; |
|||
} |
|||
|
|||
public String getPartName() { |
|||
return partName; |
|||
} |
|||
|
|||
public void setPartName(String partName) { |
|||
this.partName = partName; |
|||
} |
|||
|
|||
public String getPartDesc() { |
|||
return partDesc; |
|||
} |
|||
|
|||
public void setPartDesc(String partDesc) { |
|||
this.partDesc = partDesc; |
|||
} |
|||
|
|||
public String getFinalPartNo() { |
|||
return finalPartNo; |
|||
} |
|||
|
|||
public void setFinalPartNo(String finalPartNo) { |
|||
this.finalPartNo = finalPartNo; |
|||
} |
|||
|
|||
public String getQuotationOfficer() { |
|||
return quotationOfficer; |
|||
} |
|||
|
|||
public void setQuotationOfficer(String quotationOfficer) { |
|||
this.quotationOfficer = quotationOfficer; |
|||
} |
|||
|
|||
public String getEngineer() { |
|||
return engineer; |
|||
} |
|||
|
|||
public void setEngineer(String engineer) { |
|||
this.engineer = engineer; |
|||
} |
|||
|
|||
public String getTechnician() { |
|||
return technician; |
|||
} |
|||
|
|||
public void setTechnician(String technician) { |
|||
this.technician = technician; |
|||
} |
|||
|
|||
public String getCustomerId() { |
|||
return customerId; |
|||
} |
|||
|
|||
public void setCustomerId(String customerId) { |
|||
this.customerId = customerId; |
|||
} |
|||
|
|||
public List<String> getQuotationOfficerList() { |
|||
return quotationOfficerList; |
|||
} |
|||
|
|||
public void setQuotationOfficerList(List<String> quotationOfficerList) { |
|||
this.quotationOfficerList = quotationOfficerList; |
|||
} |
|||
|
|||
public List<String> getEngineerList() { |
|||
return engineerList; |
|||
} |
|||
|
|||
public void setEngineerList(List<String> engineerList) { |
|||
this.engineerList = engineerList; |
|||
} |
|||
|
|||
public List<String> getTechnicianList() { |
|||
return technicianList; |
|||
} |
|||
|
|||
public void setTechnicianList(List<String> technicianList) { |
|||
this.technicianList = technicianList; |
|||
} |
|||
|
|||
public String getPartTypeDesc() { |
|||
return partTypeDesc; |
|||
} |
|||
|
|||
public void setPartTypeDesc(String partTypeDesc) { |
|||
this.partTypeDesc = partTypeDesc; |
|||
} |
|||
} |
|||
@ -0,0 +1,235 @@ |
|||
package com.spring.modules.sampleManagement.entity; |
|||
|
|||
import com.fasterxml.jackson.annotation.JsonFormat; |
|||
import com.spring.common.utils.QueryPage; |
|||
import org.springframework.format.annotation.DateTimeFormat; |
|||
|
|||
import java.util.Date; |
|||
|
|||
public class PlmTechnicalSpecificationSheet extends QueryPage { |
|||
/** |
|||
* |
|||
*/ |
|||
private Integer id; |
|||
|
|||
/** |
|||
* 工厂编码 |
|||
*/ |
|||
private String site; |
|||
|
|||
/** |
|||
* 参数卡编码 |
|||
*/ |
|||
private String codeNo; |
|||
|
|||
/** |
|||
* |
|||
*/ |
|||
private String proofingNo; |
|||
|
|||
/** |
|||
* 项目编码 |
|||
*/ |
|||
private String projectId; |
|||
|
|||
/** |
|||
* 项目料号 |
|||
*/ |
|||
private String testPartNo; |
|||
|
|||
/** |
|||
* 状态编码 |
|||
*/ |
|||
private String status; |
|||
|
|||
/** |
|||
* 版本号 |
|||
*/ |
|||
private String revNo; |
|||
|
|||
/** |
|||
* 加工中心 |
|||
*/ |
|||
private String workCenterNo; |
|||
|
|||
/** |
|||
* ECN记录 |
|||
*/ |
|||
private String ecnFlag; |
|||
|
|||
/** |
|||
* ECN单据号 |
|||
*/ |
|||
private String ecnNo; |
|||
|
|||
/** |
|||
* ECN文档路径 |
|||
*/ |
|||
private String ecnAddress; |
|||
|
|||
/** |
|||
* 备注 |
|||
*/ |
|||
private String remark; |
|||
|
|||
/** |
|||
* 创建时间 |
|||
*/ |
|||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
|||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
|||
private Date createDate; |
|||
|
|||
/** |
|||
* 创建人 |
|||
*/ |
|||
private String createBy; |
|||
|
|||
/** |
|||
* 更新时间 |
|||
*/ |
|||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") |
|||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") |
|||
private Date updateDate; |
|||
|
|||
/** |
|||
* 更新人 |
|||
*/ |
|||
private String updateBy; |
|||
|
|||
public Integer getId() { |
|||
return id; |
|||
} |
|||
|
|||
public void setId(Integer id) { |
|||
this.id = id; |
|||
} |
|||
|
|||
public String getSite() { |
|||
return site; |
|||
} |
|||
|
|||
public void setSite(String site) { |
|||
this.site = site; |
|||
} |
|||
|
|||
public String getCodeNo() { |
|||
return codeNo; |
|||
} |
|||
|
|||
public void setCodeNo(String codeNo) { |
|||
this.codeNo = codeNo; |
|||
} |
|||
|
|||
public String getProofingNo() { |
|||
return proofingNo; |
|||
} |
|||
|
|||
public void setProofingNo(String proofingNo) { |
|||
this.proofingNo = proofingNo; |
|||
} |
|||
|
|||
public String getProjectId() { |
|||
return projectId; |
|||
} |
|||
|
|||
public void setProjectId(String projectId) { |
|||
this.projectId = projectId; |
|||
} |
|||
|
|||
public String getTestPartNo() { |
|||
return testPartNo; |
|||
} |
|||
|
|||
public void setTestPartNo(String testPartNo) { |
|||
this.testPartNo = testPartNo; |
|||
} |
|||
|
|||
public String getStatus() { |
|||
return status; |
|||
} |
|||
|
|||
public void setStatus(String status) { |
|||
this.status = status; |
|||
} |
|||
|
|||
public String getRevNo() { |
|||
return revNo; |
|||
} |
|||
|
|||
public void setRevNo(String revNo) { |
|||
this.revNo = revNo; |
|||
} |
|||
|
|||
public String getWorkCenterNo() { |
|||
return workCenterNo; |
|||
} |
|||
|
|||
public void setWorkCenterNo(String workCenterNo) { |
|||
this.workCenterNo = workCenterNo; |
|||
} |
|||
|
|||
public String getEcnFlag() { |
|||
return ecnFlag; |
|||
} |
|||
|
|||
public void setEcnFlag(String ecnFlag) { |
|||
this.ecnFlag = ecnFlag; |
|||
} |
|||
|
|||
public String getEcnNo() { |
|||
return ecnNo; |
|||
} |
|||
|
|||
public void setEcnNo(String ecnNo) { |
|||
this.ecnNo = ecnNo; |
|||
} |
|||
|
|||
public String getEcnAddress() { |
|||
return ecnAddress; |
|||
} |
|||
|
|||
public void setEcnAddress(String ecnAddress) { |
|||
this.ecnAddress = ecnAddress; |
|||
} |
|||
|
|||
public String getRemark() { |
|||
return remark; |
|||
} |
|||
|
|||
public void setRemark(String remark) { |
|||
this.remark = remark; |
|||
} |
|||
|
|||
public Date getCreateDate() { |
|||
return createDate; |
|||
} |
|||
|
|||
public void setCreateDate(Date createDate) { |
|||
this.createDate = createDate; |
|||
} |
|||
|
|||
public String getCreateBy() { |
|||
return createBy; |
|||
} |
|||
|
|||
public void setCreateBy(String createBy) { |
|||
this.createBy = createBy; |
|||
} |
|||
|
|||
public Date getUpdateDate() { |
|||
return updateDate; |
|||
} |
|||
|
|||
public void setUpdateDate(Date updateDate) { |
|||
this.updateDate = updateDate; |
|||
} |
|||
|
|||
public String getUpdateBy() { |
|||
return updateBy; |
|||
} |
|||
|
|||
public void setUpdateBy(String updateBy) { |
|||
this.updateBy = updateBy; |
|||
} |
|||
} |
|||
|
|||
@ -0,0 +1,24 @@ |
|||
package com.spring.modules.sampleManagement.service.Impl; |
|||
|
|||
import com.baomidou.mybatisplus.core.metadata.IPage; |
|||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
|||
import com.spring.common.utils.PageUtils; |
|||
import com.spring.modules.project.data.PlmProjectInfoData; |
|||
import com.spring.modules.sampleManagement.dao.TechnicalSpecificationMapper; |
|||
import com.spring.modules.sampleManagement.data.PlmTechnicalSpecificationSheetData; |
|||
import com.spring.modules.sampleManagement.service.TechnicalSpecificationService; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Service; |
|||
|
|||
@Service |
|||
public class TechnicalSpecificationServiceImpl implements TechnicalSpecificationService { |
|||
@Autowired |
|||
private TechnicalSpecificationMapper technicalSpecificationMapper; |
|||
|
|||
@Override |
|||
public PageUtils technicalSpecificationListSearch(PlmTechnicalSpecificationSheetData inData){ |
|||
IPage<PlmTechnicalSpecificationSheetData> resultList = this.technicalSpecificationMapper.technicalSpecificationListSearch( |
|||
new Page<PlmTechnicalSpecificationSheetData>(inData.getPage(), inData.getLimit()), inData); |
|||
return new PageUtils(resultList); |
|||
} |
|||
} |
|||
@ -0,0 +1,20 @@ |
|||
package com.spring.modules.sampleManagement.service; |
|||
|
|||
import com.spring.common.utils.PageUtils; |
|||
import com.spring.modules.project.data.PlmProjectInfoData; |
|||
import com.spring.modules.sampleManagement.data.PlmTechnicalSpecificationSheetData; |
|||
|
|||
public interface TechnicalSpecificationService { |
|||
|
|||
/** |
|||
* @param inData |
|||
* @return |
|||
* @Description 查询项目 |
|||
* @Title |
|||
* @author rq |
|||
* @date 2023/1/29 13:34 |
|||
* @throw |
|||
*/ |
|||
PageUtils technicalSpecificationListSearch(PlmTechnicalSpecificationSheetData inData); |
|||
|
|||
} |
|||
@ -0,0 +1,35 @@ |
|||
<?xml version="1.0" encoding="UTF-8"?> |
|||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
|||
<mapper namespace="com.spring.modules.sampleManagement.dao.TechnicalSpecificationMapper"> |
|||
|
|||
<select id="technicalSpecificationListSearch" parameterType="PlmTechnicalSpecificationSheetData" resultType="PlmTechnicalSpecificationSheetData"> |
|||
SELECT a.id,a.site,a.code_no,a.proofing_no,a.project_id,a.test_part_no,a.status,a.rev_no,a.work_center_no,a.ECN_flag,a.ECN_no, |
|||
a.ECN_address,a.remark,a.create_date,a.create_by,a.update_date,a.update_by,b.final_part_no,dbo.plm_get_projectBaseDesc(b.part_type,'part_type') partTypeDesc, |
|||
b.part_type,b.part_name,b.part_desc,b.part_spec,dbo.plm_get_technicalBaseDesc(a.status,'status') statusDesc, |
|||
dbo.get_technicalSpecificationTeamName(a.site,a.code_no,'engineer') engineer, |
|||
dbo.get_technicalSpecificationTeamName(a.site,a.code_no,'technician') technician, |
|||
dbo.get_technicalSpecificationTeamName(a.site,a.code_no,'customerId') customerId |
|||
FROM plm_technical_specification_sheet a |
|||
left join plm_project_part b on a.site=b.site and a.project_id=b.project_id and a.test_part_no=b.test_part_no |
|||
<where> |
|||
<if test="query.id != null"> |
|||
AND a.id = #{query.id} |
|||
</if> |
|||
<if test="query.site != null and query.site != ''"> |
|||
AND a.site = #{query.site} |
|||
</if> |
|||
<if test="query.codeNo != null and query.codeNo != ''"> |
|||
AND a.code_no like #{query.codeNo} |
|||
</if> |
|||
<if test="query.projectId != null and query.projectId != ''"> |
|||
AND a.project_id like #{query.projectId} |
|||
</if> |
|||
<if test="query.testPartNo != null and query.testPartNo != ''"> |
|||
AND a.test_part_no like #{query.testPartNo} |
|||
</if> |
|||
</where> |
|||
</select> |
|||
|
|||
|
|||
|
|||
</mapper> |
|||
Write
Preview
Loading…
Cancel
Save
Reference in new issue