成品生产入库
parent
77d831af56
commit
50fdeebd4b
@ -0,0 +1,97 @@
|
||||
package com.op.wms.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.wms.domain.WmsProductPut;
|
||||
import com.op.wms.service.IWmsProductPutService;
|
||||
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-08-29
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/put")
|
||||
public class WmsProductPutController extends BaseController {
|
||||
@Autowired
|
||||
private IWmsProductPutService wmsProductPutService;
|
||||
|
||||
/**
|
||||
* 查询成品生产入库列表
|
||||
*/
|
||||
@RequiresPermissions("wms:put:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(WmsProductPut wmsProductPut) {
|
||||
startPage();
|
||||
List<WmsProductPut> list = wmsProductPutService.selectWmsProductPutList(wmsProductPut);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出成品生产入库列表
|
||||
*/
|
||||
@RequiresPermissions("wms:put:export")
|
||||
@Log(title = "成品生产入库", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, WmsProductPut wmsProductPut) {
|
||||
List<WmsProductPut> list = wmsProductPutService.selectWmsProductPutList(wmsProductPut);
|
||||
ExcelUtil<WmsProductPut> util = new ExcelUtil<WmsProductPut>(WmsProductPut.class);
|
||||
util.exportExcel(response, list, "成品生产入库数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取成品生产入库详细信息
|
||||
*/
|
||||
@RequiresPermissions("wms:put:query")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") String id) {
|
||||
return success(wmsProductPutService.selectWmsProductPutById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增成品生产入库
|
||||
*/
|
||||
@RequiresPermissions("wms:put:add")
|
||||
@Log(title = "成品生产入库", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody WmsProductPut wmsProductPut) {
|
||||
return toAjax(wmsProductPutService.insertWmsProductPut(wmsProductPut));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改成品生产入库
|
||||
*/
|
||||
@RequiresPermissions("wms:put:edit")
|
||||
@Log(title = "成品生产入库", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody WmsProductPut wmsProductPut) {
|
||||
return toAjax(wmsProductPutService.updateWmsProductPut(wmsProductPut));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除成品生产入库
|
||||
*/
|
||||
@RequiresPermissions("wms:put:remove")
|
||||
@Log(title = "成品生产入库", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable String[] ids) {
|
||||
return toAjax(wmsProductPutService.deleteWmsProductPutByIds(ids));
|
||||
}
|
||||
}
|
@ -0,0 +1,365 @@
|
||||
package com.op.wms.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.op.common.core.annotation.Excel;
|
||||
import com.op.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 成品生产入库对象 wms_product_put
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-08-29
|
||||
*/
|
||||
public class WmsProductPut extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** ID */
|
||||
private String id;
|
||||
|
||||
/** 工厂编码 */
|
||||
@Excel(name = "工厂编码")
|
||||
private String factoryCode;
|
||||
|
||||
/** 退货单号 */
|
||||
@Excel(name = "退货单号")
|
||||
private String productOrder;
|
||||
|
||||
/** 仓库编码 */
|
||||
@Excel(name = "仓库编码")
|
||||
private String whCode;
|
||||
|
||||
/** 库区编码 */
|
||||
@Excel(name = "库区编码")
|
||||
private String waCode;
|
||||
|
||||
/** 库位编码 */
|
||||
@Excel(name = "库位编码")
|
||||
private String wlCode;
|
||||
|
||||
/** 产品名称 */
|
||||
@Excel(name = "产品名称")
|
||||
private String productName;
|
||||
|
||||
/** 产品编码 */
|
||||
@Excel(name = "产品编码")
|
||||
private String productCode;
|
||||
|
||||
/** 产品分类 */
|
||||
@Excel(name = "产品分类")
|
||||
private String productSort;
|
||||
|
||||
/** 规格型号 */
|
||||
@Excel(name = "规格型号")
|
||||
private String specification;
|
||||
|
||||
/** 单位 */
|
||||
@Excel(name = "单位")
|
||||
private String unitOfMeasure;
|
||||
|
||||
/** 计划入库数量 */
|
||||
@Excel(name = "计划入库数量")
|
||||
private Long planQuantity;
|
||||
|
||||
/** 入库数量 */
|
||||
@Excel(name = "入库数量")
|
||||
private Long putQuantity;
|
||||
|
||||
/** 入库状态 */
|
||||
@Excel(name = "入库状态")
|
||||
private String status;
|
||||
|
||||
/** 过账SAP状态 */
|
||||
@Excel(name = "过账SAP状态")
|
||||
private String sapStatus;
|
||||
|
||||
/** 过账SAP凭证 */
|
||||
@Excel(name = "过账SAP凭证")
|
||||
private String sapProof;
|
||||
|
||||
/** 过账SAP返回信息 */
|
||||
@Excel(name = "过账SAP返回信息")
|
||||
private String sapMessage;
|
||||
|
||||
/** 入库时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "入库时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date putDate;
|
||||
|
||||
/** 预留字段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;
|
||||
|
||||
/** 预留字段5 */
|
||||
@Excel(name = "预留字段5")
|
||||
private String attr5;
|
||||
|
||||
/** 预留字段6 */
|
||||
@Excel(name = "预留字段6")
|
||||
private String attr6;
|
||||
|
||||
/** 预留字段7 */
|
||||
@Excel(name = "预留字段7")
|
||||
private String attr7;
|
||||
|
||||
/** 预留字段8 */
|
||||
@Excel(name = "预留字段8")
|
||||
private String attr8;
|
||||
|
||||
/** 预留字段9 */
|
||||
@Excel(name = "预留字段9")
|
||||
private String attr9;
|
||||
|
||||
/** 预留字段10 */
|
||||
@Excel(name = "预留字段10")
|
||||
private String attr10;
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
public void setFactoryCode(String factoryCode) {
|
||||
this.factoryCode = factoryCode;
|
||||
}
|
||||
|
||||
public String getFactoryCode() {
|
||||
return factoryCode;
|
||||
}
|
||||
public void setProductOrder(String productOrder) {
|
||||
this.productOrder = productOrder;
|
||||
}
|
||||
|
||||
public String getProductOrder() {
|
||||
return productOrder;
|
||||
}
|
||||
public void setWhCode(String whCode) {
|
||||
this.whCode = whCode;
|
||||
}
|
||||
|
||||
public String getWhCode() {
|
||||
return whCode;
|
||||
}
|
||||
public void setWaCode(String waCode) {
|
||||
this.waCode = waCode;
|
||||
}
|
||||
|
||||
public String getWaCode() {
|
||||
return waCode;
|
||||
}
|
||||
public void setWlCode(String wlCode) {
|
||||
this.wlCode = wlCode;
|
||||
}
|
||||
|
||||
public String getWlCode() {
|
||||
return wlCode;
|
||||
}
|
||||
public void setProductName(String productName) {
|
||||
this.productName = productName;
|
||||
}
|
||||
|
||||
public String getProductName() {
|
||||
return productName;
|
||||
}
|
||||
public void setProductCode(String productCode) {
|
||||
this.productCode = productCode;
|
||||
}
|
||||
|
||||
public String getProductCode() {
|
||||
return productCode;
|
||||
}
|
||||
public void setProductSort(String productSort) {
|
||||
this.productSort = productSort;
|
||||
}
|
||||
|
||||
public String getProductSort() {
|
||||
return productSort;
|
||||
}
|
||||
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 setPlanQuantity(Long planQuantity) {
|
||||
this.planQuantity = planQuantity;
|
||||
}
|
||||
|
||||
public Long getPlanQuantity() {
|
||||
return planQuantity;
|
||||
}
|
||||
public void setPutQuantity(Long putQuantity) {
|
||||
this.putQuantity = putQuantity;
|
||||
}
|
||||
|
||||
public Long getPutQuantity() {
|
||||
return putQuantity;
|
||||
}
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
public void setSapStatus(String sapStatus) {
|
||||
this.sapStatus = sapStatus;
|
||||
}
|
||||
|
||||
public String getSapStatus() {
|
||||
return sapStatus;
|
||||
}
|
||||
public void setSapProof(String sapProof) {
|
||||
this.sapProof = sapProof;
|
||||
}
|
||||
|
||||
public String getSapProof() {
|
||||
return sapProof;
|
||||
}
|
||||
public void setSapMessage(String sapMessage) {
|
||||
this.sapMessage = sapMessage;
|
||||
}
|
||||
|
||||
public String getSapMessage() {
|
||||
return sapMessage;
|
||||
}
|
||||
public void setPutDate(Date putDate) {
|
||||
this.putDate = putDate;
|
||||
}
|
||||
|
||||
public Date getPutDate() {
|
||||
return putDate;
|
||||
}
|
||||
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 setAttr5(String attr5) {
|
||||
this.attr5 = attr5;
|
||||
}
|
||||
|
||||
public String getAttr5() {
|
||||
return attr5;
|
||||
}
|
||||
public void setAttr6(String attr6) {
|
||||
this.attr6 = attr6;
|
||||
}
|
||||
|
||||
public String getAttr6() {
|
||||
return attr6;
|
||||
}
|
||||
public void setAttr7(String attr7) {
|
||||
this.attr7 = attr7;
|
||||
}
|
||||
|
||||
public String getAttr7() {
|
||||
return attr7;
|
||||
}
|
||||
public void setAttr8(String attr8) {
|
||||
this.attr8 = attr8;
|
||||
}
|
||||
|
||||
public String getAttr8() {
|
||||
return attr8;
|
||||
}
|
||||
public void setAttr9(String attr9) {
|
||||
this.attr9 = attr9;
|
||||
}
|
||||
|
||||
public String getAttr9() {
|
||||
return attr9;
|
||||
}
|
||||
public void setAttr10(String attr10) {
|
||||
this.attr10 = attr10;
|
||||
}
|
||||
|
||||
public String getAttr10() {
|
||||
return attr10;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("factoryCode", getFactoryCode())
|
||||
.append("productOrder", getProductOrder())
|
||||
.append("whCode", getWhCode())
|
||||
.append("waCode", getWaCode())
|
||||
.append("wlCode", getWlCode())
|
||||
.append("productName", getProductName())
|
||||
.append("productCode", getProductCode())
|
||||
.append("productSort", getProductSort())
|
||||
.append("specification", getSpecification())
|
||||
.append("unitOfMeasure", getUnitOfMeasure())
|
||||
.append("planQuantity", getPlanQuantity())
|
||||
.append("putQuantity", getPutQuantity())
|
||||
.append("status", getStatus())
|
||||
.append("sapStatus", getSapStatus())
|
||||
.append("sapProof", getSapProof())
|
||||
.append("sapMessage", getSapMessage())
|
||||
.append("putDate", getPutDate())
|
||||
.append("attr1", getAttr1())
|
||||
.append("attr2", getAttr2())
|
||||
.append("attr3", getAttr3())
|
||||
.append("attr4", getAttr4())
|
||||
.append("attr5", getAttr5())
|
||||
.append("attr6", getAttr6())
|
||||
.append("attr7", getAttr7())
|
||||
.append("attr8", getAttr8())
|
||||
.append("attr9", getAttr9())
|
||||
.append("attr10", getAttr10())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.op.wms.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.op.wms.domain.WmsProductPut;
|
||||
|
||||
/**
|
||||
* 成品生产入库Mapper接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-08-29
|
||||
*/
|
||||
public interface WmsProductPutMapper {
|
||||
/**
|
||||
* 查询成品生产入库
|
||||
*
|
||||
* @param id 成品生产入库主键
|
||||
* @return 成品生产入库
|
||||
*/
|
||||
public WmsProductPut selectWmsProductPutById(String id);
|
||||
|
||||
/**
|
||||
* 查询成品生产入库列表
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 成品生产入库集合
|
||||
*/
|
||||
public List<WmsProductPut> selectWmsProductPutList(WmsProductPut wmsProductPut);
|
||||
|
||||
/**
|
||||
* 新增成品生产入库
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWmsProductPut(WmsProductPut wmsProductPut);
|
||||
|
||||
/**
|
||||
* 修改成品生产入库
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWmsProductPut(WmsProductPut wmsProductPut);
|
||||
|
||||
/**
|
||||
* 删除成品生产入库
|
||||
*
|
||||
* @param id 成品生产入库主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmsProductPutById(String id);
|
||||
|
||||
/**
|
||||
* 批量删除成品生产入库
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmsProductPutByIds(String[] ids);
|
||||
}
|
@ -0,0 +1,60 @@
|
||||
package com.op.wms.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.op.wms.domain.WmsProductPut;
|
||||
|
||||
/**
|
||||
* 成品生产入库Service接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-08-29
|
||||
*/
|
||||
public interface IWmsProductPutService {
|
||||
/**
|
||||
* 查询成品生产入库
|
||||
*
|
||||
* @param id 成品生产入库主键
|
||||
* @return 成品生产入库
|
||||
*/
|
||||
public WmsProductPut selectWmsProductPutById(String id);
|
||||
|
||||
/**
|
||||
* 查询成品生产入库列表
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 成品生产入库集合
|
||||
*/
|
||||
public List<WmsProductPut> selectWmsProductPutList(WmsProductPut wmsProductPut);
|
||||
|
||||
/**
|
||||
* 新增成品生产入库
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWmsProductPut(WmsProductPut wmsProductPut);
|
||||
|
||||
/**
|
||||
* 修改成品生产入库
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWmsProductPut(WmsProductPut wmsProductPut);
|
||||
|
||||
/**
|
||||
* 批量删除成品生产入库
|
||||
*
|
||||
* @param ids 需要删除的成品生产入库主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmsProductPutByIds(String[] ids);
|
||||
|
||||
/**
|
||||
* 删除成品生产入库信息
|
||||
*
|
||||
* @param id 成品生产入库主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWmsProductPutById(String id);
|
||||
}
|
@ -0,0 +1,99 @@
|
||||
package com.op.wms.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.op.common.core.utils.DateUtils;
|
||||
import com.op.common.core.utils.uuid.IdUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.op.wms.mapper.WmsProductPutMapper;
|
||||
import com.op.wms.domain.WmsProductPut;
|
||||
import com.op.wms.service.IWmsProductPutService;
|
||||
|
||||
/**
|
||||
* 成品生产入库Service业务层处理
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2023-08-29
|
||||
*/
|
||||
@Service
|
||||
public class WmsProductPutServiceImpl implements IWmsProductPutService {
|
||||
@Autowired
|
||||
|
||||
private WmsProductPutMapper wmsProductPutMapper;
|
||||
|
||||
/**
|
||||
* 查询成品生产入库
|
||||
*
|
||||
* @param id 成品生产入库主键
|
||||
* @return 成品生产入库
|
||||
*/
|
||||
@Override
|
||||
public WmsProductPut selectWmsProductPutById(String id) {
|
||||
return wmsProductPutMapper.selectWmsProductPutById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询成品生产入库列表
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 成品生产入库
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public List<WmsProductPut> selectWmsProductPutList(WmsProductPut wmsProductPut) {
|
||||
return wmsProductPutMapper.selectWmsProductPutList(wmsProductPut);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增成品生产入库
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int insertWmsProductPut(WmsProductPut wmsProductPut) {
|
||||
wmsProductPut.setId(IdUtils.fastSimpleUUID());
|
||||
wmsProductPut.setCreateTime(DateUtils.getNowDate());
|
||||
return wmsProductPutMapper.insertWmsProductPut(wmsProductPut);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改成品生产入库
|
||||
*
|
||||
* @param wmsProductPut 成品生产入库
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int updateWmsProductPut(WmsProductPut wmsProductPut) {
|
||||
wmsProductPut.setUpdateTime(DateUtils.getNowDate());
|
||||
return wmsProductPutMapper.updateWmsProductPut(wmsProductPut);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除成品生产入库
|
||||
*
|
||||
* @param ids 需要删除的成品生产入库主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteWmsProductPutByIds(String[] ids) {
|
||||
return wmsProductPutMapper.deleteWmsProductPutByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除成品生产入库信息
|
||||
*
|
||||
* @param id 成品生产入库主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteWmsProductPutById(String id) {
|
||||
return wmsProductPutMapper.deleteWmsProductPutById(id);
|
||||
}
|
||||
}
|
@ -0,0 +1,204 @@
|
||||
<?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.wms.mapper.WmsProductPutMapper">
|
||||
|
||||
<resultMap type="WmsProductPut" id="WmsProductPutResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="factoryCode" column="factory_code" />
|
||||
<result property="productOrder" column="product_order" />
|
||||
<result property="whCode" column="wh_code" />
|
||||
<result property="waCode" column="wa_code" />
|
||||
<result property="wlCode" column="wl_code" />
|
||||
<result property="productName" column="product_name" />
|
||||
<result property="productCode" column="product_code" />
|
||||
<result property="productSort" column="product_sort" />
|
||||
<result property="specification" column="specification" />
|
||||
<result property="unitOfMeasure" column="unit_of_measure" />
|
||||
<result property="planQuantity" column="plan_quantity" />
|
||||
<result property="putQuantity" column="put_quantity" />
|
||||
<result property="status" column="status" />
|
||||
<result property="sapStatus" column="SAP_status" />
|
||||
<result property="sapProof" column="SAP_proof" />
|
||||
<result property="sapMessage" column="SAP_message" />
|
||||
<result property="putDate" column="put_date" />
|
||||
<result property="attr1" column="attr1" />
|
||||
<result property="attr2" column="attr2" />
|
||||
<result property="attr3" column="attr3" />
|
||||
<result property="attr4" column="attr4" />
|
||||
<result property="attr5" column="attr5" />
|
||||
<result property="attr6" column="attr6" />
|
||||
<result property="attr7" column="attr7" />
|
||||
<result property="attr8" column="attr8" />
|
||||
<result property="attr9" column="attr9" />
|
||||
<result property="attr10" column="attr10" />
|
||||
<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="selectWmsProductPutVo">
|
||||
select id, factory_code, product_order, wh_code, wa_code, wl_code, product_name, product_code, product_sort, specification, unit_of_measure, plan_quantity, put_quantity, status, SAP_status, SAP_proof, SAP_message, put_date, attr1, attr2, attr3, attr4, attr5, attr6, attr7, attr8, attr9, attr10, create_by, create_time, update_by, update_time from wms_product_put
|
||||
</sql>
|
||||
|
||||
<select id="selectWmsProductPutList" parameterType="WmsProductPut" resultMap="WmsProductPutResult">
|
||||
<include refid="selectWmsProductPutVo"/>
|
||||
<where>
|
||||
<if test="factoryCode != null and factoryCode != ''"> and factory_code = #{factoryCode}</if>
|
||||
<if test="productOrder != null and productOrder != ''"> and product_order = #{productOrder}</if>
|
||||
<if test="whCode != null and whCode != ''"> and wh_code = #{whCode}</if>
|
||||
<if test="waCode != null and waCode != ''"> and wa_code = #{waCode}</if>
|
||||
<if test="wlCode != null and wlCode != ''"> and wl_code = #{wlCode}</if>
|
||||
<if test="productName != null and productName != ''"> and product_name like concat('%', #{productName}, '%')</if>
|
||||
<if test="productCode != null and productCode != ''"> and product_code = #{productCode}</if>
|
||||
<if test="productSort != null and productSort != ''"> and product_sort = #{productSort}</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="planQuantity != null "> and plan_quantity = #{planQuantity}</if>
|
||||
<if test="putQuantity != null "> and put_quantity = #{putQuantity}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
<if test="sapStatus != null and sapStatus != ''"> and SAP_status = #{sapStatus}</if>
|
||||
<if test="sapProof != null and sapProof != ''"> and SAP_proof = #{sapProof}</if>
|
||||
<if test="sapMessage != null and sapMessage != ''"> and SAP_message = #{sapMessage}</if>
|
||||
<if test="putDate != null "> and put_date = #{putDate}</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="attr5 != null and attr5 != ''"> and attr5 = #{attr5}</if>
|
||||
<if test="attr6 != null and attr6 != ''"> and attr6 = #{attr6}</if>
|
||||
<if test="attr7 != null and attr7 != ''"> and attr7 = #{attr7}</if>
|
||||
<if test="attr8 != null and attr8 != ''"> and attr8 = #{attr8}</if>
|
||||
<if test="attr9 != null and attr9 != ''"> and attr9 = #{attr9}</if>
|
||||
<if test="attr10 != null and attr10 != ''"> and attr10 = #{attr10}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectWmsProductPutById" parameterType="String" resultMap="WmsProductPutResult">
|
||||
<include refid="selectWmsProductPutVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertWmsProductPut" parameterType="WmsProductPut">
|
||||
insert into wms_product_put
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">factory_code,</if>
|
||||
<if test="productOrder != null">product_order,</if>
|
||||
<if test="whCode != null">wh_code,</if>
|
||||
<if test="waCode != null">wa_code,</if>
|
||||
<if test="wlCode != null">wl_code,</if>
|
||||
<if test="productName != null">product_name,</if>
|
||||
<if test="productCode != null">product_code,</if>
|
||||
<if test="productSort != null">product_sort,</if>
|
||||
<if test="specification != null">specification,</if>
|
||||
<if test="unitOfMeasure != null">unit_of_measure,</if>
|
||||
<if test="planQuantity != null">plan_quantity,</if>
|
||||
<if test="putQuantity != null">put_quantity,</if>
|
||||
<if test="status != null">status,</if>
|
||||
<if test="sapStatus != null">SAP_status,</if>
|
||||
<if test="sapProof != null">SAP_proof,</if>
|
||||
<if test="sapMessage != null">SAP_message,</if>
|
||||
<if test="putDate != null">put_date,</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="attr5 != null">attr5,</if>
|
||||
<if test="attr6 != null">attr6,</if>
|
||||
<if test="attr7 != null">attr7,</if>
|
||||
<if test="attr8 != null">attr8,</if>
|
||||
<if test="attr9 != null">attr9,</if>
|
||||
<if test="attr10 != null">attr10,</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="id != null">#{id},</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">#{factoryCode},</if>
|
||||
<if test="productOrder != null">#{productOrder},</if>
|
||||
<if test="whCode != null">#{whCode},</if>
|
||||
<if test="waCode != null">#{waCode},</if>
|
||||
<if test="wlCode != null">#{wlCode},</if>
|
||||
<if test="productName != null">#{productName},</if>
|
||||
<if test="productCode != null">#{productCode},</if>
|
||||
<if test="productSort != null">#{productSort},</if>
|
||||
<if test="specification != null">#{specification},</if>
|
||||
<if test="unitOfMeasure != null">#{unitOfMeasure},</if>
|
||||
<if test="planQuantity != null">#{planQuantity},</if>
|
||||
<if test="putQuantity != null">#{putQuantity},</if>
|
||||
<if test="status != null">#{status},</if>
|
||||
<if test="sapStatus != null">#{sapStatus},</if>
|
||||
<if test="sapProof != null">#{sapProof},</if>
|
||||
<if test="sapMessage != null">#{sapMessage},</if>
|
||||
<if test="putDate != null">#{putDate},</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="attr5 != null">#{attr5},</if>
|
||||
<if test="attr6 != null">#{attr6},</if>
|
||||
<if test="attr7 != null">#{attr7},</if>
|
||||
<if test="attr8 != null">#{attr8},</if>
|
||||
<if test="attr9 != null">#{attr9},</if>
|
||||
<if test="attr10 != null">#{attr10},</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="updateWmsProductPut" parameterType="WmsProductPut">
|
||||
update wms_product_put
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="factoryCode != null and factoryCode != ''">factory_code = #{factoryCode},</if>
|
||||
<if test="productOrder != null">product_order = #{productOrder},</if>
|
||||
<if test="whCode != null">wh_code = #{whCode},</if>
|
||||
<if test="waCode != null">wa_code = #{waCode},</if>
|
||||
<if test="wlCode != null">wl_code = #{wlCode},</if>
|
||||
<if test="productName != null">product_name = #{productName},</if>
|
||||
<if test="productCode != null">product_code = #{productCode},</if>
|
||||
<if test="productSort != null">product_sort = #{productSort},</if>
|
||||
<if test="specification != null">specification = #{specification},</if>
|
||||
<if test="unitOfMeasure != null">unit_of_measure = #{unitOfMeasure},</if>
|
||||
<if test="planQuantity != null">plan_quantity = #{planQuantity},</if>
|
||||
<if test="putQuantity != null">put_quantity = #{putQuantity},</if>
|
||||
<if test="status != null">status = #{status},</if>
|
||||
<if test="sapStatus != null">SAP_status = #{sapStatus},</if>
|
||||
<if test="sapProof != null">SAP_proof = #{sapProof},</if>
|
||||
<if test="sapMessage != null">SAP_message = #{sapMessage},</if>
|
||||
<if test="putDate != null">put_date = #{putDate},</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="attr5 != null">attr5 = #{attr5},</if>
|
||||
<if test="attr6 != null">attr6 = #{attr6},</if>
|
||||
<if test="attr7 != null">attr7 = #{attr7},</if>
|
||||
<if test="attr8 != null">attr8 = #{attr8},</if>
|
||||
<if test="attr9 != null">attr9 = #{attr9},</if>
|
||||
<if test="attr10 != null">attr10 = #{attr10},</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 id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteWmsProductPutById" parameterType="String">
|
||||
delete from wms_product_put where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteWmsProductPutByIds" parameterType="String">
|
||||
delete from wms_product_put where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
Loading…
Reference in New Issue