备料通知后端功能代码
This commit is contained in:
parent
13aca75b88
commit
5b720be4b9
@ -0,0 +1,104 @@
|
||||
package com.ktg.mes.wm.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
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.ktg.common.annotation.Log;
|
||||
import com.ktg.common.core.controller.BaseController;
|
||||
import com.ktg.common.core.domain.AjaxResult;
|
||||
import com.ktg.common.enums.BusinessType;
|
||||
import com.ktg.mes.wm.domain.WmMaterialrequestNotice;
|
||||
import com.ktg.mes.wm.service.IWmMaterialrequestNoticeService;
|
||||
import com.ktg.common.utils.poi.ExcelUtil;
|
||||
import com.ktg.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 备料通知单Controller
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/mes/wm/mrnotice")
|
||||
public class WmMaterialrequestNoticeController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IWmMaterialrequestNoticeService wmMaterialrequestNoticeService;
|
||||
|
||||
/**
|
||||
* 查询备料通知单列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnotice:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(WmMaterialrequestNotice wmMaterialrequestNotice)
|
||||
{
|
||||
startPage();
|
||||
List<WmMaterialrequestNotice> list = wmMaterialrequestNoticeService.selectWmMaterialrequestNoticeList(wmMaterialrequestNotice);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出备料通知单列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnotice:export')")
|
||||
@Log(title = "备料通知单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, WmMaterialrequestNotice wmMaterialrequestNotice)
|
||||
{
|
||||
List<WmMaterialrequestNotice> list = wmMaterialrequestNoticeService.selectWmMaterialrequestNoticeList(wmMaterialrequestNotice);
|
||||
ExcelUtil<WmMaterialrequestNotice> util = new ExcelUtil<WmMaterialrequestNotice>(WmMaterialrequestNotice.class);
|
||||
util.exportExcel(response, list, "备料通知单数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取备料通知单详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnotice:query')")
|
||||
@GetMapping(value = "/{noticeId}")
|
||||
public AjaxResult getInfo(@PathVariable("noticeId") Long noticeId)
|
||||
{
|
||||
return AjaxResult.success(wmMaterialrequestNoticeService.selectWmMaterialrequestNoticeByNoticeId(noticeId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增备料通知单
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnotice:add')")
|
||||
@Log(title = "备料通知单", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody WmMaterialrequestNotice wmMaterialrequestNotice)
|
||||
{
|
||||
return toAjax(wmMaterialrequestNoticeService.insertWmMaterialrequestNotice(wmMaterialrequestNotice));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改备料通知单
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnotice:edit')")
|
||||
@Log(title = "备料通知单", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody WmMaterialrequestNotice wmMaterialrequestNotice)
|
||||
{
|
||||
return toAjax(wmMaterialrequestNoticeService.updateWmMaterialrequestNotice(wmMaterialrequestNotice));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除备料通知单
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnotice:remove')")
|
||||
@Log(title = "备料通知单", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{noticeIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] noticeIds)
|
||||
{
|
||||
return toAjax(wmMaterialrequestNoticeService.deleteWmMaterialrequestNoticeByNoticeIds(noticeIds));
|
||||
}
|
||||
}
|
@ -0,0 +1,104 @@
|
||||
package com.ktg.mes.wm.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
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.ktg.common.annotation.Log;
|
||||
import com.ktg.common.core.controller.BaseController;
|
||||
import com.ktg.common.core.domain.AjaxResult;
|
||||
import com.ktg.common.enums.BusinessType;
|
||||
import com.ktg.mes.wm.domain.WmMaterialrequestNoticeLine;
|
||||
import com.ktg.mes.wm.service.IWmMaterialrequestNoticeLineService;
|
||||
import com.ktg.common.utils.poi.ExcelUtil;
|
||||
import com.ktg.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 备料通知单明细Controller
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/mes/wm/mrnoticeline")
|
||||
public class WmMaterialrequestNoticeLineController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IWmMaterialrequestNoticeLineService wmMaterialrequestNoticeLineService;
|
||||
|
||||
/**
|
||||
* 查询备料通知单明细列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnoticeline:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine)
|
||||
{
|
||||
startPage();
|
||||
List<WmMaterialrequestNoticeLine> list = wmMaterialrequestNoticeLineService.selectWmMaterialrequestNoticeLineList(wmMaterialrequestNoticeLine);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出备料通知单明细列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnoticeline:export')")
|
||||
@Log(title = "备料通知单明细", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine)
|
||||
{
|
||||
List<WmMaterialrequestNoticeLine> list = wmMaterialrequestNoticeLineService.selectWmMaterialrequestNoticeLineList(wmMaterialrequestNoticeLine);
|
||||
ExcelUtil<WmMaterialrequestNoticeLine> util = new ExcelUtil<WmMaterialrequestNoticeLine>(WmMaterialrequestNoticeLine.class);
|
||||
util.exportExcel(response, list, "备料通知单明细数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取备料通知单明细详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnoticeline:query')")
|
||||
@GetMapping(value = "/{lineId}")
|
||||
public AjaxResult getInfo(@PathVariable("lineId") Long lineId)
|
||||
{
|
||||
return AjaxResult.success(wmMaterialrequestNoticeLineService.selectWmMaterialrequestNoticeLineByLineId(lineId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增备料通知单明细
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnoticeline:add')")
|
||||
@Log(title = "备料通知单明细", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine)
|
||||
{
|
||||
return toAjax(wmMaterialrequestNoticeLineService.insertWmMaterialrequestNoticeLine(wmMaterialrequestNoticeLine));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改备料通知单明细
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnoticeline:edit')")
|
||||
@Log(title = "备料通知单明细", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine)
|
||||
{
|
||||
return toAjax(wmMaterialrequestNoticeLineService.updateWmMaterialrequestNoticeLine(wmMaterialrequestNoticeLine));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除备料通知单明细
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('wm:mrnoticeline:remove')")
|
||||
@Log(title = "备料通知单明细", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{lineIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] lineIds)
|
||||
{
|
||||
return toAjax(wmMaterialrequestNoticeLineService.deleteWmMaterialrequestNoticeLineByLineIds(lineIds));
|
||||
}
|
||||
}
|
@ -0,0 +1,336 @@
|
||||
package com.ktg.mes.wm.domain;
|
||||
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ktg.common.annotation.Excel;
|
||||
import com.ktg.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 备料通知单对象 wm_materialrequest_notice
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
public class WmMaterialrequestNotice extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 通知ID */
|
||||
private Long noticeId;
|
||||
|
||||
/** 工作站ID */
|
||||
@Excel(name = "工作站ID")
|
||||
private Long workstationId;
|
||||
|
||||
/** 工作站编号 */
|
||||
@Excel(name = "工作站编号")
|
||||
private String workstaitonCode;
|
||||
|
||||
/** 生产工单ID */
|
||||
@Excel(name = "生产工单ID")
|
||||
private Long workorderId;
|
||||
|
||||
/** 生产工单编号 */
|
||||
@Excel(name = "生产工单编号")
|
||||
private String workorderCode;
|
||||
|
||||
/** 需求人 */
|
||||
@Excel(name = "需求人")
|
||||
private Long userId;
|
||||
|
||||
/** 用户名 */
|
||||
@Excel(name = "用户名")
|
||||
private String userName;
|
||||
|
||||
/** 昵称 */
|
||||
@Excel(name = "昵称")
|
||||
private String nickName;
|
||||
|
||||
/** 需求时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "需求时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date requestTime;
|
||||
|
||||
/** 开始备料时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "开始备料时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date startTime;
|
||||
|
||||
/** 完成时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date endTime;
|
||||
|
||||
|
||||
private Long itemId;
|
||||
|
||||
/** 产品物料编码 */
|
||||
@Excel(name = "产品物料编码")
|
||||
private String itemCode;
|
||||
|
||||
/** 产品物料名称 */
|
||||
@Excel(name = "产品物料名称")
|
||||
private String itemName;
|
||||
|
||||
/** 规格型号 */
|
||||
@Excel(name = "规格型号")
|
||||
private String specification;
|
||||
|
||||
/** 单位 */
|
||||
@Excel(name = "单位")
|
||||
private String unitOfMeasure;
|
||||
|
||||
/** 单位名称 */
|
||||
@Excel(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
/** 需求数量 */
|
||||
@Excel(name = "需求数量")
|
||||
private Long quantity;
|
||||
|
||||
/** 状态 */
|
||||
@Excel(name = "状态")
|
||||
private String status;
|
||||
|
||||
/** 预留字段1 */
|
||||
private String attr1;
|
||||
|
||||
/** 预留字段2 */
|
||||
private String attr2;
|
||||
|
||||
/** 预留字段3 */
|
||||
private Long attr3;
|
||||
|
||||
/** 预留字段4 */
|
||||
private Long attr4;
|
||||
|
||||
public void setNoticeId(Long noticeId)
|
||||
{
|
||||
this.noticeId = noticeId;
|
||||
}
|
||||
|
||||
public Long getNoticeId()
|
||||
{
|
||||
return noticeId;
|
||||
}
|
||||
public void setWorkstationId(Long workstationId)
|
||||
{
|
||||
this.workstationId = workstationId;
|
||||
}
|
||||
|
||||
public Long getWorkstationId()
|
||||
{
|
||||
return workstationId;
|
||||
}
|
||||
public void setWorkstaitonCode(String workstaitonCode)
|
||||
{
|
||||
this.workstaitonCode = workstaitonCode;
|
||||
}
|
||||
|
||||
public String getWorkstaitonCode()
|
||||
{
|
||||
return workstaitonCode;
|
||||
}
|
||||
public void setWorkorderId(Long workorderId)
|
||||
{
|
||||
this.workorderId = workorderId;
|
||||
}
|
||||
|
||||
public Long getWorkorderId()
|
||||
{
|
||||
return workorderId;
|
||||
}
|
||||
public void setWorkorderCode(String workorderCode)
|
||||
{
|
||||
this.workorderCode = workorderCode;
|
||||
}
|
||||
|
||||
public String getWorkorderCode()
|
||||
{
|
||||
return workorderCode;
|
||||
}
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
public void setUserName(String userName)
|
||||
{
|
||||
this.userName = userName;
|
||||
}
|
||||
|
||||
public String getUserName()
|
||||
{
|
||||
return userName;
|
||||
}
|
||||
public void setNickName(String nickName)
|
||||
{
|
||||
this.nickName = nickName;
|
||||
}
|
||||
|
||||
public String getNickName()
|
||||
{
|
||||
return nickName;
|
||||
}
|
||||
public void setRequestTime(Date requestTime)
|
||||
{
|
||||
this.requestTime = requestTime;
|
||||
}
|
||||
|
||||
public Date getRequestTime()
|
||||
{
|
||||
return requestTime;
|
||||
}
|
||||
public void setStartTime(Date startTime)
|
||||
{
|
||||
this.startTime = startTime;
|
||||
}
|
||||
|
||||
public Date getStartTime()
|
||||
{
|
||||
return startTime;
|
||||
}
|
||||
public void setEndTime(Date endTime)
|
||||
{
|
||||
this.endTime = endTime;
|
||||
}
|
||||
|
||||
public Date getEndTime()
|
||||
{
|
||||
return endTime;
|
||||
}
|
||||
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(Long attr3)
|
||||
{
|
||||
this.attr3 = attr3;
|
||||
}
|
||||
|
||||
public Long getAttr3()
|
||||
{
|
||||
return attr3;
|
||||
}
|
||||
public void setAttr4(Long attr4)
|
||||
{
|
||||
this.attr4 = attr4;
|
||||
}
|
||||
|
||||
public Long getAttr4()
|
||||
{
|
||||
return attr4;
|
||||
}
|
||||
|
||||
public Long getItemId() {
|
||||
return itemId;
|
||||
}
|
||||
|
||||
public void setItemId(Long itemId) {
|
||||
this.itemId = itemId;
|
||||
}
|
||||
|
||||
public String getItemCode() {
|
||||
return itemCode;
|
||||
}
|
||||
|
||||
public void setItemCode(String itemCode) {
|
||||
this.itemCode = itemCode;
|
||||
}
|
||||
|
||||
public String getItemName() {
|
||||
return itemName;
|
||||
}
|
||||
|
||||
public void setItemName(String itemName) {
|
||||
this.itemName = itemName;
|
||||
}
|
||||
|
||||
public String getSpecification() {
|
||||
return specification;
|
||||
}
|
||||
|
||||
public void setSpecification(String specification) {
|
||||
this.specification = specification;
|
||||
}
|
||||
|
||||
public String getUnitOfMeasure() {
|
||||
return unitOfMeasure;
|
||||
}
|
||||
|
||||
public void setUnitOfMeasure(String unitOfMeasure) {
|
||||
this.unitOfMeasure = unitOfMeasure;
|
||||
}
|
||||
|
||||
public String getUnitName() {
|
||||
return unitName;
|
||||
}
|
||||
|
||||
public void setUnitName(String unitName) {
|
||||
this.unitName = unitName;
|
||||
}
|
||||
|
||||
public Long getQuantity() {
|
||||
return quantity;
|
||||
}
|
||||
|
||||
public void setQuantity(Long quantity) {
|
||||
this.quantity = quantity;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("noticeId", getNoticeId())
|
||||
.append("workstationId", getWorkstationId())
|
||||
.append("workstaitonCode", getWorkstaitonCode())
|
||||
.append("workorderId", getWorkorderId())
|
||||
.append("workorderCode", getWorkorderCode())
|
||||
.append("userId", getUserId())
|
||||
.append("userName", getUserName())
|
||||
.append("nickName", getNickName())
|
||||
.append("requestTime", getRequestTime())
|
||||
.append("startTime", getStartTime())
|
||||
.append("endTime", getEndTime())
|
||||
.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())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,206 @@
|
||||
package com.ktg.mes.wm.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ktg.common.annotation.Excel;
|
||||
import com.ktg.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 备料通知单明细对象 wm_materialrequest_notice_line
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
public class WmMaterialrequestNoticeLine extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 行ID */
|
||||
private Long lineId;
|
||||
|
||||
/** 通知ID */
|
||||
@Excel(name = "通知ID")
|
||||
private Long noticeId;
|
||||
|
||||
/** 产品物料ID */
|
||||
@Excel(name = "产品物料ID")
|
||||
private Long itemId;
|
||||
|
||||
/** 产品物料编码 */
|
||||
@Excel(name = "产品物料编码")
|
||||
private String itemCode;
|
||||
|
||||
/** 产品物料名称 */
|
||||
@Excel(name = "产品物料名称")
|
||||
private String itemName;
|
||||
|
||||
/** 规格型号 */
|
||||
@Excel(name = "规格型号")
|
||||
private String specification;
|
||||
|
||||
/** 单位 */
|
||||
@Excel(name = "单位")
|
||||
private String unitOfMeasure;
|
||||
|
||||
/** 单位名称 */
|
||||
@Excel(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
/** 需求数量 */
|
||||
@Excel(name = "需求数量")
|
||||
private Long quantity;
|
||||
|
||||
/** 预留字段1 */
|
||||
private String attr1;
|
||||
|
||||
/** 预留字段2 */
|
||||
private String attr2;
|
||||
|
||||
/** 预留字段3 */
|
||||
private Long attr3;
|
||||
|
||||
/** 预留字段4 */
|
||||
private Long attr4;
|
||||
|
||||
public void setLineId(Long lineId)
|
||||
{
|
||||
this.lineId = lineId;
|
||||
}
|
||||
|
||||
public Long getLineId()
|
||||
{
|
||||
return lineId;
|
||||
}
|
||||
public void setNoticeId(Long noticeId)
|
||||
{
|
||||
this.noticeId = noticeId;
|
||||
}
|
||||
|
||||
public Long getNoticeId()
|
||||
{
|
||||
return noticeId;
|
||||
}
|
||||
public void setItemId(Long itemId)
|
||||
{
|
||||
this.itemId = itemId;
|
||||
}
|
||||
|
||||
public Long getItemId()
|
||||
{
|
||||
return itemId;
|
||||
}
|
||||
public void setItemCode(String itemCode)
|
||||
{
|
||||
this.itemCode = itemCode;
|
||||
}
|
||||
|
||||
public String getItemCode()
|
||||
{
|
||||
return itemCode;
|
||||
}
|
||||
public void setItemName(String itemName)
|
||||
{
|
||||
this.itemName = itemName;
|
||||
}
|
||||
|
||||
public String getItemName()
|
||||
{
|
||||
return itemName;
|
||||
}
|
||||
public void setSpecification(String specification)
|
||||
{
|
||||
this.specification = specification;
|
||||
}
|
||||
|
||||
public String getSpecification()
|
||||
{
|
||||
return specification;
|
||||
}
|
||||
public void setUnitOfMeasure(String unitOfMeasure)
|
||||
{
|
||||
this.unitOfMeasure = unitOfMeasure;
|
||||
}
|
||||
|
||||
public String getUnitOfMeasure()
|
||||
{
|
||||
return unitOfMeasure;
|
||||
}
|
||||
public void setUnitName(String unitName)
|
||||
{
|
||||
this.unitName = unitName;
|
||||
}
|
||||
|
||||
public String getUnitName()
|
||||
{
|
||||
return unitName;
|
||||
}
|
||||
public void setQuantity(Long quantity)
|
||||
{
|
||||
this.quantity = quantity;
|
||||
}
|
||||
|
||||
public Long getQuantity()
|
||||
{
|
||||
return quantity;
|
||||
}
|
||||
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(Long attr3)
|
||||
{
|
||||
this.attr3 = attr3;
|
||||
}
|
||||
|
||||
public Long getAttr3()
|
||||
{
|
||||
return attr3;
|
||||
}
|
||||
public void setAttr4(Long attr4)
|
||||
{
|
||||
this.attr4 = attr4;
|
||||
}
|
||||
|
||||
public Long getAttr4()
|
||||
{
|
||||
return attr4;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("lineId", getLineId())
|
||||
.append("noticeId", getNoticeId())
|
||||
.append("itemId", getItemId())
|
||||
.append("itemCode", getItemCode())
|
||||
.append("itemName", getItemName())
|
||||
.append("specification", getSpecification())
|
||||
.append("unitOfMeasure", getUnitOfMeasure())
|
||||
.append("unitName", getUnitName())
|
||||
.append("quantity", getQuantity())
|
||||
.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())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.ktg.mes.wm.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ktg.mes.wm.domain.WmMaterialrequestNoticeLine;
|
||||
|
||||
/**
|
||||
* 备料通知单明细Mapper接口
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
public interface WmMaterialrequestNoticeLineMapper
|
||||
{
|
||||
/**
|
||||
* 查询备料通知单明细
|
||||
*
|
||||
* @param lineId 备料通知单明细主键
|
||||
* @return 备料通知单明细
|
||||
*/
|
||||
public WmMaterialrequestNoticeLine selectWmMaterialrequestNoticeLineByLineId(Long lineId);
|
||||
|
||||
/**
|
||||
* 查询备料通知单明细列表
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 备料通知单明细集合
|
||||
*/
|
||||
public List<WmMaterialrequestNoticeLine> selectWmMaterialrequestNoticeLineList(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine);
|
||||
|
||||
/**
|
||||
* 新增备料通知单明细
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWmMaterialrequestNoticeLine(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine);
|
||||
|
||||
/**
|
||||
* 修改备料通知单明细
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWmMaterialrequestNoticeLine(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine);
|
||||
|
||||
/**
|
||||
* 删除备料通知单明细
|
||||
*
|
||||
* @param lineId 备料通知单明细主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmMaterialrequestNoticeLineByLineId(Long lineId);
|
||||
|
||||
/**
|
||||
* 批量删除备料通知单明细
|
||||
*
|
||||
* @param lineIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmMaterialrequestNoticeLineByLineIds(Long[] lineIds);
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.ktg.mes.wm.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ktg.mes.wm.domain.WmMaterialrequestNotice;
|
||||
|
||||
/**
|
||||
* 备料通知单Mapper接口
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
public interface WmMaterialrequestNoticeMapper
|
||||
{
|
||||
/**
|
||||
* 查询备料通知单
|
||||
*
|
||||
* @param noticeId 备料通知单主键
|
||||
* @return 备料通知单
|
||||
*/
|
||||
public WmMaterialrequestNotice selectWmMaterialrequestNoticeByNoticeId(Long noticeId);
|
||||
|
||||
/**
|
||||
* 查询备料通知单列表
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 备料通知单集合
|
||||
*/
|
||||
public List<WmMaterialrequestNotice> selectWmMaterialrequestNoticeList(WmMaterialrequestNotice wmMaterialrequestNotice);
|
||||
|
||||
/**
|
||||
* 新增备料通知单
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWmMaterialrequestNotice(WmMaterialrequestNotice wmMaterialrequestNotice);
|
||||
|
||||
/**
|
||||
* 修改备料通知单
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWmMaterialrequestNotice(WmMaterialrequestNotice wmMaterialrequestNotice);
|
||||
|
||||
/**
|
||||
* 删除备料通知单
|
||||
*
|
||||
* @param noticeId 备料通知单主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmMaterialrequestNoticeByNoticeId(Long noticeId);
|
||||
|
||||
/**
|
||||
* 批量删除备料通知单
|
||||
*
|
||||
* @param noticeIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmMaterialrequestNoticeByNoticeIds(Long[] noticeIds);
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.ktg.mes.wm.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ktg.mes.wm.domain.WmMaterialrequestNoticeLine;
|
||||
|
||||
/**
|
||||
* 备料通知单明细Service接口
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
public interface IWmMaterialrequestNoticeLineService
|
||||
{
|
||||
/**
|
||||
* 查询备料通知单明细
|
||||
*
|
||||
* @param lineId 备料通知单明细主键
|
||||
* @return 备料通知单明细
|
||||
*/
|
||||
public WmMaterialrequestNoticeLine selectWmMaterialrequestNoticeLineByLineId(Long lineId);
|
||||
|
||||
/**
|
||||
* 查询备料通知单明细列表
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 备料通知单明细集合
|
||||
*/
|
||||
public List<WmMaterialrequestNoticeLine> selectWmMaterialrequestNoticeLineList(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine);
|
||||
|
||||
/**
|
||||
* 新增备料通知单明细
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWmMaterialrequestNoticeLine(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine);
|
||||
|
||||
/**
|
||||
* 修改备料通知单明细
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWmMaterialrequestNoticeLine(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine);
|
||||
|
||||
/**
|
||||
* 批量删除备料通知单明细
|
||||
*
|
||||
* @param lineIds 需要删除的备料通知单明细主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmMaterialrequestNoticeLineByLineIds(Long[] lineIds);
|
||||
|
||||
/**
|
||||
* 删除备料通知单明细信息
|
||||
*
|
||||
* @param lineId 备料通知单明细主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmMaterialrequestNoticeLineByLineId(Long lineId);
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.ktg.mes.wm.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ktg.mes.wm.domain.WmMaterialrequestNotice;
|
||||
|
||||
/**
|
||||
* 备料通知单Service接口
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
public interface IWmMaterialrequestNoticeService
|
||||
{
|
||||
/**
|
||||
* 查询备料通知单
|
||||
*
|
||||
* @param noticeId 备料通知单主键
|
||||
* @return 备料通知单
|
||||
*/
|
||||
public WmMaterialrequestNotice selectWmMaterialrequestNoticeByNoticeId(Long noticeId);
|
||||
|
||||
/**
|
||||
* 查询备料通知单列表
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 备料通知单集合
|
||||
*/
|
||||
public List<WmMaterialrequestNotice> selectWmMaterialrequestNoticeList(WmMaterialrequestNotice wmMaterialrequestNotice);
|
||||
|
||||
/**
|
||||
* 新增备料通知单
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWmMaterialrequestNotice(WmMaterialrequestNotice wmMaterialrequestNotice);
|
||||
|
||||
/**
|
||||
* 修改备料通知单
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWmMaterialrequestNotice(WmMaterialrequestNotice wmMaterialrequestNotice);
|
||||
|
||||
/**
|
||||
* 批量删除备料通知单
|
||||
*
|
||||
* @param noticeIds 需要删除的备料通知单主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmMaterialrequestNoticeByNoticeIds(Long[] noticeIds);
|
||||
|
||||
/**
|
||||
* 删除备料通知单信息
|
||||
*
|
||||
* @param noticeId 备料通知单主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmMaterialrequestNoticeByNoticeId(Long noticeId);
|
||||
}
|
@ -0,0 +1,96 @@
|
||||
package com.ktg.mes.wm.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ktg.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ktg.mes.wm.mapper.WmMaterialrequestNoticeLineMapper;
|
||||
import com.ktg.mes.wm.domain.WmMaterialrequestNoticeLine;
|
||||
import com.ktg.mes.wm.service.IWmMaterialrequestNoticeLineService;
|
||||
|
||||
/**
|
||||
* 备料通知单明细Service业务层处理
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
@Service
|
||||
public class WmMaterialrequestNoticeLineServiceImpl implements IWmMaterialrequestNoticeLineService
|
||||
{
|
||||
@Autowired
|
||||
private WmMaterialrequestNoticeLineMapper wmMaterialrequestNoticeLineMapper;
|
||||
|
||||
/**
|
||||
* 查询备料通知单明细
|
||||
*
|
||||
* @param lineId 备料通知单明细主键
|
||||
* @return 备料通知单明细
|
||||
*/
|
||||
@Override
|
||||
public WmMaterialrequestNoticeLine selectWmMaterialrequestNoticeLineByLineId(Long lineId)
|
||||
{
|
||||
return wmMaterialrequestNoticeLineMapper.selectWmMaterialrequestNoticeLineByLineId(lineId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询备料通知单明细列表
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 备料通知单明细
|
||||
*/
|
||||
@Override
|
||||
public List<WmMaterialrequestNoticeLine> selectWmMaterialrequestNoticeLineList(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine)
|
||||
{
|
||||
return wmMaterialrequestNoticeLineMapper.selectWmMaterialrequestNoticeLineList(wmMaterialrequestNoticeLine);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增备料通知单明细
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertWmMaterialrequestNoticeLine(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine)
|
||||
{
|
||||
wmMaterialrequestNoticeLine.setCreateTime(DateUtils.getNowDate());
|
||||
return wmMaterialrequestNoticeLineMapper.insertWmMaterialrequestNoticeLine(wmMaterialrequestNoticeLine);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改备料通知单明细
|
||||
*
|
||||
* @param wmMaterialrequestNoticeLine 备料通知单明细
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateWmMaterialrequestNoticeLine(WmMaterialrequestNoticeLine wmMaterialrequestNoticeLine)
|
||||
{
|
||||
wmMaterialrequestNoticeLine.setUpdateTime(DateUtils.getNowDate());
|
||||
return wmMaterialrequestNoticeLineMapper.updateWmMaterialrequestNoticeLine(wmMaterialrequestNoticeLine);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除备料通知单明细
|
||||
*
|
||||
* @param lineIds 需要删除的备料通知单明细主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteWmMaterialrequestNoticeLineByLineIds(Long[] lineIds)
|
||||
{
|
||||
return wmMaterialrequestNoticeLineMapper.deleteWmMaterialrequestNoticeLineByLineIds(lineIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除备料通知单明细信息
|
||||
*
|
||||
* @param lineId 备料通知单明细主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteWmMaterialrequestNoticeLineByLineId(Long lineId)
|
||||
{
|
||||
return wmMaterialrequestNoticeLineMapper.deleteWmMaterialrequestNoticeLineByLineId(lineId);
|
||||
}
|
||||
}
|
@ -0,0 +1,96 @@
|
||||
package com.ktg.mes.wm.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ktg.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ktg.mes.wm.mapper.WmMaterialrequestNoticeMapper;
|
||||
import com.ktg.mes.wm.domain.WmMaterialrequestNotice;
|
||||
import com.ktg.mes.wm.service.IWmMaterialrequestNoticeService;
|
||||
|
||||
/**
|
||||
* 备料通知单Service业务层处理
|
||||
*
|
||||
* @author yinjinlu
|
||||
* @date 2024-12-13
|
||||
*/
|
||||
@Service
|
||||
public class WmMaterialrequestNoticeServiceImpl implements IWmMaterialrequestNoticeService
|
||||
{
|
||||
@Autowired
|
||||
private WmMaterialrequestNoticeMapper wmMaterialrequestNoticeMapper;
|
||||
|
||||
/**
|
||||
* 查询备料通知单
|
||||
*
|
||||
* @param noticeId 备料通知单主键
|
||||
* @return 备料通知单
|
||||
*/
|
||||
@Override
|
||||
public WmMaterialrequestNotice selectWmMaterialrequestNoticeByNoticeId(Long noticeId)
|
||||
{
|
||||
return wmMaterialrequestNoticeMapper.selectWmMaterialrequestNoticeByNoticeId(noticeId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询备料通知单列表
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 备料通知单
|
||||
*/
|
||||
@Override
|
||||
public List<WmMaterialrequestNotice> selectWmMaterialrequestNoticeList(WmMaterialrequestNotice wmMaterialrequestNotice)
|
||||
{
|
||||
return wmMaterialrequestNoticeMapper.selectWmMaterialrequestNoticeList(wmMaterialrequestNotice);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增备料通知单
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertWmMaterialrequestNotice(WmMaterialrequestNotice wmMaterialrequestNotice)
|
||||
{
|
||||
wmMaterialrequestNotice.setCreateTime(DateUtils.getNowDate());
|
||||
return wmMaterialrequestNoticeMapper.insertWmMaterialrequestNotice(wmMaterialrequestNotice);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改备料通知单
|
||||
*
|
||||
* @param wmMaterialrequestNotice 备料通知单
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateWmMaterialrequestNotice(WmMaterialrequestNotice wmMaterialrequestNotice)
|
||||
{
|
||||
wmMaterialrequestNotice.setUpdateTime(DateUtils.getNowDate());
|
||||
return wmMaterialrequestNoticeMapper.updateWmMaterialrequestNotice(wmMaterialrequestNotice);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除备料通知单
|
||||
*
|
||||
* @param noticeIds 需要删除的备料通知单主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteWmMaterialrequestNoticeByNoticeIds(Long[] noticeIds)
|
||||
{
|
||||
return wmMaterialrequestNoticeMapper.deleteWmMaterialrequestNoticeByNoticeIds(noticeIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除备料通知单信息
|
||||
*
|
||||
* @param noticeId 备料通知单主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteWmMaterialrequestNoticeByNoticeId(Long noticeId)
|
||||
{
|
||||
return wmMaterialrequestNoticeMapper.deleteWmMaterialrequestNoticeByNoticeId(noticeId);
|
||||
}
|
||||
}
|
@ -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.ktg.mes.wm.mapper.WmMaterialrequestNoticeLineMapper">
|
||||
|
||||
<resultMap type="WmMaterialrequestNoticeLine" id="WmMaterialrequestNoticeLineResult">
|
||||
<result property="lineId" column="line_id" />
|
||||
<result property="noticeId" column="notice_id" />
|
||||
<result property="itemId" column="item_id" />
|
||||
<result property="itemCode" column="item_code" />
|
||||
<result property="itemName" column="item_name" />
|
||||
<result property="specification" column="specification" />
|
||||
<result property="unitOfMeasure" column="unit_of_measure" />
|
||||
<result property="unitName" column="unit_name" />
|
||||
<result property="quantity" column="quantity" />
|
||||
<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" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectWmMaterialrequestNoticeLineVo">
|
||||
select line_id, notice_id, item_id, item_code, item_name, specification, unit_of_measure, unit_name, quantity, remark, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time from wm_materialrequest_notice_line
|
||||
</sql>
|
||||
|
||||
<select id="selectWmMaterialrequestNoticeLineList" parameterType="WmMaterialrequestNoticeLine" resultMap="WmMaterialrequestNoticeLineResult">
|
||||
<include refid="selectWmMaterialrequestNoticeLineVo"/>
|
||||
<where>
|
||||
<if test="noticeId != null "> and notice_id = #{noticeId}</if>
|
||||
<if test="itemId != null "> and item_id = #{itemId}</if>
|
||||
<if test="itemCode != null and itemCode != ''"> and item_code = #{itemCode}</if>
|
||||
<if test="itemName != null and itemName != ''"> and item_name like concat('%', #{itemName}, '%')</if>
|
||||
<if test="specification != null and specification != ''"> and specification = #{specification}</if>
|
||||
<if test="unitOfMeasure != null and unitOfMeasure != ''"> and unit_of_measure = #{unitOfMeasure}</if>
|
||||
<if test="unitName != null and unitName != ''"> and unit_name like concat('%', #{unitName}, '%')</if>
|
||||
<if test="quantity != null "> and quantity = #{quantity}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectWmMaterialrequestNoticeLineByLineId" parameterType="Long" resultMap="WmMaterialrequestNoticeLineResult">
|
||||
<include refid="selectWmMaterialrequestNoticeLineVo"/>
|
||||
where line_id = #{lineId}
|
||||
</select>
|
||||
|
||||
<insert id="insertWmMaterialrequestNoticeLine" parameterType="WmMaterialrequestNoticeLine" useGeneratedKeys="true" keyProperty="lineId">
|
||||
insert into wm_materialrequest_notice_line
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="noticeId != null">notice_id,</if>
|
||||
<if test="itemId != null">item_id,</if>
|
||||
<if test="itemCode != null">item_code,</if>
|
||||
<if test="itemName != null">item_name,</if>
|
||||
<if test="specification != null">specification,</if>
|
||||
<if test="unitOfMeasure != null">unit_of_measure,</if>
|
||||
<if test="unitName != null">unit_name,</if>
|
||||
<if test="quantity != null">quantity,</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>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="noticeId != null">#{noticeId},</if>
|
||||
<if test="itemId != null">#{itemId},</if>
|
||||
<if test="itemCode != null">#{itemCode},</if>
|
||||
<if test="itemName != null">#{itemName},</if>
|
||||
<if test="specification != null">#{specification},</if>
|
||||
<if test="unitOfMeasure != null">#{unitOfMeasure},</if>
|
||||
<if test="unitName != null">#{unitName},</if>
|
||||
<if test="quantity != null">#{quantity},</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>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateWmMaterialrequestNoticeLine" parameterType="WmMaterialrequestNoticeLine">
|
||||
update wm_materialrequest_notice_line
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="noticeId != null">notice_id = #{noticeId},</if>
|
||||
<if test="itemId != null">item_id = #{itemId},</if>
|
||||
<if test="itemCode != null">item_code = #{itemCode},</if>
|
||||
<if test="itemName != null">item_name = #{itemName},</if>
|
||||
<if test="specification != null">specification = #{specification},</if>
|
||||
<if test="unitOfMeasure != null">unit_of_measure = #{unitOfMeasure},</if>
|
||||
<if test="unitName != null">unit_name = #{unitName},</if>
|
||||
<if test="quantity != null">quantity = #{quantity},</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>
|
||||
</trim>
|
||||
where line_id = #{lineId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteWmMaterialrequestNoticeLineByLineId" parameterType="Long">
|
||||
delete from wm_materialrequest_notice_line where line_id = #{lineId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteWmMaterialrequestNoticeLineByLineIds" parameterType="String">
|
||||
delete from wm_materialrequest_notice_line where line_id in
|
||||
<foreach item="lineId" collection="array" open="(" separator="," close=")">
|
||||
#{lineId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
@ -0,0 +1,142 @@
|
||||
<?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.ktg.mes.wm.mapper.WmMaterialrequestNoticeMapper">
|
||||
|
||||
<resultMap type="WmMaterialrequestNotice" id="WmMaterialrequestNoticeResult">
|
||||
<result property="noticeId" column="notice_id" />
|
||||
<result property="workstationId" column="workstation_id" />
|
||||
<result property="workstaitonCode" column="workstaiton_code" />
|
||||
<result property="workorderId" column="workorder_id" />
|
||||
<result property="workorderCode" column="workorder_code" />
|
||||
<result property="userId" column="user_id" />
|
||||
<result property="userName" column="user_name" />
|
||||
<result property="nickName" column="nick_name" />
|
||||
<result property="requestTime" column="request_time" />
|
||||
<result property="startTime" column="start_time" />
|
||||
<result property="endTime" column="end_time" />
|
||||
<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" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectWmMaterialrequestNoticeVo">
|
||||
select notice_id, workstation_id, workstaiton_code, workorder_id, workorder_code, user_id, user_name, nick_name, request_time, start_time, end_time, status, remark, attr1, attr2, attr3, attr4, create_by, create_time, update_by, update_time from wm_materialrequest_notice
|
||||
</sql>
|
||||
|
||||
<select id="selectWmMaterialrequestNoticeList" parameterType="WmMaterialrequestNotice" resultMap="WmMaterialrequestNoticeResult">
|
||||
<include refid="selectWmMaterialrequestNoticeVo"/>
|
||||
<where>
|
||||
<if test="workstationId != null "> and workstation_id = #{workstationId}</if>
|
||||
<if test="workstaitonCode != null and workstaitonCode != ''"> and workstaiton_code = #{workstaitonCode}</if>
|
||||
<if test="workorderId != null "> and workorder_id = #{workorderId}</if>
|
||||
<if test="workorderCode != null and workorderCode != ''"> and workorder_code = #{workorderCode}</if>
|
||||
<if test="userId != null "> and user_id = #{userId}</if>
|
||||
<if test="userName != null and userName != ''"> and user_name like concat('%', #{userName}, '%')</if>
|
||||
<if test="nickName != null and nickName != ''"> and nick_name like concat('%', #{nickName}, '%')</if>
|
||||
<if test="requestTime != null "> and request_time = #{requestTime}</if>
|
||||
<if test="startTime != null "> and start_time = #{startTime}</if>
|
||||
<if test="endTime != null "> and end_time = #{endTime}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectWmMaterialrequestNoticeByNoticeId" parameterType="Long" resultMap="WmMaterialrequestNoticeResult">
|
||||
<include refid="selectWmMaterialrequestNoticeVo"/>
|
||||
where notice_id = #{noticeId}
|
||||
</select>
|
||||
|
||||
<insert id="insertWmMaterialrequestNotice" parameterType="WmMaterialrequestNotice" useGeneratedKeys="true" keyProperty="noticeId">
|
||||
insert into wm_materialrequest_notice
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="workstationId != null">workstation_id,</if>
|
||||
<if test="workstaitonCode != null">workstaiton_code,</if>
|
||||
<if test="workorderId != null">workorder_id,</if>
|
||||
<if test="workorderCode != null">workorder_code,</if>
|
||||
<if test="userId != null">user_id,</if>
|
||||
<if test="userName != null">user_name,</if>
|
||||
<if test="nickName != null">nick_name,</if>
|
||||
<if test="requestTime != null">request_time,</if>
|
||||
<if test="startTime != null">start_time,</if>
|
||||
<if test="endTime != null">end_time,</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>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="workstationId != null">#{workstationId},</if>
|
||||
<if test="workstaitonCode != null">#{workstaitonCode},</if>
|
||||
<if test="workorderId != null">#{workorderId},</if>
|
||||
<if test="workorderCode != null">#{workorderCode},</if>
|
||||
<if test="userId != null">#{userId},</if>
|
||||
<if test="userName != null">#{userName},</if>
|
||||
<if test="nickName != null">#{nickName},</if>
|
||||
<if test="requestTime != null">#{requestTime},</if>
|
||||
<if test="startTime != null">#{startTime},</if>
|
||||
<if test="endTime != null">#{endTime},</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>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateWmMaterialrequestNotice" parameterType="WmMaterialrequestNotice">
|
||||
update wm_materialrequest_notice
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="workstationId != null">workstation_id = #{workstationId},</if>
|
||||
<if test="workstaitonCode != null">workstaiton_code = #{workstaitonCode},</if>
|
||||
<if test="workorderId != null">workorder_id = #{workorderId},</if>
|
||||
<if test="workorderCode != null">workorder_code = #{workorderCode},</if>
|
||||
<if test="userId != null">user_id = #{userId},</if>
|
||||
<if test="userName != null">user_name = #{userName},</if>
|
||||
<if test="nickName != null">nick_name = #{nickName},</if>
|
||||
<if test="requestTime != null">request_time = #{requestTime},</if>
|
||||
<if test="startTime != null">start_time = #{startTime},</if>
|
||||
<if test="endTime != null">end_time = #{endTime},</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>
|
||||
</trim>
|
||||
where notice_id = #{noticeId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteWmMaterialrequestNoticeByNoticeId" parameterType="Long">
|
||||
delete from wm_materialrequest_notice where notice_id = #{noticeId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteWmMaterialrequestNoticeByNoticeIds" parameterType="String">
|
||||
delete from wm_materialrequest_notice where notice_id in
|
||||
<foreach item="noticeId" collection="array" open="(" separator="," close=")">
|
||||
#{noticeId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
Loading…
Reference in New Issue
Block a user