Merge remote-tracking branch 'origin/master'
commit
5803ae6782
@ -0,0 +1,123 @@
|
||||
package com.op.quality.controller;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.op.common.core.utils.DateUtils;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.op.common.log.annotation.Log;
|
||||
import com.op.common.log.enums.BusinessType;
|
||||
import com.op.common.security.annotation.RequiresPermissions;
|
||||
import com.op.quality.domain.QcCheckUnqualified;
|
||||
import com.op.quality.service.IQcCheckUnqualifiedService;
|
||||
import com.op.common.core.web.controller.BaseController;
|
||||
import com.op.common.core.web.domain.AjaxResult;
|
||||
import com.op.common.core.utils.poi.ExcelUtil;
|
||||
import com.op.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 不合格处理Controller
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/unqualified")
|
||||
public class QcCheckUnqualifiedController extends BaseController {
|
||||
@Autowired
|
||||
private IQcCheckUnqualifiedService qcCheckUnqualifiedService;
|
||||
|
||||
/**
|
||||
* 查询不合格处理列表
|
||||
*/
|
||||
@RequiresPermissions("quality:unqualified:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(QcCheckUnqualified qcCheckUnqualified) {
|
||||
startPage();
|
||||
|
||||
//默认时间范围T 00:00:00~T+1 00:00:00
|
||||
if(StringUtils.isEmpty(qcCheckUnqualified.getCheckTimeStart())){
|
||||
qcCheckUnqualified.setCheckTimeStart(DateUtils.getDate()+" 00:00:00");//start
|
||||
LocalDate date = LocalDate.now();
|
||||
LocalDate dateEnd = date.plusDays(1);
|
||||
DateTimeFormatter dtf = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
||||
String dateEndStr = dtf.format(dateEnd)+" 00:00:00";
|
||||
qcCheckUnqualified.setCheckTimeEnd(dateEndStr);//end
|
||||
}
|
||||
qcCheckUnqualified.setDelFlag("0");
|
||||
List<QcCheckUnqualified> list = qcCheckUnqualifiedService.selectQcCheckUnqualifiedList(qcCheckUnqualified);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出不合格处理列表
|
||||
*/
|
||||
@RequiresPermissions("quality:unqualified:export")
|
||||
@Log(title = "不合格处理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, QcCheckUnqualified qcCheckUnqualified) {
|
||||
//默认时间范围T 00:00:00~T+1 00:00:00
|
||||
if(StringUtils.isEmpty(qcCheckUnqualified.getCheckTimeStart())){
|
||||
qcCheckUnqualified.setCheckTimeStart(DateUtils.getDate()+" 00:00:00");//start
|
||||
LocalDate date = LocalDate.now();
|
||||
LocalDate dateEnd = date.plusDays(1);
|
||||
DateTimeFormatter dtf = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
||||
String dateEndStr = dtf.format(dateEnd)+" 00:00:00";
|
||||
qcCheckUnqualified.setCheckTimeEnd(dateEndStr);//end
|
||||
}
|
||||
qcCheckUnqualified.setDelFlag("0");
|
||||
List<QcCheckUnqualified> list = qcCheckUnqualifiedService.selectQcCheckUnqualifiedList(qcCheckUnqualified);
|
||||
ExcelUtil<QcCheckUnqualified> util = new ExcelUtil<QcCheckUnqualified>(QcCheckUnqualified.class);
|
||||
util.exportExcel(response, list, "不合格处理数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取不合格处理详细信息
|
||||
*/
|
||||
@RequiresPermissions("quality:unqualified:query")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") String id) {
|
||||
return success(qcCheckUnqualifiedService.selectQcCheckUnqualifiedById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增不合格处理
|
||||
*/
|
||||
@RequiresPermissions("quality:unqualified:add")
|
||||
@Log(title = "不合格处理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody QcCheckUnqualified qcCheckUnqualified) {
|
||||
return toAjax(qcCheckUnqualifiedService.insertQcCheckUnqualified(qcCheckUnqualified));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改不合格处理
|
||||
*/
|
||||
@RequiresPermissions("quality:unqualified:edit")
|
||||
@Log(title = "不合格处理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody QcCheckUnqualified qcCheckUnqualified) {
|
||||
return toAjax(qcCheckUnqualifiedService.updateQcCheckUnqualified(qcCheckUnqualified));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除不合格处理
|
||||
*/
|
||||
@RequiresPermissions("quality:unqualified:remove")
|
||||
@Log(title = "不合格处理", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable String[] ids) {
|
||||
return toAjax(qcCheckUnqualifiedService.deleteQcCheckUnqualifiedByIds(ids));
|
||||
}
|
||||
}
|
@ -0,0 +1,97 @@
|
||||
package com.op.quality.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.op.common.log.annotation.Log;
|
||||
import com.op.common.log.enums.BusinessType;
|
||||
import com.op.common.security.annotation.RequiresPermissions;
|
||||
import com.op.quality.domain.QcCheckUnqualifiedDetail;
|
||||
import com.op.quality.service.IQcCheckUnqualifiedDetailService;
|
||||
import com.op.common.core.web.controller.BaseController;
|
||||
import com.op.common.core.web.domain.AjaxResult;
|
||||
import com.op.common.core.utils.poi.ExcelUtil;
|
||||
import com.op.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 不合格处理详情Controller
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/unqualityDetail")
|
||||
public class QcCheckUnqualifiedDetailController extends BaseController {
|
||||
@Autowired
|
||||
private IQcCheckUnqualifiedDetailService qcCheckUnqualifiedDetailService;
|
||||
|
||||
/**
|
||||
* 查询不合格处理详情列表
|
||||
*/
|
||||
//@RequiresPermissions("unqualityDetail:unqualityDetail:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail) {
|
||||
startPage();
|
||||
List<QcCheckUnqualifiedDetail> list = qcCheckUnqualifiedDetailService.selectQcCheckUnqualifiedDetailList(qcCheckUnqualifiedDetail);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出不合格处理详情列表
|
||||
*/
|
||||
//@RequiresPermissions("unqualityDetail:unqualityDetail:export")
|
||||
@Log(title = "不合格处理详情", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail) {
|
||||
List<QcCheckUnqualifiedDetail> list = qcCheckUnqualifiedDetailService.selectQcCheckUnqualifiedDetailList(qcCheckUnqualifiedDetail);
|
||||
ExcelUtil<QcCheckUnqualifiedDetail> util = new ExcelUtil<QcCheckUnqualifiedDetail>(QcCheckUnqualifiedDetail.class);
|
||||
util.exportExcel(response, list, "不合格处理详情数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取不合格处理详情详细信息
|
||||
*/
|
||||
//@RequiresPermissions("unqualityDetail:unqualityDetail:query")
|
||||
@GetMapping(value = "/{recordId}")
|
||||
public AjaxResult getInfo(@PathVariable("recordId") String recordId) {
|
||||
return success(qcCheckUnqualifiedDetailService.selectQcCheckUnqualifiedDetailByRecordId(recordId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增不合格处理详情
|
||||
*/
|
||||
//@RequiresPermissions("unqualityDetail:unqualityDetail:add")
|
||||
@Log(title = "不合格处理详情", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail) {
|
||||
return toAjax(qcCheckUnqualifiedDetailService.insertQcCheckUnqualifiedDetail(qcCheckUnqualifiedDetail));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改不合格处理详情
|
||||
*/
|
||||
//@RequiresPermissions("unqualityDetail:unqualityDetail:edit")
|
||||
@Log(title = "不合格处理详情", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail) {
|
||||
return toAjax(qcCheckUnqualifiedDetailService.updateQcCheckUnqualifiedDetail(qcCheckUnqualifiedDetail));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除不合格处理详情
|
||||
*/
|
||||
//@RequiresPermissions("unqualityDetail:unqualityDetail:remove")
|
||||
@Log(title = "不合格处理详情", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{recordIds}")
|
||||
public AjaxResult remove(@PathVariable String[] recordIds) {
|
||||
return toAjax(qcCheckUnqualifiedDetailService.deleteQcCheckUnqualifiedDetailByRecordIds(recordIds));
|
||||
}
|
||||
}
|
@ -0,0 +1,187 @@
|
||||
package com.op.quality.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.op.common.core.annotation.Excel;
|
||||
import com.op.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 不合格处理对象 qc_check_unqualified
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
public class QcCheckUnqualified extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** id */
|
||||
private String id;
|
||||
|
||||
/** 归属任务编码 */
|
||||
@Excel(name = "归属任务编码")
|
||||
private String taskId;
|
||||
|
||||
/** 0未处理 */
|
||||
@Excel(name = "0未处理")
|
||||
private String status;
|
||||
|
||||
/** 下一节点编码 */
|
||||
@Excel(name = "下一节点编码")
|
||||
private String nextNodeCode;
|
||||
|
||||
/** 下一节点名称 */
|
||||
@Excel(name = "下一节点名称")
|
||||
private String nextNodeName;
|
||||
|
||||
/** 预留字段1 */
|
||||
@Excel(name = "预留字段1")
|
||||
private String attr1;
|
||||
|
||||
/** 预留字段2 */
|
||||
@Excel(name = "预留字段2")
|
||||
private String attr2;
|
||||
|
||||
/** 预留字段3 */
|
||||
@Excel(name = "预留字段3")
|
||||
private String attr3;
|
||||
|
||||
/** 预留字段4 */
|
||||
@Excel(name = "预留字段4")
|
||||
private String attr4;
|
||||
|
||||
/** 工厂编码 */
|
||||
@Excel(name = "工厂编码")
|
||||
private String factoryCode;
|
||||
|
||||
/** 删除标识1删除0正常 */
|
||||
private String delFlag;
|
||||
|
||||
private String checkTimeStart;
|
||||
private String checkTimeEnd;
|
||||
|
||||
private String type;
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void setType(String type) {
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
public String getCheckTimeStart() {
|
||||
return checkTimeStart;
|
||||
}
|
||||
|
||||
public void setCheckTimeStart(String checkTimeStart) {
|
||||
this.checkTimeStart = checkTimeStart;
|
||||
}
|
||||
|
||||
public String getCheckTimeEnd() {
|
||||
return checkTimeEnd;
|
||||
}
|
||||
|
||||
public void setCheckTimeEnd(String checkTimeEnd) {
|
||||
this.checkTimeEnd = checkTimeEnd;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
public void setTaskId(String taskId) {
|
||||
this.taskId = taskId;
|
||||
}
|
||||
|
||||
public String getTaskId() {
|
||||
return taskId;
|
||||
}
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
public void setNextNodeCode(String nextNodeCode) {
|
||||
this.nextNodeCode = nextNodeCode;
|
||||
}
|
||||
|
||||
public String getNextNodeCode() {
|
||||
return nextNodeCode;
|
||||
}
|
||||
public void setNextNodeName(String nextNodeName) {
|
||||
this.nextNodeName = nextNodeName;
|
||||
}
|
||||
|
||||
public String getNextNodeName() {
|
||||
return nextNodeName;
|
||||
}
|
||||
public void setAttr1(String attr1) {
|
||||
this.attr1 = attr1;
|
||||
}
|
||||
|
||||
public String getAttr1() {
|
||||
return attr1;
|
||||
}
|
||||
public void setAttr2(String attr2) {
|
||||
this.attr2 = attr2;
|
||||
}
|
||||
|
||||
public String getAttr2() {
|
||||
return attr2;
|
||||
}
|
||||
public void setAttr3(String attr3) {
|
||||
this.attr3 = attr3;
|
||||
}
|
||||
|
||||
public String getAttr3() {
|
||||
return attr3;
|
||||
}
|
||||
public void setAttr4(String attr4) {
|
||||
this.attr4 = attr4;
|
||||
}
|
||||
|
||||
public String getAttr4() {
|
||||
return attr4;
|
||||
}
|
||||
public void setFactoryCode(String factoryCode) {
|
||||
this.factoryCode = factoryCode;
|
||||
}
|
||||
|
||||
public String getFactoryCode() {
|
||||
return factoryCode;
|
||||
}
|
||||
public void setDelFlag(String delFlag) {
|
||||
this.delFlag = delFlag;
|
||||
}
|
||||
|
||||
public String getDelFlag() {
|
||||
return delFlag;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("taskId", getTaskId())
|
||||
.append("status", getStatus())
|
||||
.append("nextNodeCode", getNextNodeCode())
|
||||
.append("nextNodeName", getNextNodeName())
|
||||
.append("remark", getRemark())
|
||||
.append("attr1", getAttr1())
|
||||
.append("attr2", getAttr2())
|
||||
.append("attr3", getAttr3())
|
||||
.append("attr4", getAttr4())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("factoryCode", getFactoryCode())
|
||||
.append("delFlag", getDelFlag())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,182 @@
|
||||
package com.op.quality.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.op.common.core.annotation.Excel;
|
||||
import com.op.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 不合格处理详情对象 qc_check_unqualified_detail
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
public class QcCheckUnqualifiedDetail extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** id */
|
||||
private String recordId;
|
||||
|
||||
/** 归属任务编码 */
|
||||
@Excel(name = "归属任务编码")
|
||||
private String unqualifiedId;
|
||||
|
||||
/** 顺序 */
|
||||
@Excel(name = "顺序")
|
||||
private String sort;
|
||||
|
||||
/** 处理人编码 */
|
||||
@Excel(name = "处理人编码")
|
||||
private String dowithCode;
|
||||
|
||||
/** 处理人名称 */
|
||||
@Excel(name = "处理人名称")
|
||||
private String dowithName;
|
||||
|
||||
/** 处理意见 */
|
||||
@Excel(name = "处理意见")
|
||||
private String dowithRemark;
|
||||
|
||||
/** Y合格N不合格 */
|
||||
@Excel(name = "Y合格N不合格")
|
||||
private String status;
|
||||
|
||||
/** 预留字段1 */
|
||||
@Excel(name = "预留字段1")
|
||||
private String attr1;
|
||||
|
||||
/** 预留字段2 */
|
||||
@Excel(name = "预留字段2")
|
||||
private String attr2;
|
||||
|
||||
/** 预留字段3 */
|
||||
@Excel(name = "预留字段3")
|
||||
private String attr3;
|
||||
|
||||
/** 预留字段4 */
|
||||
@Excel(name = "预留字段4")
|
||||
private String attr4;
|
||||
|
||||
/** 工厂编码 */
|
||||
@Excel(name = "工厂编码")
|
||||
private String factoryCode;
|
||||
|
||||
/** 删除标识1删除0正常 */
|
||||
private String delFlag;
|
||||
|
||||
public void setRecordId(String recordId) {
|
||||
this.recordId = recordId;
|
||||
}
|
||||
|
||||
public String getRecordId() {
|
||||
return recordId;
|
||||
}
|
||||
public void setUnqualifiedId(String unqualifiedId) {
|
||||
this.unqualifiedId = unqualifiedId;
|
||||
}
|
||||
|
||||
public String getUnqualifiedId() {
|
||||
return unqualifiedId;
|
||||
}
|
||||
public void setSort(String sort) {
|
||||
this.sort = sort;
|
||||
}
|
||||
|
||||
public String getSort() {
|
||||
return sort;
|
||||
}
|
||||
public void setDowithCode(String dowithCode) {
|
||||
this.dowithCode = dowithCode;
|
||||
}
|
||||
|
||||
public String getDowithCode() {
|
||||
return dowithCode;
|
||||
}
|
||||
public void setDowithName(String dowithName) {
|
||||
this.dowithName = dowithName;
|
||||
}
|
||||
|
||||
public String getDowithName() {
|
||||
return dowithName;
|
||||
}
|
||||
public void setDowithRemark(String dowithRemark) {
|
||||
this.dowithRemark = dowithRemark;
|
||||
}
|
||||
|
||||
public String getDowithRemark() {
|
||||
return dowithRemark;
|
||||
}
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
public void setAttr1(String attr1) {
|
||||
this.attr1 = attr1;
|
||||
}
|
||||
|
||||
public String getAttr1() {
|
||||
return attr1;
|
||||
}
|
||||
public void setAttr2(String attr2) {
|
||||
this.attr2 = attr2;
|
||||
}
|
||||
|
||||
public String getAttr2() {
|
||||
return attr2;
|
||||
}
|
||||
public void setAttr3(String attr3) {
|
||||
this.attr3 = attr3;
|
||||
}
|
||||
|
||||
public String getAttr3() {
|
||||
return attr3;
|
||||
}
|
||||
public void setAttr4(String attr4) {
|
||||
this.attr4 = attr4;
|
||||
}
|
||||
|
||||
public String getAttr4() {
|
||||
return attr4;
|
||||
}
|
||||
public void setFactoryCode(String factoryCode) {
|
||||
this.factoryCode = factoryCode;
|
||||
}
|
||||
|
||||
public String getFactoryCode() {
|
||||
return factoryCode;
|
||||
}
|
||||
public void setDelFlag(String delFlag) {
|
||||
this.delFlag = delFlag;
|
||||
}
|
||||
|
||||
public String getDelFlag() {
|
||||
return delFlag;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("recordId", getRecordId())
|
||||
.append("unqualifiedId", getUnqualifiedId())
|
||||
.append("sort", getSort())
|
||||
.append("dowithCode", getDowithCode())
|
||||
.append("dowithName", getDowithName())
|
||||
.append("dowithRemark", getDowithRemark())
|
||||
.append("status", getStatus())
|
||||
.append("remark", getRemark())
|
||||
.append("attr1", getAttr1())
|
||||
.append("attr2", getAttr2())
|
||||
.append("attr3", getAttr3())
|
||||
.append("attr4", getAttr4())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("factoryCode", getFactoryCode())
|
||||
.append("delFlag", getDelFlag())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,63 @@
|
||||
package com.op.quality.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.op.quality.domain.QcCheckUnqualifiedDetail;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 不合格处理详情Mapper接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
@Mapper
|
||||
public interface QcCheckUnqualifiedDetailMapper {
|
||||
/**
|
||||
* 查询不合格处理详情
|
||||
*
|
||||
* @param recordId 不合格处理详情主键
|
||||
* @return 不合格处理详情
|
||||
*/
|
||||
public QcCheckUnqualifiedDetail selectQcCheckUnqualifiedDetailByRecordId(String recordId);
|
||||
|
||||
/**
|
||||
* 查询不合格处理详情列表
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 不合格处理详情集合
|
||||
*/
|
||||
public List<QcCheckUnqualifiedDetail> selectQcCheckUnqualifiedDetailList(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail);
|
||||
|
||||
/**
|
||||
* 新增不合格处理详情
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertQcCheckUnqualifiedDetail(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail);
|
||||
|
||||
/**
|
||||
* 修改不合格处理详情
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateQcCheckUnqualifiedDetail(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail);
|
||||
|
||||
/**
|
||||
* 删除不合格处理详情
|
||||
*
|
||||
* @param recordId 不合格处理详情主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcCheckUnqualifiedDetailByRecordId(String recordId);
|
||||
|
||||
/**
|
||||
* 批量删除不合格处理详情
|
||||
*
|
||||
* @param recordIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcCheckUnqualifiedDetailByRecordIds(String[] recordIds);
|
||||
}
|
@ -0,0 +1,63 @@
|
||||
package com.op.quality.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.op.quality.domain.QcCheckUnqualified;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
/**
|
||||
* 不合格处理Mapper接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
@Mapper
|
||||
public interface QcCheckUnqualifiedMapper {
|
||||
/**
|
||||
* 查询不合格处理
|
||||
*
|
||||
* @param id 不合格处理主键
|
||||
* @return 不合格处理
|
||||
*/
|
||||
public QcCheckUnqualified selectQcCheckUnqualifiedById(String id);
|
||||
|
||||
/**
|
||||
* 查询不合格处理列表
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 不合格处理集合
|
||||
*/
|
||||
public List<QcCheckUnqualified> selectQcCheckUnqualifiedList(QcCheckUnqualified qcCheckUnqualified);
|
||||
|
||||
/**
|
||||
* 新增不合格处理
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertQcCheckUnqualified(QcCheckUnqualified qcCheckUnqualified);
|
||||
|
||||
/**
|
||||
* 修改不合格处理
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateQcCheckUnqualified(QcCheckUnqualified qcCheckUnqualified);
|
||||
|
||||
/**
|
||||
* 删除不合格处理
|
||||
*
|
||||
* @param id 不合格处理主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcCheckUnqualifiedById(String id);
|
||||
|
||||
/**
|
||||
* 批量删除不合格处理
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcCheckUnqualifiedByIds(String[] ids);
|
||||
}
|
@ -0,0 +1,60 @@
|
||||
package com.op.quality.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.op.quality.domain.QcCheckUnqualifiedDetail;
|
||||
|
||||
/**
|
||||
* 不合格处理详情Service接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
public interface IQcCheckUnqualifiedDetailService {
|
||||
/**
|
||||
* 查询不合格处理详情
|
||||
*
|
||||
* @param recordId 不合格处理详情主键
|
||||
* @return 不合格处理详情
|
||||
*/
|
||||
public QcCheckUnqualifiedDetail selectQcCheckUnqualifiedDetailByRecordId(String recordId);
|
||||
|
||||
/**
|
||||
* 查询不合格处理详情列表
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 不合格处理详情集合
|
||||
*/
|
||||
public List<QcCheckUnqualifiedDetail> selectQcCheckUnqualifiedDetailList(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail);
|
||||
|
||||
/**
|
||||
* 新增不合格处理详情
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertQcCheckUnqualifiedDetail(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail);
|
||||
|
||||
/**
|
||||
* 修改不合格处理详情
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateQcCheckUnqualifiedDetail(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail);
|
||||
|
||||
/**
|
||||
* 批量删除不合格处理详情
|
||||
*
|
||||
* @param recordIds 需要删除的不合格处理详情主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcCheckUnqualifiedDetailByRecordIds(String[] recordIds);
|
||||
|
||||
/**
|
||||
* 删除不合格处理详情信息
|
||||
*
|
||||
* @param recordId 不合格处理详情主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcCheckUnqualifiedDetailByRecordId(String recordId);
|
||||
}
|
@ -0,0 +1,60 @@
|
||||
package com.op.quality.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.op.quality.domain.QcCheckUnqualified;
|
||||
|
||||
/**
|
||||
* 不合格处理Service接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
public interface IQcCheckUnqualifiedService {
|
||||
/**
|
||||
* 查询不合格处理
|
||||
*
|
||||
* @param id 不合格处理主键
|
||||
* @return 不合格处理
|
||||
*/
|
||||
public QcCheckUnqualified selectQcCheckUnqualifiedById(String id);
|
||||
|
||||
/**
|
||||
* 查询不合格处理列表
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 不合格处理集合
|
||||
*/
|
||||
public List<QcCheckUnqualified> selectQcCheckUnqualifiedList(QcCheckUnqualified qcCheckUnqualified);
|
||||
|
||||
/**
|
||||
* 新增不合格处理
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertQcCheckUnqualified(QcCheckUnqualified qcCheckUnqualified);
|
||||
|
||||
/**
|
||||
* 修改不合格处理
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateQcCheckUnqualified(QcCheckUnqualified qcCheckUnqualified);
|
||||
|
||||
/**
|
||||
* 批量删除不合格处理
|
||||
*
|
||||
* @param ids 需要删除的不合格处理主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcCheckUnqualifiedByIds(String[] ids);
|
||||
|
||||
/**
|
||||
* 删除不合格处理信息
|
||||
*
|
||||
* @param id 不合格处理主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcCheckUnqualifiedById(String id);
|
||||
}
|
@ -0,0 +1,89 @@
|
||||
package com.op.quality.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.op.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.op.quality.mapper.QcCheckUnqualifiedDetailMapper;
|
||||
import com.op.quality.domain.QcCheckUnqualifiedDetail;
|
||||
import com.op.quality.service.IQcCheckUnqualifiedDetailService;
|
||||
|
||||
/**
|
||||
* 不合格处理详情Service业务层处理
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
@Service
|
||||
public class QcCheckUnqualifiedDetailServiceImpl implements IQcCheckUnqualifiedDetailService {
|
||||
@Autowired
|
||||
private QcCheckUnqualifiedDetailMapper qcCheckUnqualifiedDetailMapper;
|
||||
|
||||
/**
|
||||
* 查询不合格处理详情
|
||||
*
|
||||
* @param recordId 不合格处理详情主键
|
||||
* @return 不合格处理详情
|
||||
*/
|
||||
@Override
|
||||
public QcCheckUnqualifiedDetail selectQcCheckUnqualifiedDetailByRecordId(String recordId) {
|
||||
return qcCheckUnqualifiedDetailMapper.selectQcCheckUnqualifiedDetailByRecordId(recordId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询不合格处理详情列表
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 不合格处理详情
|
||||
*/
|
||||
@Override
|
||||
public List<QcCheckUnqualifiedDetail> selectQcCheckUnqualifiedDetailList(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail) {
|
||||
return qcCheckUnqualifiedDetailMapper.selectQcCheckUnqualifiedDetailList(qcCheckUnqualifiedDetail);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增不合格处理详情
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertQcCheckUnqualifiedDetail(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail) {
|
||||
qcCheckUnqualifiedDetail.setCreateTime(DateUtils.getNowDate());
|
||||
return qcCheckUnqualifiedDetailMapper.insertQcCheckUnqualifiedDetail(qcCheckUnqualifiedDetail);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改不合格处理详情
|
||||
*
|
||||
* @param qcCheckUnqualifiedDetail 不合格处理详情
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateQcCheckUnqualifiedDetail(QcCheckUnqualifiedDetail qcCheckUnqualifiedDetail) {
|
||||
qcCheckUnqualifiedDetail.setUpdateTime(DateUtils.getNowDate());
|
||||
return qcCheckUnqualifiedDetailMapper.updateQcCheckUnqualifiedDetail(qcCheckUnqualifiedDetail);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除不合格处理详情
|
||||
*
|
||||
* @param recordIds 需要删除的不合格处理详情主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteQcCheckUnqualifiedDetailByRecordIds(String[] recordIds) {
|
||||
return qcCheckUnqualifiedDetailMapper.deleteQcCheckUnqualifiedDetailByRecordIds(recordIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除不合格处理详情信息
|
||||
*
|
||||
* @param recordId 不合格处理详情主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteQcCheckUnqualifiedDetailByRecordId(String recordId) {
|
||||
return qcCheckUnqualifiedDetailMapper.deleteQcCheckUnqualifiedDetailByRecordId(recordId);
|
||||
}
|
||||
}
|
@ -0,0 +1,97 @@
|
||||
package com.op.quality.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.op.common.core.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.op.quality.mapper.QcCheckUnqualifiedMapper;
|
||||
import com.op.quality.domain.QcCheckUnqualified;
|
||||
import com.op.quality.service.IQcCheckUnqualifiedService;
|
||||
|
||||
/**
|
||||
* 不合格处理Service业务层处理
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-10-31
|
||||
*/
|
||||
@Service
|
||||
public class QcCheckUnqualifiedServiceImpl implements IQcCheckUnqualifiedService {
|
||||
@Autowired
|
||||
private QcCheckUnqualifiedMapper qcCheckUnqualifiedMapper;
|
||||
|
||||
/**
|
||||
* 查询不合格处理
|
||||
*
|
||||
* @param id 不合格处理主键
|
||||
* @return 不合格处理
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public QcCheckUnqualified selectQcCheckUnqualifiedById(String id) {
|
||||
return qcCheckUnqualifiedMapper.selectQcCheckUnqualifiedById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询不合格处理列表
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 不合格处理
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public List<QcCheckUnqualified> selectQcCheckUnqualifiedList(QcCheckUnqualified qcCheckUnqualified) {
|
||||
return qcCheckUnqualifiedMapper.selectQcCheckUnqualifiedList(qcCheckUnqualified);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增不合格处理
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int insertQcCheckUnqualified(QcCheckUnqualified qcCheckUnqualified) {
|
||||
qcCheckUnqualified.setCreateTime(DateUtils.getNowDate());
|
||||
return qcCheckUnqualifiedMapper.insertQcCheckUnqualified(qcCheckUnqualified);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改不合格处理
|
||||
*
|
||||
* @param qcCheckUnqualified 不合格处理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int updateQcCheckUnqualified(QcCheckUnqualified qcCheckUnqualified) {
|
||||
qcCheckUnqualified.setUpdateTime(DateUtils.getNowDate());
|
||||
return qcCheckUnqualifiedMapper.updateQcCheckUnqualified(qcCheckUnqualified);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除不合格处理
|
||||
*
|
||||
* @param ids 需要删除的不合格处理主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteQcCheckUnqualifiedByIds(String[] ids) {
|
||||
return qcCheckUnqualifiedMapper.deleteQcCheckUnqualifiedByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除不合格处理信息
|
||||
*
|
||||
* @param id 不合格处理主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteQcCheckUnqualifiedById(String id) {
|
||||
return qcCheckUnqualifiedMapper.deleteQcCheckUnqualifiedById(id);
|
||||
}
|
||||
}
|
@ -0,0 +1,132 @@
|
||||
<?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.op.quality.mapper.QcCheckUnqualifiedDetailMapper">
|
||||
|
||||
<resultMap type="QcCheckUnqualifiedDetail" id="QcCheckUnqualifiedDetailResult">
|
||||
<result property="recordId" column="record_id" />
|
||||
<result property="unqualifiedId" column="unqualified_id" />
|
||||
<result property="sort" column="sort" />
|
||||
<result property="dowithCode" column="dowith_code" />
|
||||
<result property="dowithName" column="dowith_name" />
|
||||
<result property="dowithRemark" column="dowith_remark" />
|
||||
<result property="status" column="status" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="attr1" column="attr1" />
|
||||
<result property="attr2" column="attr2" />
|
||||
<result property="attr3" column="attr3" />
|
||||
<result property="attr4" column="attr4" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="factoryCode" column="factory_code" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectQcCheckUnqualifiedDetailVo">
|
||||
select record_id, unqualified_id, sort, dowith_code, dowith_name, dowith_remark, status, remark, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time, factory_code, del_flag from qc_check_unqualified_detail
|
||||
</sql>
|
||||
|
||||
<select id="selectQcCheckUnqualifiedDetailList" parameterType="QcCheckUnqualifiedDetail" resultMap="QcCheckUnqualifiedDetailResult">
|
||||
<include refid="selectQcCheckUnqualifiedDetailVo"/>
|
||||
<where>
|
||||
<if test="unqualifiedId != null and unqualifiedId != ''"> and unqualified_id = #{unqualifiedId}</if>
|
||||
<if test="sort != null and sort != ''"> and sort = #{sort}</if>
|
||||
<if test="dowithCode != null and dowithCode != ''"> and dowith_code = #{dowithCode}</if>
|
||||
<if test="dowithName != null and dowithName != ''"> and dowith_name like concat('%', #{dowithName}, '%')</if>
|
||||
<if test="dowithRemark != null and dowithRemark != ''"> and dowith_remark = #{dowithRemark}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
<if test="attr1 != null and attr1 != ''"> and attr1 = #{attr1}</if>
|
||||
<if test="attr2 != null and attr2 != ''"> and attr2 = #{attr2}</if>
|
||||
<if test="attr3 != null and attr3 != ''"> and attr3 = #{attr3}</if>
|
||||
<if test="attr4 != null and attr4 != ''"> and attr4 = #{attr4}</if>
|
||||
<if test="factoryCode != null and factoryCode != ''"> and factory_code = #{factoryCode}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectQcCheckUnqualifiedDetailByRecordId" parameterType="String" resultMap="QcCheckUnqualifiedDetailResult">
|
||||
<include refid="selectQcCheckUnqualifiedDetailVo"/>
|
||||
where record_id = #{recordId}
|
||||
</select>
|
||||
|
||||
<insert id="insertQcCheckUnqualifiedDetail" parameterType="QcCheckUnqualifiedDetail">
|
||||
insert into qc_check_unqualified_detail
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="recordId != null">record_id,</if>
|
||||
<if test="unqualifiedId != null">unqualified_id,</if>
|
||||
<if test="sort != null">sort,</if>
|
||||
<if test="dowithCode != null">dowith_code,</if>
|
||||
<if test="dowithName != null">dowith_name,</if>
|
||||
<if test="dowithRemark != null">dowith_remark,</if>
|
||||
<if test="status != null">status,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="attr1 != null">attr1,</if>
|
||||
<if test="attr2 != null">attr2,</if>
|
||||
<if test="attr3 != null">attr3,</if>
|
||||
<if test="attr4 != null">attr4,</if>
|
||||
<if test="createBy != null">create_by,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="updateBy != null">update_by,</if>
|
||||
<if test="updateTime != null">update_time,</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">factory_code,</if>
|
||||
<if test="delFlag != null">del_flag,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="recordId != null">#{recordId},</if>
|
||||
<if test="unqualifiedId != null">#{unqualifiedId},</if>
|
||||
<if test="sort != null">#{sort},</if>
|
||||
<if test="dowithCode != null">#{dowithCode},</if>
|
||||
<if test="dowithName != null">#{dowithName},</if>
|
||||
<if test="dowithRemark != null">#{dowithRemark},</if>
|
||||
<if test="status != null">#{status},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="attr1 != null">#{attr1},</if>
|
||||
<if test="attr2 != null">#{attr2},</if>
|
||||
<if test="attr3 != null">#{attr3},</if>
|
||||
<if test="attr4 != null">#{attr4},</if>
|
||||
<if test="createBy != null">#{createBy},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="updateBy != null">#{updateBy},</if>
|
||||
<if test="updateTime != null">#{updateTime},</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">#{factoryCode},</if>
|
||||
<if test="delFlag != null">#{delFlag},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateQcCheckUnqualifiedDetail" parameterType="QcCheckUnqualifiedDetail">
|
||||
update qc_check_unqualified_detail
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="unqualifiedId != null">unqualified_id = #{unqualifiedId},</if>
|
||||
<if test="sort != null">sort = #{sort},</if>
|
||||
<if test="dowithCode != null">dowith_code = #{dowithCode},</if>
|
||||
<if test="dowithName != null">dowith_name = #{dowithName},</if>
|
||||
<if test="dowithRemark != null">dowith_remark = #{dowithRemark},</if>
|
||||
<if test="status != null">status = #{status},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="attr1 != null">attr1 = #{attr1},</if>
|
||||
<if test="attr2 != null">attr2 = #{attr2},</if>
|
||||
<if test="attr3 != null">attr3 = #{attr3},</if>
|
||||
<if test="attr4 != null">attr4 = #{attr4},</if>
|
||||
<if test="createBy != null">create_by = #{createBy},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">factory_code = #{factoryCode},</if>
|
||||
<if test="delFlag != null">del_flag = #{delFlag},</if>
|
||||
</trim>
|
||||
where record_id = #{recordId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteQcCheckUnqualifiedDetailByRecordId" parameterType="String">
|
||||
delete from qc_check_unqualified_detail where record_id = #{recordId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteQcCheckUnqualifiedDetailByRecordIds" parameterType="String">
|
||||
delete from qc_check_unqualified_detail where record_id in
|
||||
<foreach item="recordId" collection="array" open="(" separator="," close=")">
|
||||
#{recordId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
@ -0,0 +1,127 @@
|
||||
<?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.op.quality.mapper.QcCheckUnqualifiedMapper">
|
||||
|
||||
<resultMap type="QcCheckUnqualified" id="QcCheckUnqualifiedResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="taskId" column="task_id" />
|
||||
<result property="status" column="status" />
|
||||
<result property="nextNodeCode" column="next_node_code" />
|
||||
<result property="nextNodeName" column="next_node_name" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="attr1" column="attr1" />
|
||||
<result property="attr2" column="attr2" />
|
||||
<result property="attr3" column="attr3" />
|
||||
<result property="attr4" column="attr4" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="factoryCode" column="factory_code" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectQcCheckUnqualifiedVo">
|
||||
select id, task_id, status, next_node_code, next_node_name, remark,
|
||||
attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time, factory_code, del_flag
|
||||
from qc_check_unqualified
|
||||
</sql>
|
||||
|
||||
<select id="selectQcCheckUnqualifiedList" parameterType="QcCheckUnqualified" resultMap="QcCheckUnqualifiedResult">
|
||||
<include refid="selectQcCheckUnqualifiedVo"/>
|
||||
<where>
|
||||
<if test="taskId != null and taskId != ''"> and task_id like concat('%', #{taskId}, '%')</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
<if test="nextNodeCode != null and nextNodeCode != ''"> and next_node_code = #{nextNodeCode}</if>
|
||||
<if test="nextNodeName != null and nextNodeName != ''"> and next_node_name like concat('%', #{nextNodeName}, '%')</if>
|
||||
<if test="attr1 != null and attr1 != ''"> and attr1 = #{attr1}</if>
|
||||
<if test="attr2 != null and attr2 != ''"> and attr2 = #{attr2}</if>
|
||||
<if test="attr3 != null and attr3 != ''"> and attr3 = #{attr3}</if>
|
||||
<if test="attr4 != null and attr4 != ''"> and attr4 = #{attr4}</if>
|
||||
and del_flag = #{delFlag}
|
||||
<if test="factoryCode != null and factoryCode != ''"> and factory_code = #{factoryCode}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectQcCheckUnqualifiedById" parameterType="String" resultMap="QcCheckUnqualifiedResult">
|
||||
<include refid="selectQcCheckUnqualifiedVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertQcCheckUnqualified" parameterType="QcCheckUnqualified">
|
||||
insert into qc_check_unqualified
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
<if test="taskId != null">task_id,</if>
|
||||
<if test="status != null">status,</if>
|
||||
<if test="type != null">type,</if>
|
||||
<if test="nextNodeCode != null">next_node_code,</if>
|
||||
<if test="nextNodeName != null">next_node_name,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="attr1 != null">attr1,</if>
|
||||
<if test="attr2 != null">attr2,</if>
|
||||
<if test="attr3 != null">attr3,</if>
|
||||
<if test="attr4 != null">attr4,</if>
|
||||
<if test="createBy != null">create_by,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="updateBy != null">update_by,</if>
|
||||
<if test="updateTime != null">update_time,</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">factory_code,</if>
|
||||
<if test="delFlag != null">del_flag,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">#{id},</if>
|
||||
<if test="taskId != null">#{taskId},</if>
|
||||
<if test="status != null">#{status},</if>
|
||||
<if test="type != null">#{type},</if>
|
||||
<if test="nextNodeCode != null">#{nextNodeCode},</if>
|
||||
<if test="nextNodeName != null">#{nextNodeName},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="attr1 != null">#{attr1},</if>
|
||||
<if test="attr2 != null">#{attr2},</if>
|
||||
<if test="attr3 != null">#{attr3},</if>
|
||||
<if test="attr4 != null">#{attr4},</if>
|
||||
<if test="createBy != null">#{createBy},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="updateBy != null">#{updateBy},</if>
|
||||
<if test="updateTime != null">#{updateTime},</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">#{factoryCode},</if>
|
||||
<if test="delFlag != null">#{delFlag},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateQcCheckUnqualified" parameterType="QcCheckUnqualified">
|
||||
update qc_check_unqualified
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="taskId != null">task_id = #{taskId},</if>
|
||||
<if test="status != null">status = #{status},</if>
|
||||
<if test="nextNodeCode != null">next_node_code = #{nextNodeCode},</if>
|
||||
<if test="nextNodeName != null">next_node_name = #{nextNodeName},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="attr1 != null">attr1 = #{attr1},</if>
|
||||
<if test="attr2 != null">attr2 = #{attr2},</if>
|
||||
<if test="attr3 != null">attr3 = #{attr3},</if>
|
||||
<if test="attr4 != null">attr4 = #{attr4},</if>
|
||||
<if test="createBy != null">create_by = #{createBy},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">factory_code = #{factoryCode},</if>
|
||||
<if test="delFlag != null">del_flag = #{delFlag},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteQcCheckUnqualifiedById" parameterType="String">
|
||||
delete from qc_check_unqualified where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteQcCheckUnqualifiedByIds" parameterType="String">
|
||||
delete from qc_check_unqualified where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
Loading…
Reference in New Issue