打包收货部分功能完成
This commit is contained in:
parent
beb4011729
commit
0d755fed51
|
|
@ -7,6 +7,7 @@ package com.nflg.wms.admin.controller;
|
|||
import cn.hutool.core.collection.CollectionUtil;
|
||||
import cn.hutool.core.convert.Convert;
|
||||
import cn.hutool.core.util.IdUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.hutool.crypto.digest.DigestUtil;
|
||||
import com.nflg.wms.admin.pojo.dto.QCMaterialSyncDTO;
|
||||
|
|
@ -1085,27 +1086,113 @@ public class NormalPGIController extends BaseController {
|
|||
|
||||
//------------------------------------通过大包物料扫码收货------------------------------------
|
||||
|
||||
// @PostMapping("scanPackage")
|
||||
// @ApiMark(moduleName = "打包扫码", apiName = "通过打包码获取到打包码的信息")
|
||||
// public ApiResult<PacageScanVO> scanPackage(@Valid @RequestBody StrappingQO request) {
|
||||
//
|
||||
// }
|
||||
//
|
||||
// @PostMapping("getPackageOrders")
|
||||
// @ApiMark(moduleName = "获取打包码对应的送货单信息", apiName = "获取打包码对应的送货单信息")
|
||||
// public ApiResult<PacageScanVO> scanPackage(@Valid @RequestBody StrappingQO request) {
|
||||
//
|
||||
// }
|
||||
//
|
||||
// @PostMapping("getPackageOrderItems")
|
||||
// @ApiMark(moduleName = "根据送货单单号和大码的ID获取到具体的物料信息", apiName = "根据送货单单号和大码的ID获取到具体的物料信息")
|
||||
// public ApiResult<PacageScanVO> scanPackage(@Valid @RequestBody StrappingQO request) {
|
||||
//
|
||||
// }
|
||||
//
|
||||
// @PostMapping("getPackageOrderItems")
|
||||
// @ApiMark(moduleName = "根据送货单单号和大码的ID获取到具体的物料信息", apiName = "根据送货单单号和大码的ID获取到具体的物料信息")
|
||||
// public ApiResult<PacageScanVO> scanPackage(@Valid @RequestBody StrappingQO request) {
|
||||
//
|
||||
// }
|
||||
|
||||
/**
|
||||
* 通过打包码获取到打包码的信息
|
||||
* @param request
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("scanPackage")
|
||||
@ApiMark(moduleName = "打包扫码", apiName = "通过打包码获取到打包码的信息")
|
||||
public ApiResult<PacageScanVO> scanPackage(@Valid @RequestBody PackingPDASearchQO request) {
|
||||
// 首先判断当前包是否已经收货了
|
||||
PacageScanVO pacageScanVO = wmsPackageService.getPackageInfo(request.getPackageCode());
|
||||
VUtil.trueThrowBusinessError(ObjectUtil.isNull(pacageScanVO)).throwMessage("打包码不存在");
|
||||
VUtil.trueThrowBusinessError(pacageScanVO.getPackageStatus() == 0).throwMessage("此打包码尚未打包");
|
||||
VUtil.trueThrowBusinessError(pacageScanVO.getPackageStatus() == 2).throwMessage("此打包码已收货");
|
||||
|
||||
return ApiResult.success(pacageScanVO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取打包码对应的送货单信息
|
||||
* @param request
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("getPackageOrders")
|
||||
@ApiMark(moduleName = "获取打包码对应的送货单信息", apiName = "获取打包码对应的送货单信息")
|
||||
public ApiResult<List<PacagePoVO>> getPackageOrders(@Valid @RequestBody FilterIdQO request) {
|
||||
return ApiResult.success(wmsPackageService.getPackageOrders(request.getId()));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据送货单单号和大码的ID获取到具体的物料信息
|
||||
* @param request
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("getPackageOrderItems")
|
||||
@ApiMark(moduleName = "根据送货单单号和大码的ID获取到具体的物料信息", apiName = "根据送货单单号和大码的ID获取到具体的物料信息")
|
||||
public ApiResult<List<PacagePoItemVO>> scanPackage(@Valid @RequestBody PackagePoSearchQO request) {
|
||||
return ApiResult.success(wmsPackageService.getPackageOrderItems(request.getPackageId(), request.getDeliveryNo()));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据送货单单号和大码的ID获取到具体的物料信息
|
||||
* @param request id= 大码的ID
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("getPackageOrderItems")
|
||||
@ApiMark(moduleName = "根据送货单单号和大码的ID获取到具体的物料信息", apiName = "根据送货单单号和大码的ID获取到具体的物料信息")
|
||||
public ApiResult<List<PendingScanningVO>> scanPackage(@Valid @RequestBody FilterIdQO request) {
|
||||
List<PendingScanningVO> list = wmsPackageService.getPendingScannings(request.getId());
|
||||
if (CollectionUtil.isNotEmpty(list)) {
|
||||
list.forEach(vo -> {
|
||||
if (vo.getIsCounting() != null && vo.getIsCounting() == 0) {
|
||||
vo.setPendingScanQuantity(vo.getPackingQuantity());
|
||||
}
|
||||
});
|
||||
}
|
||||
return ApiResult.success(list);
|
||||
}
|
||||
|
||||
@PostMapping("takeDeliveryConfirmUnScan")
|
||||
@ApiMark(moduleName = "无需扫码收货", apiName = "无需扫码收货")
|
||||
public ApiResult<Void> takeDeliveryConfirmUnScan(@Valid @RequestBody PendingUnScanningQO request) {
|
||||
VUtil.trueThrowBusinessError(request.getBarcodeIds().stream().distinct().count() != request.getBarcodeIds().size()).throwMessage("存在重复的码");
|
||||
// 重新验证所有码的合法性 1、是否是已打包未收货的状态;2、是否全部是已启用储位管理的状态
|
||||
List<PacageScanVO> pacageScanVO = wmsPackageService.getPackageInfos(request.getBarcodeIds());
|
||||
VUtil.trueThrowBusinessError(CollectionUtil.isEmpty(pacageScanVO)).throwMessage("打包码不存在");
|
||||
|
||||
long count = pacageScanVO.stream()
|
||||
.filter(pkg -> Objects.equals(pkg.getPackageStatus(), (short) 0))
|
||||
.count();
|
||||
VUtil.trueThrowBusinessError(count >= 0).throwMessage("存在尚未打包的码");
|
||||
long count1 = pacageScanVO.stream()
|
||||
.filter(pkg -> Objects.equals(pkg.getPackageStatus(), (short) 2))
|
||||
.count();
|
||||
VUtil.trueThrowBusinessError(count1 >= 0).throwMessage("存在已经收货的码");
|
||||
|
||||
long count2 = pacageScanVO.stream()
|
||||
.filter(pkg -> Objects.equals(pkg.getIsCounting(), 1))
|
||||
.count();
|
||||
VUtil.trueThrowBusinessError(count2 >= 0).throwMessage("存在必须扫码的包装");
|
||||
List<PendingScanningItemDTO> items = wmsPackageService.getScanningItems(request.getBarcodeIds());
|
||||
//对箱码要做出来,将箱码换成对应的物料码
|
||||
List<>
|
||||
|
||||
//根据包装信息获取对应的物料收货信息
|
||||
List<SrmMaterialReceiptQO> receiptQOS = new ArrayList<>();
|
||||
//首先要对上面的信息 按照 srmId进行分组,汇总quantity
|
||||
|
||||
for (PendingScanningItemDTO item : items)
|
||||
{
|
||||
SrmMaterialReceiptQO qo = new SrmMaterialReceiptQO()
|
||||
.setNoteNum(item.getDeliveryNo())
|
||||
.setLineNumber(item.getDeliveryLineNo())
|
||||
.setPoNum(item.getPoNumber())
|
||||
.setPoLineNumber(item.getPoLineNumber())
|
||||
.setItemCode(item.getMaterialCode())
|
||||
.setId(item.getSrmId())
|
||||
.setReceiptNum(item.getQuantity());
|
||||
|
||||
// .setScanCodes(item.getScanCodes());
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@PostMapping("takeDeliveryConfirmByScan")
|
||||
@ApiMark(moduleName = "需扫码收货", apiName = "需扫码收货")
|
||||
public ApiResult<Void> takeDeliveryConfirmByScan(@Valid @RequestBody List<PendingScanningQO> request) {
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,68 @@
|
|||
package com.nflg.wms.common.pojo.dto;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class PendingScanningItemDTO {
|
||||
/**
|
||||
* 待扫描的包装物ID
|
||||
*/
|
||||
private Long id;
|
||||
/**
|
||||
* 待扫描的包装物条码
|
||||
*/
|
||||
private String barcodeCode;
|
||||
/**
|
||||
* 待扫描的包装物数量
|
||||
*/
|
||||
private BigDecimal quantity;
|
||||
/**
|
||||
* 待扫描的包装物物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
/**
|
||||
* 待扫描的包装物包装类型 0 物料;1 箱
|
||||
*/
|
||||
private short packagingType;
|
||||
/**
|
||||
* 待扫描的包装物PO单号
|
||||
*/
|
||||
private String poNumber;
|
||||
/**
|
||||
* 待扫描的包装物PO行号
|
||||
*/
|
||||
private String poLineNumber;
|
||||
/**
|
||||
* 待扫描的包装物收货单号
|
||||
*/
|
||||
private String deliveryNo;
|
||||
/**
|
||||
* 待扫描的包装物收货单行号
|
||||
*/
|
||||
private String deliveryLineNo;
|
||||
/**
|
||||
* 待扫描的包装物单位
|
||||
*/
|
||||
private String unit;
|
||||
/**
|
||||
* 待扫描的包装物序列号
|
||||
*/
|
||||
private String serialNo;
|
||||
/**
|
||||
* 待扫描的包装物批次号
|
||||
*/
|
||||
private String batchNo;
|
||||
/**
|
||||
* 待扫描的包装物物料描述
|
||||
*/
|
||||
private String materialDescription;
|
||||
|
||||
/**
|
||||
* srm传入的送货单项ID
|
||||
*/
|
||||
private Long srmId;
|
||||
}
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
package com.nflg.wms.common.pojo.qo;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class PackagePoSearchQO {
|
||||
/**
|
||||
* 包ID
|
||||
*/
|
||||
private Long packageId;
|
||||
/**
|
||||
* 送货单号
|
||||
*/
|
||||
private String deliveryNo;
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
package com.nflg.wms.common.pojo.qo;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class PendingScanningQO {
|
||||
/**
|
||||
* 物料二维码ID
|
||||
*/
|
||||
private Long barcodeId;
|
||||
|
||||
/**
|
||||
* 待扫数量
|
||||
*/
|
||||
private BigDecimal pendingScanQuantity;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
package com.nflg.wms.common.pojo.qo;
|
||||
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class PendingUnScanningQO {
|
||||
/**
|
||||
* 包装物ID
|
||||
*/
|
||||
private List<Long> barcodeIds;
|
||||
}
|
||||
|
|
@ -28,6 +28,10 @@ public class PacageScanVO {
|
|||
*/
|
||||
private String packageName;
|
||||
|
||||
/**
|
||||
* 状态 0 未打包;1 已打包;2 已收货
|
||||
*/
|
||||
private Short packageStatus;
|
||||
|
||||
/**
|
||||
* 是否需要点数 0 不需要点数;1 需要点数
|
||||
|
|
|
|||
|
|
@ -83,4 +83,8 @@ public class PendingScanningVO {
|
|||
*/
|
||||
private String deliveryLineNo;
|
||||
|
||||
/**
|
||||
* 是否需要点数 0 不需要点数;1 需要点数
|
||||
*/
|
||||
private Integer isCounting;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,10 +4,10 @@ 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.PageData;
|
||||
import com.nflg.wms.common.pojo.dto.PendingScanningItemDTO;
|
||||
import com.nflg.wms.common.pojo.qo.PackingQO;
|
||||
import com.nflg.wms.common.pojo.qo.PackingSearchQO;
|
||||
import com.nflg.wms.common.pojo.vo.PackingItemPDAVO;
|
||||
import com.nflg.wms.common.pojo.vo.PackingVO;
|
||||
import com.nflg.wms.common.pojo.vo.*;
|
||||
import com.nflg.wms.repository.entity.WmsPackage;
|
||||
|
||||
import java.util.List;
|
||||
|
|
@ -27,4 +27,16 @@ public interface WmsPackageMapper extends BaseMapper<WmsPackage> {
|
|||
IPage<PackingVO> search(PackingSearchQO request, Page<Object> objectPage);
|
||||
|
||||
List<PackingItemPDAVO> getChildPackageContent(Long id);
|
||||
|
||||
PacageScanVO getPackageInfo(String packageCode);
|
||||
|
||||
List<PacagePoVO> getPackageOrders(Long id);
|
||||
|
||||
List<PacagePoItemVO> getPackageOrderItems(Long packageId, String deliveryNo);
|
||||
|
||||
List<PendingScanningVO> getPendingScannings(Long id);
|
||||
|
||||
List<PacageScanVO> getPackageInfos(List<Long> barcodeIds);
|
||||
|
||||
List<PendingScanningItemDTO> getScanningItems(List<Long> barcodeIds);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,10 +2,10 @@ 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.dto.PendingScanningItemDTO;
|
||||
import com.nflg.wms.common.pojo.qo.PackingQO;
|
||||
import com.nflg.wms.common.pojo.qo.PackingSearchQO;
|
||||
import com.nflg.wms.common.pojo.vo.PackingItemPDAVO;
|
||||
import com.nflg.wms.common.pojo.vo.PackingVO;
|
||||
import com.nflg.wms.common.pojo.vo.*;
|
||||
import com.nflg.wms.repository.entity.WmsPackage;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.nflg.wms.repository.entity.WmsPackageItem;
|
||||
|
|
@ -35,4 +35,16 @@ public interface IWmsPackageService extends IService<WmsPackage> {
|
|||
IPage<PackingVO> serach(@Valid PackingSearchQO request);
|
||||
|
||||
List<PackingItemPDAVO> getChildPackageContent(@NotNull Long id);
|
||||
|
||||
PacageScanVO getPackageInfo(String packageCode);
|
||||
|
||||
List<PacagePoVO> getPackageOrders(@NotNull Long id);
|
||||
|
||||
List<PacagePoItemVO> getPackageOrderItems(Long packageId, String deliveryNo);
|
||||
|
||||
List<PendingScanningVO> getPendingScannings(@NotNull Long id);
|
||||
|
||||
List<PacageScanVO> getPackageInfos(List<Long> barcodeIds);
|
||||
|
||||
List<PendingScanningItemDTO> getScanningItems(List<Long> barcodeIds);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,10 +6,10 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
|
|||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.nflg.wms.common.constant.BarCodeProcessStage;
|
||||
import com.nflg.wms.common.pojo.PageData;
|
||||
import com.nflg.wms.common.pojo.dto.PendingScanningItemDTO;
|
||||
import com.nflg.wms.common.pojo.qo.PackingQO;
|
||||
import com.nflg.wms.common.pojo.qo.PackingSearchQO;
|
||||
import com.nflg.wms.common.pojo.vo.PackingItemPDAVO;
|
||||
import com.nflg.wms.common.pojo.vo.PackingVO;
|
||||
import com.nflg.wms.common.pojo.vo.*;
|
||||
import com.nflg.wms.repository.entity.WmsPackage;
|
||||
import com.nflg.wms.repository.entity.WmsPackageItem;
|
||||
import com.nflg.wms.repository.entity.WmsQrCodeMaster;
|
||||
|
|
@ -107,5 +107,35 @@ public class WmsPackageServiceImpl extends ServiceImpl<WmsPackageMapper, WmsPack
|
|||
return baseMapper.getChildPackageContent(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PacageScanVO getPackageInfo(String packageCode) {
|
||||
return baseMapper.getPackageInfo(packageCode);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PacagePoVO> getPackageOrders(Long id) {
|
||||
return baseMapper.getPackageOrders(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PacagePoItemVO> getPackageOrderItems(Long packageId, String deliveryNo) {
|
||||
return baseMapper.getPackageOrderItems(packageId, deliveryNo);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PendingScanningVO> getPendingScannings(Long id) {
|
||||
return baseMapper.getPendingScannings(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PacageScanVO> getPackageInfos(List<Long> barcodeIds) {
|
||||
return baseMapper.getPackageInfos(barcodeIds);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PendingScanningItemDTO> getScanningItems(List<Long> barcodeIds) {
|
||||
return baseMapper.getScanningItems(barcodeIds);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
|
||||
<select id="search" resultType="com.nflg.wms.common.pojo.vo.PackingVO">
|
||||
select a.*,b.supplier_code,b.supplier_name from wms_package a
|
||||
left join user_supplier b on a.supplier_id=b."id"
|
||||
left join user_supplier b on a.supplier_id=b."id"
|
||||
<where>
|
||||
<if test="request.packingCode !=null and request.packingCode !=''">
|
||||
and a.package_code ilike concat('%', #{request.packingCode}, '%')
|
||||
|
|
@ -58,7 +58,7 @@
|
|||
po_number,
|
||||
po_line_number,
|
||||
delivery_no,
|
||||
delivery_line_no ,
|
||||
delivery_line_no,
|
||||
create_user_name,
|
||||
create_time,
|
||||
unit,
|
||||
|
|
@ -68,4 +68,111 @@
|
|||
from wms_qr_code_master
|
||||
where parent_barcode_id = #{id}
|
||||
</select>
|
||||
|
||||
<select id="getPackageInfo" resultType="com.nflg.wms.common.pojo.vo.PacageScanVO">
|
||||
select a.id,
|
||||
a.package_code,
|
||||
a.package_name,
|
||||
c.supplier_name,
|
||||
min(case when e.is_disable_location = true then 0 else 1 end) as is_counting, a.package_status
|
||||
from wms_package a
|
||||
left join wms_package_item b on a.id = b.package_id
|
||||
left join user_supplier c on a.supplier_id = c.id
|
||||
left join wms_qr_code_master d on b.barcode_code = d.barcode_code
|
||||
left join wms_warehouse e on d.storage_location = e."no"
|
||||
where a.package_code = #{packageCode}
|
||||
group by a.id, a.package_code, a.package_name, c.supplier_name, a.package_status
|
||||
</select>
|
||||
|
||||
|
||||
<select id="getPackageOrders" resultType="com.nflg.wms.common.pojo.vo.PacagePoVO">
|
||||
select b.delivery_no,
|
||||
c.supplier_name,
|
||||
min(case when e.is_disable_location = true then 0 else 1 end) as is_counting
|
||||
from wms_package a
|
||||
left join wms_package_item b on a.id = b.package_id
|
||||
left join user_supplier c on a.supplier_id = c.id
|
||||
left join wms_qr_code_master d on b.barcode_code = d.barcode_code
|
||||
left join wms_warehouse e on d.storage_location = e."no"
|
||||
where a.id = #{id}
|
||||
group by b.delivery_no, c.supplier_name
|
||||
</select>
|
||||
|
||||
<select id="getPackageOrderItems" resultType="com.nflg.wms.common.pojo.vo.PacagePoItemVO">
|
||||
select a.*, case when e.is_disable_location = true then 0 else 1 end as is_counting
|
||||
from wms_srm_order_item a
|
||||
left join wms_package_item b
|
||||
on a.note_num = b.delivery_no and b.delivery_line_no = a.line_number
|
||||
left join wms_qr_code_master d on b.barcode_code = d.barcode_code
|
||||
left join wms_warehouse e on d.storage_location = e."no"
|
||||
where a.note_num = #{deliveryNo}
|
||||
and b.package_id = #{packageId}
|
||||
</select>
|
||||
|
||||
<select id="getPendingScannings" resultType="com.nflg.wms.common.pojo.vo.PendingScanningVO">
|
||||
select a.id as barcode_id,
|
||||
a.barcode_code,
|
||||
b.material_code,
|
||||
b.material_description,
|
||||
case when b.packaging_type = 0 then b.quantity else sum(f.quantity) end as packing_quantity,
|
||||
b.unit,
|
||||
c.supplier_name,
|
||||
b.po_number,
|
||||
b.po_line_number,
|
||||
b.packaging_type,
|
||||
f.parent_barcode_id,
|
||||
b.delivery_no,
|
||||
b.delivery_line_no,
|
||||
min(case when e.is_disable_location = true then 0 else 1 end) as is_counting
|
||||
from wms_package_item a
|
||||
left join wms_qr_code_master b on a.barcode_code = b.barcode_code
|
||||
left join wms_qr_code_master f on b.id = f.parent_barcode_id
|
||||
left join wms_warehouse e on b.storage_location = e."no"
|
||||
left join user_supplier c on b.supplier_code = c.supplier_code
|
||||
where a.package_id = #{id}
|
||||
group by a.id, a.barcode_code, b.material_code, b.material_description, b.quantity, b.unit, c.supplier_name,
|
||||
b.po_number, b.po_line_number, b.packaging_type, f.parent_barcode_id, b.delivery_no, b.delivery_line_no
|
||||
</select>
|
||||
|
||||
<select id="getPackageInfos" resultType="com.nflg.wms.common.pojo.vo.PacageScanVO">
|
||||
select a.id,
|
||||
a.package_code,
|
||||
a.package_name,
|
||||
c.supplier_name,
|
||||
min(case when e.is_disable_location = true then 0 else 1 end) as is_counting, a.package_status
|
||||
from wms_package a
|
||||
left join wms_package_item b on a.id = b.package_id
|
||||
left join user_supplier c on a.supplier_id = c.id
|
||||
left join wms_qr_code_master d on b.barcode_code = d.barcode_code
|
||||
left join wms_warehouse e on d.storage_location = e."no"
|
||||
where a.id in
|
||||
<foreach item="id" collection="barcodeIds" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
group by a.id, a.package_code, a.package_name, c.supplier_name, a.package_status
|
||||
</select>
|
||||
|
||||
<select id="getScanningItems" resultType="com.nflg.wms.common.pojo.dto.PendingScanningItemDTO">
|
||||
select a.id,
|
||||
a.barcode_code,
|
||||
b.quantity,
|
||||
b.material_code,
|
||||
b.packaging_type,
|
||||
b.po_number,
|
||||
b.po_line_number,
|
||||
b.delivery_no,
|
||||
b.delivery_line_no,
|
||||
b.unit,
|
||||
b.serial_no,
|
||||
b.batch_no,
|
||||
b.material_description,
|
||||
c.id as srm_id
|
||||
from wms_package_item a
|
||||
left join wms_qr_code_master b on a.barcode_code = b.barcode_code
|
||||
left join wms_srm_order_item c on b.delivery_no=c.note_num and b.delivery_line_no=c.line_number
|
||||
where a.package_id in
|
||||
<foreach item="id" collection="barcodeIds" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
|
|||
Loading…
Reference in New Issue