demand: tms-运输管理-货物组批次-新增/修改组批次校验件数、重量体积时只校验运输号相同的 tms-运输管理-货物组批次-查询批次详情接口-查询运单剩余件数、重量、体积时只查询运输号相同的
This commit is contained in:
parent
f80f9983ec
commit
7de119b530
@ -1,10 +1,10 @@
|
||||
/**
|
||||
/**
|
||||
* @Project: emis
|
||||
* @Title: EmisTmsSiteBatchMapper.java
|
||||
* @author linfso
|
||||
* @date 2024-03-01 08:54:56
|
||||
* @Copyright: ShangHai Doitinfo 2022 All rights reserved.
|
||||
* @version v1.0
|
||||
* @version v1.0
|
||||
* @Description: <p> 一级网点TMS组批次 Mapper 接口 </p>
|
||||
* <span style='color:red'> Warning : This file is generate by ai tools,don't edit!!! </span>
|
||||
*/
|
||||
@ -29,13 +29,13 @@ public interface EmisTmsSiteBatchMapper extends BaseMapper<EmisTmsSiteBatch>
|
||||
/**
|
||||
* 主键查询
|
||||
* @param id
|
||||
* @return
|
||||
* @return
|
||||
*/
|
||||
public EmisTmsSiteBatch selectEmisTmsSiteBatchById(Long id);
|
||||
|
||||
/**
|
||||
* 主键查询(包含明细和装载信息)
|
||||
*
|
||||
*
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@ -48,8 +48,8 @@ public interface EmisTmsSiteBatchMapper extends BaseMapper<EmisTmsSiteBatch>
|
||||
|
||||
/**
|
||||
* 查询列表
|
||||
*
|
||||
* @param emisTmsSiteBatch
|
||||
*
|
||||
* @param emisTmsSiteBatch
|
||||
* @return 集合
|
||||
*/
|
||||
public List<EmisTmsSiteBatch> selectEmisTmsSiteBatchList(EmisTmsSiteBatch emisTmsSiteBatch);
|
||||
@ -64,25 +64,25 @@ public interface EmisTmsSiteBatchMapper extends BaseMapper<EmisTmsSiteBatch>
|
||||
public List<EmisTmsSiteBatch> selectWaitDoProfitList(EmisTmsSiteBatch emisTmsSiteBatch);
|
||||
|
||||
/**
|
||||
* 新增
|
||||
*
|
||||
* 新增
|
||||
*
|
||||
* @param emisTmsSiteBatch
|
||||
* @return
|
||||
* @return
|
||||
*/
|
||||
public int insertEmisTmsSiteBatch(EmisTmsSiteBatch emisTmsSiteBatch);
|
||||
|
||||
/**
|
||||
* 修改
|
||||
*
|
||||
* @param emisTmsSiteBatch
|
||||
* @return
|
||||
*
|
||||
* @param emisTmsSiteBatch
|
||||
* @return
|
||||
*/
|
||||
@DataAuditLog(operateType= OperateType.UPDATE,serviceClass= EmisTmsSiteBatchServiceImpl.class)
|
||||
public int updateEmisTmsSiteBatch(EmisTmsSiteBatch emisTmsSiteBatch);
|
||||
|
||||
/**
|
||||
* 删除
|
||||
*
|
||||
*
|
||||
* @param id 主键
|
||||
* @return 结果
|
||||
*/
|
||||
@ -90,7 +90,7 @@ public interface EmisTmsSiteBatchMapper extends BaseMapper<EmisTmsSiteBatch>
|
||||
|
||||
/**
|
||||
* 批量删除
|
||||
*
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
@ -119,7 +119,7 @@ public interface EmisTmsSiteBatchMapper extends BaseMapper<EmisTmsSiteBatch>
|
||||
|
||||
/**
|
||||
* 根据运单号列表查询组批次信息
|
||||
*
|
||||
*
|
||||
* @param billCodes 运单号列表
|
||||
* @return 组批次信息列表
|
||||
*/
|
||||
@ -130,13 +130,16 @@ public interface EmisTmsSiteBatchMapper extends BaseMapper<EmisTmsSiteBatch>
|
||||
*
|
||||
* @param startSiteCode 起始网点编码
|
||||
* @param nextSiteCode 下一网点编码
|
||||
* @param carNo 运输号
|
||||
* @param billCode 运单号
|
||||
* @param id
|
||||
* @return TMS组批次列表
|
||||
*/
|
||||
List<EmisTmsSiteBatch> selectTmsSiteBatchBySiteAndBillCode(@Param("startSiteCode") String startSiteCode,
|
||||
List<EmisTmsSiteBatch> selectTmsSiteBatchBySiteAndBillCode(
|
||||
@Param("startSiteCode") String startSiteCode,
|
||||
@Param("nextSiteCode") String nextSiteCode,
|
||||
@Param("billCode") String billCode, @Param("id")Long id);
|
||||
@Param("carNo") String carNo,
|
||||
@Param("billCode") String billCode, @Param("id") Long id);
|
||||
|
||||
/**
|
||||
* 验重
|
||||
|
||||
@ -46,12 +46,14 @@ public interface IEmisTmsSiteBatchService extends IDataAuditService
|
||||
*
|
||||
* @param startSiteCode 起始网点编码
|
||||
* @param nextSiteCode 下一网点编码
|
||||
* @param carNo
|
||||
* @param billCode 运单号
|
||||
* @param id
|
||||
* @return TMS组批次列表
|
||||
*/
|
||||
public List<EmisTmsSiteBatch> selectTmsSiteBatchBySiteAndBillCode(String startSiteCode, String nextSiteCode,
|
||||
String billCode, Long id);
|
||||
public List<EmisTmsSiteBatch> selectTmsSiteBatchBySiteAndBillCode(
|
||||
String startSiteCode, String nextSiteCode,
|
||||
String carNo, String billCode, Long id);
|
||||
|
||||
/**
|
||||
* 查询一级网点TMS组批次列表
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
/**
|
||||
/**
|
||||
* @Project: emis
|
||||
* @Title: EmisTmsSiteBatchDtlServiceImpl.java
|
||||
* @author linfso
|
||||
* @date 2024-03-01 08:54:57
|
||||
* @Copyright: ShangHai Duta 2022 All rights reserved.
|
||||
* @version v1.0
|
||||
* @version v1.0
|
||||
* @Description: <p> 一级网点TMS组批次明细 实体类 </p>
|
||||
*/
|
||||
|
||||
@ -34,7 +34,7 @@ import com.xdadan.erp.emis.service.IEmisTmsSiteBatchDtlService;
|
||||
|
||||
/**
|
||||
* 一级网点TMS组批次明细Service业务层处理
|
||||
*
|
||||
*
|
||||
* @author linfso
|
||||
* @date 2024-03-01 08:54:57
|
||||
*/
|
||||
@ -57,7 +57,7 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
|
||||
/**
|
||||
* 查询一级网点TMS组批次明细
|
||||
*
|
||||
*
|
||||
* @param id 一级网点TMS组批次明细主键
|
||||
* @return 一级网点TMS组批次明细
|
||||
*/
|
||||
@ -68,7 +68,7 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
|
||||
/**
|
||||
* 查询一级网点TMS组批次明细列表
|
||||
*
|
||||
*
|
||||
* @param emisTmsSiteBatchDtl 一级网点TMS组批次明细
|
||||
* @return 一级网点TMS组批次明细
|
||||
*/
|
||||
@ -93,7 +93,7 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
|
||||
/**
|
||||
* 新增一级网点TMS组批次明细
|
||||
*
|
||||
*
|
||||
* @param emisTmsSiteBatchDtl 一级网点TMS组批次明细
|
||||
* @return 结果
|
||||
*/
|
||||
@ -107,7 +107,7 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
|
||||
/**
|
||||
* 修改一级网点TMS组批次明细
|
||||
*
|
||||
*
|
||||
* @param emisTmsSiteBatchDtl 一级网点TMS组批次明细
|
||||
* @return 结果
|
||||
*/
|
||||
@ -118,7 +118,7 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
|
||||
/**
|
||||
* 批量删除一级网点TMS组批次明细
|
||||
*
|
||||
*
|
||||
* @param ids 需要删除的一级网点TMS组批次明细主键
|
||||
* @return 结果
|
||||
*/
|
||||
@ -129,7 +129,7 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
|
||||
/**
|
||||
* 删除一级网点TMS组批次明细信息
|
||||
*
|
||||
*
|
||||
* @param id 一级网点TMS组批次明细主键
|
||||
* @return 结果
|
||||
*/
|
||||
@ -149,6 +149,7 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
String batchNo = emisTmsSiteBatchDtl.getBatchNo();
|
||||
String startSiteCode = (String) emisTmsSiteBatchDtl.getParams().get("startSiteCode");
|
||||
String nextSiteCode = (String) emisTmsSiteBatchDtl.getParams().get("nextSiteCode");
|
||||
String carNo = (String) emisTmsSiteBatchDtl.getParams().get("carNo");
|
||||
String supplierCode = (String) emisTmsSiteBatchDtl.getParams().get("supplierCode");
|
||||
|
||||
// 参数校验
|
||||
@ -161,6 +162,9 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
if (StringUtils.isBlank(nextSiteCode)) {
|
||||
throw new EmisBizError(EmisBizErrorType.FAIL, "下一网点编码不能为空");
|
||||
}
|
||||
if (StringUtils.isBlank(carNo)) {
|
||||
throw new EmisBizError(EmisBizErrorType.FAIL, "运输号不能为空");
|
||||
}
|
||||
|
||||
// 查询运单信息
|
||||
EmisWaybill emisWaybill = emisWaybillMapper.selectEmisWaybillByBillCode(billCode);
|
||||
@ -200,6 +204,7 @@ public class EmisTmsSiteBatchDtlServiceImpl implements IEmisTmsSiteBatchDtlServi
|
||||
List<EmisTmsSiteBatch> existingBatches = emisTmsSiteBatchMapper.selectTmsSiteBatchBySiteAndBillCode(
|
||||
startSiteCode,
|
||||
nextSiteCode,
|
||||
carNo,
|
||||
billCode,
|
||||
null);
|
||||
|
||||
|
||||
@ -111,8 +111,8 @@ public class EmisTmsSiteBatchServiceImpl extends EmisBaseService implements IEmi
|
||||
|
||||
@Override
|
||||
public List<EmisTmsSiteBatch> selectTmsSiteBatchBySiteAndBillCode(String startSiteCode, String nextSiteCode,
|
||||
String billCode, Long id) {
|
||||
return emisTmsSiteBatchMapper.selectTmsSiteBatchBySiteAndBillCode(startSiteCode, nextSiteCode, billCode, id);
|
||||
String carNo, String billCode, Long id) {
|
||||
return emisTmsSiteBatchMapper.selectTmsSiteBatchBySiteAndBillCode(startSiteCode, nextSiteCode, carNo, billCode, id);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -209,6 +209,7 @@ public class EmisTmsSiteBatchServiceImpl extends EmisBaseService implements IEmi
|
||||
List<EmisTmsSiteBatch> existingBatches = selectTmsSiteBatchBySiteAndBillCode(
|
||||
oldSiteBatch.getStartSiteCode(),
|
||||
oldSiteBatch.getNextSiteCode(),
|
||||
oldSiteBatch.getCarNo(),
|
||||
itemDtl.getBillCode(), itemDtl.getId());
|
||||
if (itemDtl.getId() != null) {
|
||||
existingBatches = existingBatches.stream().filter(i -> !itemDtl.getBatchNo().equals(i.getBatchNo()))
|
||||
|
||||
@ -577,6 +577,9 @@
|
||||
left join emis_waybill w on d.bill_code = w.bill_code and w.del_flag = '0'
|
||||
where b.start_site_code = #{startSiteCode}
|
||||
and b.next_site_code = #{nextSiteCode}
|
||||
<if test="carNo != null and carNo != ''">
|
||||
and b.car_no = #{carNo}
|
||||
</if>
|
||||
and d.bill_code = #{billCode}
|
||||
and b.del_flag = '0'
|
||||
and d.del_flag = '0'
|
||||
|
||||
Loading…
Reference in New Issue
Block a user