Merge remote-tracking branch 'refs/remotes/惠信/dev_zhangke' into develop
This commit is contained in:
commit
79b3685830
|
|
@ -0,0 +1,28 @@
|
||||||
|
package com.nflg.wms.admin.controller;
|
||||||
|
|
||||||
|
/* * 普通物料收货单*/
|
||||||
|
|
||||||
|
import com.nflg.wms.starter.BaseController;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/pgi/normal")
|
||||||
|
public class NormalPGIController extends BaseController {
|
||||||
|
|
||||||
|
// @RequestMapping("search")
|
||||||
|
|
||||||
|
//收货单分页
|
||||||
|
|
||||||
|
//收货单详情
|
||||||
|
|
||||||
|
//一键收货
|
||||||
|
|
||||||
|
//PDA 扫码收货
|
||||||
|
|
||||||
|
// 查看扫码记录
|
||||||
|
|
||||||
|
//收货确认
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,34 @@
|
||||||
|
package com.nflg.wms.admin.controller;
|
||||||
|
|
||||||
|
import com.nflg.wms.common.constant.UserType;
|
||||||
|
import com.nflg.wms.common.pojo.ApiResult;
|
||||||
|
import com.nflg.wms.common.pojo.PageData;
|
||||||
|
import com.nflg.wms.common.pojo.qo.DeliverNormalOrderSearchQO;
|
||||||
|
import com.nflg.wms.common.pojo.qo.NomalQMOrderSearchQO;
|
||||||
|
import com.nflg.wms.common.pojo.vo.DeliverNormalOrderVO;
|
||||||
|
import com.nflg.wms.common.pojo.vo.QualityInspectionVO;
|
||||||
|
import com.nflg.wms.common.util.UserUtil;
|
||||||
|
import com.nflg.wms.repository.service.IWmsSrmQualityInspectionService;
|
||||||
|
import com.nflg.wms.starter.BaseController;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import jakarta.validation.Valid;
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import java.util.Objects;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qm/normal")
|
||||||
|
public class NormalQMController extends BaseController {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private IWmsSrmQualityInspectionService wmsSrmQualityInspectionService;
|
||||||
|
|
||||||
|
@PostMapping("search")
|
||||||
|
public ApiResult<PageData<QualityInspectionVO>> search(@Valid @RequestBody NomalQMOrderSearchQO request) {
|
||||||
|
return ApiResult.success(wmsSrmQualityInspectionService.search(request));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,35 @@
|
||||||
|
package com.nflg.wms.common.pojo.qo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class NomalQMOrderSearchQO extends SearchBaseQO{
|
||||||
|
/**
|
||||||
|
采购订单号
|
||||||
|
*/
|
||||||
|
public String poNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
送货单号
|
||||||
|
*/
|
||||||
|
public String noteNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
上架状态
|
||||||
|
*/
|
||||||
|
|
||||||
|
public Integer inStatus;
|
||||||
|
|
||||||
|
/**
|
||||||
|
质检单号
|
||||||
|
*/
|
||||||
|
public String inspectionNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
供应商代码
|
||||||
|
*/
|
||||||
|
public String supplierNum;
|
||||||
|
|
||||||
|
|
||||||
|
public String itemCode;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,127 @@
|
||||||
|
package com.nflg.wms.common.pojo.vo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class QualityInspectionVO {
|
||||||
|
/**
|
||||||
|
质检单号
|
||||||
|
*/
|
||||||
|
public String inspectionNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
工厂
|
||||||
|
*/
|
||||||
|
public String factory;
|
||||||
|
/**
|
||||||
|
供应商代码
|
||||||
|
*/
|
||||||
|
public String supplierNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
供应商名称
|
||||||
|
*/
|
||||||
|
public String supplierName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
送货数量
|
||||||
|
*/
|
||||||
|
public BigDecimal deliveryQty;
|
||||||
|
|
||||||
|
/**
|
||||||
|
检验结果
|
||||||
|
*/
|
||||||
|
public String inspectionResult;
|
||||||
|
|
||||||
|
/**
|
||||||
|
物料号
|
||||||
|
*/
|
||||||
|
public String itemCode;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
检验类型
|
||||||
|
*/
|
||||||
|
public String inspectionType;
|
||||||
|
|
||||||
|
/**
|
||||||
|
采购单行号
|
||||||
|
*/
|
||||||
|
public String poLineNumber;
|
||||||
|
|
||||||
|
/**
|
||||||
|
检验数量
|
||||||
|
*/
|
||||||
|
public BigDecimal inspectionQty;
|
||||||
|
|
||||||
|
/**
|
||||||
|
物料描述
|
||||||
|
*/
|
||||||
|
public String itemName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
单位
|
||||||
|
*/
|
||||||
|
public String unit;
|
||||||
|
|
||||||
|
/**
|
||||||
|
收货仓库
|
||||||
|
*/
|
||||||
|
public String receivedWarehouse;
|
||||||
|
|
||||||
|
/**
|
||||||
|
不合格原因
|
||||||
|
*/
|
||||||
|
public String unqualifiedReason;
|
||||||
|
|
||||||
|
/**
|
||||||
|
采购订单号
|
||||||
|
*/
|
||||||
|
public String poNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
物料凭证(收货时SAP返回的凭证)
|
||||||
|
*/
|
||||||
|
public String receiveNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
不合格数量
|
||||||
|
*/
|
||||||
|
public BigDecimal unqualifiedQty;
|
||||||
|
|
||||||
|
/**
|
||||||
|
合格数量合格数量
|
||||||
|
*/
|
||||||
|
public BigDecimal qualifiedQty;
|
||||||
|
|
||||||
|
/**
|
||||||
|
收货时的批次
|
||||||
|
*/
|
||||||
|
public String receiveBatchNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
收货时的序列号
|
||||||
|
*/
|
||||||
|
public String serialNum;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
送货单行号
|
||||||
|
*/
|
||||||
|
public String lineNumber;
|
||||||
|
|
||||||
|
/**
|
||||||
|
送货单号
|
||||||
|
*/
|
||||||
|
public String noteNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
上架状态
|
||||||
|
*/
|
||||||
|
|
||||||
|
public Integer inStatus;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,12 @@
|
||||||
package com.nflg.wms.repository.mapper;
|
package com.nflg.wms.repository.mapper;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.nflg.wms.common.pojo.qo.MaterialSearchQO;
|
||||||
|
import com.nflg.wms.common.pojo.qo.NomalQMOrderSearchQO;
|
||||||
|
import com.nflg.wms.common.pojo.vo.MaterialVO;
|
||||||
|
import com.nflg.wms.common.pojo.vo.QualityInspectionVO;
|
||||||
import com.nflg.wms.repository.entity.WmsSrmMaterialReceipt;
|
import com.nflg.wms.repository.entity.WmsSrmMaterialReceipt;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -13,4 +19,5 @@ import com.nflg.wms.repository.entity.WmsSrmMaterialReceipt;
|
||||||
*/
|
*/
|
||||||
public interface WmsSrmMaterialReceiptMapper extends BaseMapper<WmsSrmMaterialReceipt> {
|
public interface WmsSrmMaterialReceiptMapper extends BaseMapper<WmsSrmMaterialReceipt> {
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,10 @@
|
||||||
package com.nflg.wms.repository.mapper;
|
package com.nflg.wms.repository.mapper;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.nflg.wms.common.pojo.qo.NomalQMOrderSearchQO;
|
||||||
|
import com.nflg.wms.common.pojo.vo.QualityInspectionVO;
|
||||||
import com.nflg.wms.repository.entity.WmsSrmQualityInspection;
|
import com.nflg.wms.repository.entity.WmsSrmQualityInspection;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -12,5 +16,5 @@ import com.nflg.wms.repository.entity.WmsSrmQualityInspection;
|
||||||
* @since 2025
|
* @since 2025
|
||||||
*/
|
*/
|
||||||
public interface WmsSrmQualityInspectionMapper extends BaseMapper<WmsSrmQualityInspection> {
|
public interface WmsSrmQualityInspectionMapper extends BaseMapper<WmsSrmQualityInspection> {
|
||||||
|
IPage<QualityInspectionVO> search(NomalQMOrderSearchQO request, Page<?> objectPage);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,12 @@
|
||||||
package com.nflg.wms.repository.service;
|
package com.nflg.wms.repository.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.nflg.wms.common.pojo.PageData;
|
||||||
|
import com.nflg.wms.common.pojo.qo.NomalQMOrderSearchQO;
|
||||||
|
import com.nflg.wms.common.pojo.vo.QualityInspectionVO;
|
||||||
import com.nflg.wms.repository.entity.WmsSrmQualityInspection;
|
import com.nflg.wms.repository.entity.WmsSrmQualityInspection;
|
||||||
import com.baomidou.mybatisplus.extension.service.IService;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import jakarta.validation.Valid;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <p>
|
* <p>
|
||||||
|
|
@ -13,4 +18,5 @@ import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
*/
|
*/
|
||||||
public interface IWmsSrmQualityInspectionService extends IService<WmsSrmQualityInspection> {
|
public interface IWmsSrmQualityInspectionService extends IService<WmsSrmQualityInspection> {
|
||||||
|
|
||||||
|
IPage<QualityInspectionVO> search(@Valid NomalQMOrderSearchQO request);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,22 @@
|
||||||
package com.nflg.wms.repository.service.impl;
|
package com.nflg.wms.repository.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollectionUtil;
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.nflg.wms.common.pojo.PageData;
|
||||||
|
import com.nflg.wms.common.pojo.qo.NomalQMOrderSearchQO;
|
||||||
|
import com.nflg.wms.common.pojo.vo.QualityInspectionVO;
|
||||||
|
import com.nflg.wms.common.pojo.vo.StorageVO;
|
||||||
|
import com.nflg.wms.repository.entity.WmsBin;
|
||||||
import com.nflg.wms.repository.entity.WmsSrmQualityInspection;
|
import com.nflg.wms.repository.entity.WmsSrmQualityInspection;
|
||||||
import com.nflg.wms.repository.mapper.WmsSrmQualityInspectionMapper;
|
import com.nflg.wms.repository.mapper.WmsSrmQualityInspectionMapper;
|
||||||
import com.nflg.wms.repository.service.IWmsSrmQualityInspectionService;
|
import com.nflg.wms.repository.service.IWmsSrmQualityInspectionService;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* <p>
|
* <p>
|
||||||
* 服务实现类
|
* 服务实现类
|
||||||
|
|
@ -17,4 +28,8 @@ import org.springframework.stereotype.Service;
|
||||||
@Service
|
@Service
|
||||||
public class WmsSrmQualityInspectionServiceImpl extends ServiceImpl<WmsSrmQualityInspectionMapper, WmsSrmQualityInspection> implements IWmsSrmQualityInspectionService {
|
public class WmsSrmQualityInspectionServiceImpl extends ServiceImpl<WmsSrmQualityInspectionMapper, WmsSrmQualityInspection> implements IWmsSrmQualityInspectionService {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<QualityInspectionVO> search(NomalQMOrderSearchQO request) {
|
||||||
|
return baseMapper.search(request,new Page<>(request.getPage(),request.getPageSize()));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,51 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?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">
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
<mapper namespace="com.nflg.wms.repository.mapper.WmsSrmQualityInspectionMapper">
|
<mapper namespace="com.nflg.wms.repository.mapper.WmsSrmQualityInspectionMapper">
|
||||||
|
<select id="search" resultType="com.nflg.wms.common.pojo.vo.QualityInspectionVO">
|
||||||
|
<!-- SELECT DISTINCT ON ("no") *-->
|
||||||
|
<!-- FROM wms_material-->
|
||||||
|
<!-- <where>-->
|
||||||
|
<!-- <if test="request.no!=null and request.no!=''">-->
|
||||||
|
<!-- and "no" like concat('%', #{request.no}, '%')-->
|
||||||
|
<!-- </if>-->
|
||||||
|
<!-- <if test="request.describe!=null and request.describe!=''">-->
|
||||||
|
<!-- and describe like concat('%', #{request.describe}, '%')-->
|
||||||
|
<!-- </if>-->
|
||||||
|
<!-- </where>-->
|
||||||
|
<!-- ORDER BY "no",id DESC-->
|
||||||
|
|
||||||
|
select
|
||||||
|
a.inspection_num,a.factory,a.suppler_num as supplier_num,c.supplier_name,a.delivery_qty,a.inspection_result,a.item_code,a.inspection_type,
|
||||||
|
a.po_line_number,a.inspection_qty,a.item_name,a.unit,a.received_warehouse,a.unqualified_reason,a.po_num,a.receive_num,a.unqualified_qty,
|
||||||
|
a.qualified_qty,a.material_batch as receive_batch_num,a.serial_num,a.line_number,a.note_num,COALESCE(b.data_status,0) as
|
||||||
|
in_status
|
||||||
|
from wms_srm_quality_inspection a left join wms_in_task_item b on a.note_num=b.note_num and
|
||||||
|
a.line_number=b.line_number
|
||||||
|
left join user_supplier c on a.suppler_num=c.supplier_code
|
||||||
|
<where>
|
||||||
|
<if test="request.poNum !=null and request.poNum !='' ">
|
||||||
|
and a.po_num like concat('%', #{request.poNum}, '%')
|
||||||
|
</if>
|
||||||
|
|
||||||
|
<if test="request.noteNum !=null and request.noteNum !='' ">
|
||||||
|
and a.note_num like concat('%', #{request.noteNum}, '%')
|
||||||
|
</if>
|
||||||
|
|
||||||
|
<if test="request.inStatus !=null and request.inStatus !='' ">
|
||||||
|
and b.data_status=#{request.inStatus}
|
||||||
|
</if>
|
||||||
|
|
||||||
|
<if test="request.inspectionNum !=null and request.inspectionNum !='' ">
|
||||||
|
and a.inspection_num like concat('%', #{request.inspectionNum}, '%')
|
||||||
|
</if>
|
||||||
|
|
||||||
|
<if test="request.supplierNum !=null and request.supplierNum !='' ">
|
||||||
|
and a.suppler_num =#{request.supplierNum}
|
||||||
|
</if>
|
||||||
|
|
||||||
|
<if test="request.itemCode !=null and request.itemCode !='' ">
|
||||||
|
and a.item_code like =#{request.itemCode}
|
||||||
|
</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue