1.修复盘点转单条码绑定多个供应商时自动绑定的问题

2.修复更新单据备注信息无效问题
zhairh
x_z 2 years ago committed by wangwei
parent 95a2747c09
commit be6e05d87c

@ -32,7 +32,9 @@ import com.glxp.api.admin.req.business.StockOrderIdsRequest;
import com.glxp.api.admin.req.business.StockOrderPostRequest; import com.glxp.api.admin.req.business.StockOrderPostRequest;
import com.glxp.api.admin.req.inout.AddStockOrderChangeRequest; import com.glxp.api.admin.req.inout.AddStockOrderChangeRequest;
import com.glxp.api.admin.req.inout.DeleteRequest; import com.glxp.api.admin.req.inout.DeleteRequest;
import com.glxp.api.admin.req.inventory.*; import com.glxp.api.admin.req.inventory.FilterInvUserRequest;
import com.glxp.api.admin.req.inventory.InnerOrderDetailRequest;
import com.glxp.api.admin.req.inventory.PostStockPrintRequest;
import com.glxp.api.admin.res.PageSimpleResponse; import com.glxp.api.admin.res.PageSimpleResponse;
import com.glxp.api.admin.res.basic.UdiRelevanceResponse; import com.glxp.api.admin.res.basic.UdiRelevanceResponse;
import com.glxp.api.admin.res.business.StockOrderExportResponse; import com.glxp.api.admin.res.business.StockOrderExportResponse;
@ -48,7 +50,6 @@ import com.glxp.api.admin.service.business.StockOrderDetailService;
import com.glxp.api.admin.service.business.StockOrderDetailTempService; import com.glxp.api.admin.service.business.StockOrderDetailTempService;
import com.glxp.api.admin.service.business.StockOrderService; import com.glxp.api.admin.service.business.StockOrderService;
import com.glxp.api.admin.service.business.StockQRCodeTextService; import com.glxp.api.admin.service.business.StockQRCodeTextService;
import com.glxp.api.admin.service.info.CompanyService;
import com.glxp.api.admin.service.info.SystemParamConfigService; import com.glxp.api.admin.service.info.SystemParamConfigService;
import com.glxp.api.admin.service.inout.CodesService; import com.glxp.api.admin.service.inout.CodesService;
import com.glxp.api.admin.service.inout.CodesTempService; import com.glxp.api.admin.service.inout.CodesTempService;
@ -328,9 +329,12 @@ public class StockOrderController {
//判断订单是否可以补单 //判断订单是否可以补单
List<StockOrderResponse> resultList = orderService.checkSupplementOrder(stockOrderEntityList); List<StockOrderResponse> resultList = orderService.checkSupplementOrder(stockOrderEntityList);
//查询补单设置
orderService.checkSubmitOrder(resultList);
//查询仓库名称 //查询仓库名称
orderService.queryInvName(resultList); orderService.queryInvName(resultList);
resultList = orderService.checkSubmitOrder(resultList); //查询单据备注
orderService.queryPrintRemark(resultList);
PageSimpleResponse<StockOrderResponse> pageSimpleResponse = new PageSimpleResponse<>(); PageSimpleResponse<StockOrderResponse> pageSimpleResponse = new PageSimpleResponse<>();
pageSimpleResponse.setTotal(pageInfo.getTotal()); pageSimpleResponse.setTotal(pageInfo.getTotal());
pageSimpleResponse.setList(resultList); pageSimpleResponse.setList(resultList);

@ -19,7 +19,10 @@ import com.glxp.api.admin.entity.basic.EntrustReceEntity;
import com.glxp.api.admin.entity.basic.UdiEntity; import com.glxp.api.admin.entity.basic.UdiEntity;
import com.glxp.api.admin.entity.business.StockOrderEntity; import com.glxp.api.admin.entity.business.StockOrderEntity;
import com.glxp.api.admin.entity.info.SystemParamConfigEntity; import com.glxp.api.admin.entity.info.SystemParamConfigEntity;
import com.glxp.api.admin.entity.inout.*; import com.glxp.api.admin.entity.inout.ErpOrderEntity;
import com.glxp.api.admin.entity.inout.FilterErpOrderRequest;
import com.glxp.api.admin.entity.inout.OrderEntity;
import com.glxp.api.admin.entity.inout.WarehouseEntity;
import com.glxp.api.admin.entity.inventory.InvBusUserEntity; import com.glxp.api.admin.entity.inventory.InvBusUserEntity;
import com.glxp.api.admin.entity.inventory.InvWarehouseEntity; import com.glxp.api.admin.entity.inventory.InvWarehouseEntity;
import com.glxp.api.admin.httpclient.SpsDirectClient; import com.glxp.api.admin.httpclient.SpsDirectClient;
@ -27,7 +30,6 @@ import com.glxp.api.admin.req.basic.BasicEntrustRecRequest;
import com.glxp.api.admin.req.business.StockOrderFilterRequest; import com.glxp.api.admin.req.business.StockOrderFilterRequest;
import com.glxp.api.admin.req.inout.*; import com.glxp.api.admin.req.inout.*;
import com.glxp.api.admin.req.inventory.FilterInvBusUserRequest; import com.glxp.api.admin.req.inventory.FilterInvBusUserRequest;
import com.glxp.api.admin.req.inventory.FilterInvUserRequest;
import com.glxp.api.admin.req.inventory.FilterInvWarehouseRequest; import com.glxp.api.admin.req.inventory.FilterInvWarehouseRequest;
import com.glxp.api.admin.req.receipt.BussinessTypeFilterRequest; import com.glxp.api.admin.req.receipt.BussinessTypeFilterRequest;
import com.glxp.api.admin.res.PageSimpleResponse; import com.glxp.api.admin.res.PageSimpleResponse;
@ -207,6 +209,25 @@ public class OrderController {
return ResultVOUtils.success("更新成功"); return ResultVOUtils.success("更新成功");
} }
/**
*
*
* @param orderEntity
* @param bindingResult
* @return
*/
@PostMapping("/udiwms/inout/order/updateOrderPrintRemark")
public BaseResponse updateOrderRemark(@RequestBody OrderEntity orderEntity, BindingResult bindingResult) {
if (bindingResult.hasErrors()) {
return ResultVOUtils.error(ResultEnum.PARAM_VERIFY_FALL, bindingResult.getFieldError().getDefaultMessage());
}
boolean b = orderService.updatePrintRemark(orderEntity.getId(), orderEntity.getPrintRemark());
if (!b) {
return ResultVOUtils.error(500, "单据备注更新失败!");
}
return ResultVOUtils.success("更新成功");
}
@AuthRuleAnnotation("") @AuthRuleAnnotation("")
@PostMapping("/udiwms/inout/order/updateUnit") @PostMapping("/udiwms/inout/order/updateUnit")

@ -98,7 +98,7 @@ public class InvSpaceController {
*/ */
@GetMapping("/spms/inv/space/getSpaceCodeList") @GetMapping("/spms/inv/space/getSpaceCodeList")
public BaseResponse getSpaceCodeList(FilterInvSpaceRequest filterInvSpaceRequest) { public BaseResponse getSpaceCodeList(FilterInvSpaceRequest filterInvSpaceRequest) {
List<InvSpace> list = invSpaceService.getSpaceCodeList(filterInvSpaceRequest); List<InvSpaceResponse> list = invSpaceService.getSpaceCodeList(filterInvSpaceRequest);
return ResultVOUtils.success(list); return ResultVOUtils.success(list);
} }

@ -35,4 +35,12 @@ public interface CompanyProductRelevanceDao {
boolean deleteById(String id); boolean deleteById(String id);
boolean deleteByRlId(String id); boolean deleteByRlId(String id);
/**
* IDID
*
* @param udiRlIdFk
* @return
*/
List<String> selectUnitFkByUdiRlIdFk(@Param("udiRlIdFk") String udiRlIdFk);
} }

@ -48,7 +48,7 @@ public interface InvSpaceDao {
* @param filterInvSpaceRequest * @param filterInvSpaceRequest
* @return * @return
*/ */
List<InvSpace> selectSpaceCodeList(FilterInvSpaceRequest filterInvSpaceRequest); List<InvSpaceResponse> selectSpaceCodeList(FilterInvSpaceRequest filterInvSpaceRequest);
/** /**
* *

@ -100,4 +100,21 @@ public interface OrderDao {
* @return * @return
*/ */
List<OrderEntity> selectByBillNoAndStatus(String billNo); List<OrderEntity> selectByBillNoAndStatus(String billNo);
/**
*
*
* @param orderId
* @param printRemark
* @return
*/
boolean updatePrintRemark(@Param("orderId") String orderId, @Param("printRemark") String printRemark);
/**
*
*
* @param orderId
* @return
*/
String selectPrintRemarkById(@Param("orderId") String orderId);
} }

@ -100,6 +100,6 @@ public interface InvProductDetailDao {
* @param code * @param code
* @return * @return
*/ */
String selectSupIdByCode(String code); List<String> selectSupIdByCode(String code);
} }

@ -21,4 +21,7 @@ public class StockOrderResponse extends StockOrderEntity {
//当前分库名称 //当前分库名称
private String invWarehouseName; private String invWarehouseName;
//单据备注
private String printRemark;
} }

@ -138,4 +138,21 @@ public interface OrderService {
* @param responseList * @param responseList
*/ */
void queryInvName(List<StockOrderResponse> responseList); void queryInvName(List<StockOrderResponse> responseList);
/**
*
*
* @param id
* @param printRemark
* @return
*/
boolean updatePrintRemark(String id, String printRemark);
/**
*
*
* @param resultList
*/
void queryPrintRemark(List<StockOrderResponse> resultList);
} }

@ -406,10 +406,6 @@ public class OrderServiceImpl implements OrderService {
@Override @Override
public List<StockOrderResponse> checkSubmitOrder(List<StockOrderResponse> orderResponseList) { public List<StockOrderResponse> checkSubmitOrder(List<StockOrderResponse> orderResponseList) {
if (CollUtil.isEmpty(orderResponseList)) {
return Collections.emptyList();
}
//查询第三方系统的 //查询第三方系统的
List<String> actions = new ArrayList<>(); List<String> actions = new ArrayList<>();
for (StockOrderResponse stockOrderResponse : orderResponseList) { for (StockOrderResponse stockOrderResponse : orderResponseList) {
@ -539,6 +535,19 @@ public class OrderServiceImpl implements OrderService {
} }
} }
@Override
public boolean updatePrintRemark(String orderId, String printRemark) {
return orderDao.updatePrintRemark(orderId, printRemark);
}
@Override
public void queryPrintRemark(List<StockOrderResponse> resultList) {
for (StockOrderResponse stockOrderResponse : resultList) {
String printRemark = orderDao.selectPrintRemarkById(stockOrderResponse.getOrderIdFk());
stockOrderResponse.setPrintRemark(printRemark);
}
}
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@Override @Override
public void deleteOrders(List<String> ids) { public void deleteOrders(List<String> ids) {

@ -41,7 +41,7 @@ public interface InvSpaceService {
*/ */
BaseResponse updateSpace(InvSpace invSpace); BaseResponse updateSpace(InvSpace invSpace);
List<InvSpace> getSpaceCodeList(FilterInvSpaceRequest filterInvSpaceRequest); List<InvSpaceResponse> getSpaceCodeList(FilterInvSpaceRequest filterInvSpaceRequest);
/** /**
* *

@ -11,6 +11,7 @@ import com.glxp.api.admin.constant.Constant;
import com.glxp.api.admin.constant.ConstantStatus; import com.glxp.api.admin.constant.ConstantStatus;
import com.glxp.api.admin.constant.ConstantType; import com.glxp.api.admin.constant.ConstantType;
import com.glxp.api.admin.dao.basic.BussinessTypeDao; import com.glxp.api.admin.dao.basic.BussinessTypeDao;
import com.glxp.api.admin.dao.basic.CompanyProductRelevanceDao;
import com.glxp.api.admin.dao.basic.UnitMaintainDao; import com.glxp.api.admin.dao.basic.UnitMaintainDao;
import com.glxp.api.admin.dao.inout.CodesDao; import com.glxp.api.admin.dao.inout.CodesDao;
import com.glxp.api.admin.dao.inout.CodesTempDao; import com.glxp.api.admin.dao.inout.CodesTempDao;
@ -73,6 +74,8 @@ public class InvCountOrderServiceImpl implements InvCountOrderService {
private InvCountCodesService invCountCodesService; private InvCountCodesService invCountCodesService;
@Resource @Resource
private CodesDao codesDao; private CodesDao codesDao;
@Resource
private CompanyProductRelevanceDao companyProductRelevanceDao;
@Override @Override
public List<InvCountOrderResponse> filterList(FilterInvCountOrderRequest filterInvCountOrderRequest) { public List<InvCountOrderResponse> filterList(FilterInvCountOrderRequest filterInvCountOrderRequest) {
@ -299,7 +302,7 @@ public class InvCountOrderServiceImpl implements InvCountOrderService {
warehouseEntity.setReCount(codeNum); warehouseEntity.setReCount(codeNum);
//设置供应商信息 //设置供应商信息
setSupInfo(warehouseEntity); setSupInfo(warehouseEntity, "loss");
outOrderCodes.add(warehouseEntity); outOrderCodes.add(warehouseEntity);
} else { } else {
for (InvProductDetailEntity invProductDetailEntity : invProductDetailEntities) { for (InvProductDetailEntity invProductDetailEntity : invProductDetailEntities) {
@ -323,7 +326,7 @@ public class InvCountOrderServiceImpl implements InvCountOrderService {
} }
//设置供应商信息 //设置供应商信息
setSupInfo(warehouseEntity); setSupInfo(warehouseEntity, "loss");
outOrderCodes.add(warehouseEntity); outOrderCodes.add(warehouseEntity);
} }
} }
@ -362,11 +365,11 @@ public class InvCountOrderServiceImpl implements InvCountOrderService {
UdiEntity udi = FilterUdiUtils.getUdi(countCodesList.get(0)); UdiEntity udi = FilterUdiUtils.getUdi(countCodesList.get(0));
//修改码数量 //修改码数量
int actCount = invCountCodesService.getActCount(udi.getUdi()); int actCount = invCountCodesService.getActCount(udi.getUdi());
//使用此盘点单据详情的盘数量 / 实际数量,计算得出扫码数量 //使用此盘点单据详情的盘数量 / 实际数量,计算得出扫码数量
int codeNum = invCountOrderDetail.getProfitNum() / actCount; int codeNum = invCountOrderDetail.getProfitNum() / actCount;
warehouseEntity.setCount(codeNum); warehouseEntity.setCount(codeNum);
warehouseEntity.setReCount(codeNum); warehouseEntity.setReCount(codeNum);
setSupInfo(warehouseEntity); setSupInfo(warehouseEntity, "profit");
inOrderCodes.add(warehouseEntity); inOrderCodes.add(warehouseEntity);
} else { } else {
for (String code : profitCodes) { for (String code : profitCodes) {
@ -378,7 +381,7 @@ public class InvCountOrderServiceImpl implements InvCountOrderService {
if ((StrUtil.isBlank(udi.getBatchNo()) && StrUtil.isBlank(udi.getSerialNo())) || (StrUtil.isBlank(udi.getSerialNo()) && StrUtil.isNotBlank(udi.getBatchNo()))) { if ((StrUtil.isBlank(udi.getBatchNo()) && StrUtil.isBlank(udi.getSerialNo())) || (StrUtil.isBlank(udi.getSerialNo()) && StrUtil.isNotBlank(udi.getBatchNo()))) {
//修改码数量 //修改码数量
int actCount = invCountCodesService.getActCount(udi.getUdi()); int actCount = invCountCodesService.getActCount(udi.getUdi());
//使用此盘点单据详情的盘数量 / 实际数量,计算得出扫码数量 //使用此盘点单据详情的盘数量 / 实际数量,计算得出扫码数量
int codeNum = invCountOrderDetail.getProfitNum() / actCount; int codeNum = invCountOrderDetail.getProfitNum() / actCount;
warehouseEntity.setCount(codeNum); warehouseEntity.setCount(codeNum);
warehouseEntity.setReCount(codeNum); warehouseEntity.setReCount(codeNum);
@ -388,7 +391,7 @@ public class InvCountOrderServiceImpl implements InvCountOrderService {
warehouseEntity.setCount(actCount); warehouseEntity.setCount(actCount);
warehouseEntity.setReCount(actCount); warehouseEntity.setReCount(actCount);
} }
setSupInfo(warehouseEntity); setSupInfo(warehouseEntity, "profit");
inOrderCodes.add(warehouseEntity); inOrderCodes.add(warehouseEntity);
} }
} }
@ -444,16 +447,41 @@ public class InvCountOrderServiceImpl implements InvCountOrderService {
/** /**
* *
* *
* @param warehouseEntity * @param warehouseEntity
* @param countStatus
*/ */
private void setSupInfo(WarehouseEntity warehouseEntity) { private void setSupInfo(WarehouseEntity warehouseEntity, String countStatus) {
//设置供应商参数 /**
String supId = invProductDetailDao.selectSupIdByCode(warehouseEntity.getCode()); * 使
if (StrUtil.isNotEmpty(supId)) { *
warehouseEntity.setSupId(supId); * ID
//查询供应商名称 *
String name = unitMaintainDao.selectNameByErpId(supId); * 1
warehouseEntity.setSupName(name); */
if (countStatus.equals("loss")) {
log.info("生成盘亏单据条码供应商详情,条码信息:{}", warehouseEntity.getCode());
List<String> supIds = invProductDetailDao.selectSupIdByCode(warehouseEntity.getCode());
if (CollUtil.isNotEmpty(supIds)) {
if (supIds.size() == 1) {
//此产品只绑定了一个供应商若绑定了多个供应商则不填供应商ID字段生成单据之后会进入异常单据页面手动指定供应商
warehouseEntity.setSupId(supIds.get(0));
//查询供应商名称
String name = unitMaintainDao.selectNameByErpId(supIds.get(0));
warehouseEntity.setSupName(name);
}
}
} else {
log.info("生成盘盈单据条码供应商详情,条码信息:{}", warehouseEntity.getCode());
List<String> unitFkList = companyProductRelevanceDao.selectUnitFkByUdiRlIdFk(warehouseEntity.getRelId());
if (CollUtil.isNotEmpty(unitFkList)) {
if (unitFkList.size() == 1) {
//此产品只绑定了一个供应商若绑定了多个供应商则不填供应商ID字段生成单据之后会进入异常单据页面手动指定供应商
warehouseEntity.setSupId(unitFkList.get(0));
//查询供应商名称
String name = unitMaintainDao.selectNameByErpId(unitFkList.get(0));
warehouseEntity.setSupName(name);
}
}
} }
} }

@ -125,7 +125,7 @@ public class InvSpaceServiceImpl implements InvSpaceService {
} }
@Override @Override
public List<InvSpace> getSpaceCodeList(FilterInvSpaceRequest filterInvSpaceRequest) { public List<InvSpaceResponse> getSpaceCodeList(FilterInvSpaceRequest filterInvSpaceRequest) {
return invSpaceDao.selectSpaceCodeList(filterInvSpaceRequest); return invSpaceDao.selectSpaceCodeList(filterInvSpaceRequest);
} }

@ -7,16 +7,15 @@ import com.glxp.api.admin.constant.Constant;
import com.glxp.api.admin.constant.ConstantStatus; import com.glxp.api.admin.constant.ConstantStatus;
import com.glxp.api.admin.constant.ConstantType; import com.glxp.api.admin.constant.ConstantType;
import com.glxp.api.admin.controller.inout.utils.CheckOrderUtils; import com.glxp.api.admin.controller.inout.utils.CheckOrderUtils;
import com.glxp.api.admin.controller.inout.utils.ContrastErpUtil;
import com.glxp.api.admin.controller.inout.utils.DataTransUtil;
import com.glxp.api.admin.controller.inout.utils.InoutUtils; import com.glxp.api.admin.controller.inout.utils.InoutUtils;
import com.glxp.api.admin.dao.business.StockOrderRemakDao; import com.glxp.api.admin.dao.business.StockOrderRemakDao;
import com.glxp.api.admin.entity.basic.*; import com.glxp.api.admin.entity.basic.BasicUnitMaintainEntity;
import com.glxp.api.admin.entity.basic.BussinessTypeEntity;
import com.glxp.api.admin.entity.basic.CompanyProductRelevanceEntity;
import com.glxp.api.admin.entity.basic.UdiEntity;
import com.glxp.api.admin.entity.business.StockOrderDetailEntity; import com.glxp.api.admin.entity.business.StockOrderDetailEntity;
import com.glxp.api.admin.entity.business.StockOrderEntity; import com.glxp.api.admin.entity.business.StockOrderEntity;
import com.glxp.api.admin.entity.business.StockOrderRemakEntity; import com.glxp.api.admin.entity.business.StockOrderRemakEntity;
import com.glxp.api.admin.entity.info.CompanyEntity;
import com.glxp.api.admin.entity.info.SystemParamConfigEntity;
import com.glxp.api.admin.entity.inout.ErpOrderEntity; import com.glxp.api.admin.entity.inout.ErpOrderEntity;
import com.glxp.api.admin.entity.inout.FilterErpOrderRequest; import com.glxp.api.admin.entity.inout.FilterErpOrderRequest;
import com.glxp.api.admin.entity.inout.OrderEntity; import com.glxp.api.admin.entity.inout.OrderEntity;
@ -24,41 +23,33 @@ import com.glxp.api.admin.entity.inout.WarehouseEntity;
import com.glxp.api.admin.entity.inventory.InvProductDetailEntity; import com.glxp.api.admin.entity.inventory.InvProductDetailEntity;
import com.glxp.api.admin.entity.inventory.InvProductEntity; import com.glxp.api.admin.entity.inventory.InvProductEntity;
import com.glxp.api.admin.entity.inventory.InvWarehouseEntity; import com.glxp.api.admin.entity.inventory.InvWarehouseEntity;
import com.glxp.api.admin.httpclient.ErpOrderClient;
import com.glxp.api.admin.httpclient.UdiDlHttpClient;
import com.glxp.api.admin.req.basic.CompanyProductRelevanceRequest; import com.glxp.api.admin.req.basic.CompanyProductRelevanceRequest;
import com.glxp.api.admin.req.basic.FilterCompanyProductRelevanceRequest; import com.glxp.api.admin.req.basic.FilterCompanyProductRelevanceRequest;
import com.glxp.api.admin.req.basic.FilterUdiInfoRequest;
import com.glxp.api.admin.req.business.StockOrderFilterRequest; import com.glxp.api.admin.req.business.StockOrderFilterRequest;
import com.glxp.api.admin.req.inout.CommitRequest; import com.glxp.api.admin.req.inout.CommitRequest;
import com.glxp.api.admin.req.inout.OrderFilterRequest; import com.glxp.api.admin.req.inout.OrderFilterRequest;
import com.glxp.api.admin.req.inout.PostOrderRequest; import com.glxp.api.admin.req.inout.PostOrderRequest;
import com.glxp.api.admin.req.inout.WarehouseQueryRequest; import com.glxp.api.admin.req.inout.WarehouseQueryRequest;
import com.glxp.api.admin.req.inventory.FilterInvProductDetailRequest;
import com.glxp.api.admin.req.inventory.FilterInvProductRequest; import com.glxp.api.admin.req.inventory.FilterInvProductRequest;
import com.glxp.api.admin.req.inventory.FilterInvWarehouseRequest; import com.glxp.api.admin.req.inventory.FilterInvWarehouseRequest;
import com.glxp.api.admin.res.basic.BussinessOriginTypeResponse;
import com.glxp.api.admin.res.basic.UdiRelevanceResponse; import com.glxp.api.admin.res.basic.UdiRelevanceResponse;
import com.glxp.api.admin.res.info.CompanyProductRelevanceResponse; import com.glxp.api.admin.res.info.CompanyProductRelevanceResponse;
import com.glxp.api.admin.service.basic.*; import com.glxp.api.admin.service.basic.BasicUnitMaintainService;
import com.glxp.api.admin.service.basic.BussinessTypeService;
import com.glxp.api.admin.service.basic.UdiInfoService;
import com.glxp.api.admin.service.basic.UdiRelevanceService;
import com.glxp.api.admin.service.business.StockOrderDetailService; import com.glxp.api.admin.service.business.StockOrderDetailService;
import com.glxp.api.admin.service.business.StockOrderService; import com.glxp.api.admin.service.business.StockOrderService;
import com.glxp.api.admin.service.info.CompanyProductRelevanceService; import com.glxp.api.admin.service.info.CompanyProductRelevanceService;
import com.glxp.api.admin.service.info.CompanyService;
import com.glxp.api.admin.service.info.SystemParamConfigService;
import com.glxp.api.admin.service.inout.CodesService; import com.glxp.api.admin.service.inout.CodesService;
import com.glxp.api.admin.service.inout.CodesTempService; import com.glxp.api.admin.service.inout.CodesTempService;
import com.glxp.api.admin.service.inout.OrderDetailService; import com.glxp.api.admin.service.inout.OrderDetailService;
import com.glxp.api.admin.service.inout.OrderService; import com.glxp.api.admin.service.inout.OrderService;
import com.glxp.api.admin.service.inventory.*; import com.glxp.api.admin.service.inventory.*;
import com.glxp.api.admin.service.thrsys.ThrDataService;
import com.glxp.api.admin.service.thrsys.ThrOrderService;
import com.glxp.api.admin.util.*; import com.glxp.api.admin.util.*;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.scheduling.annotation.Async; import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
@ -528,7 +519,7 @@ public class IoTransInoutService {
if (originSupId != null) { if (originSupId != null) {
warehouseEntity.setSupId(originSupId); warehouseEntity.setSupId(originSupId);
} }
if (udiRelevanceEntities != null && udiRelevanceEntities.size() > 1 && warehouseEntity.getRelId() == null) {//同一个DI绑定多个产品西信息 if (udiRelevanceEntities != null && udiRelevanceEntities.size() > 1 && warehouseEntity.getRelId() == null) {//同一个DI绑定多个产品信息
warehouseEntity.setRelId(null); warehouseEntity.setRelId(null);
warehouseEntity.setStatus(ConstantStatus.ORDER_DETAIL_DI_MUTI); warehouseEntity.setStatus(ConstantStatus.ORDER_DETAIL_DI_MUTI);
} else if (udiRelevanceEntities == null || udiRelevanceEntities.size() == 0) {//未找到产品信息,一般不会出现 } else if (udiRelevanceEntities == null || udiRelevanceEntities.size() == 0) {//未找到产品信息,一般不会出现

@ -297,4 +297,7 @@
WHERE udiRlIdFk = #{id} WHERE udiRlIdFk = #{id}
</delete> </delete>
<select id="selectUnitFkByUdiRlIdFk" resultType="java.lang.String">
select unitFk from company_product_relevance where udiRlIdFk = #{udiRlIdFk}
</select>
</mapper> </mapper>

@ -315,18 +315,20 @@
</where> </where>
</select> </select>
<select id="selectSpaceCodeList" resultMap="BaseResultMap"> <select id="selectSpaceCodeList" resultType="com.glxp.api.admin.res.inventory.InvSpaceResponse">
select code, name select inv_space.code, inv_space.name, iws.name invSubStorageName, iw.name invStorageName
from inv_space from inv_space
left join inv_warehouse_sub iws on iws.code = inv_space.invWarehouseCode
left join inv_warehouse iw on iw.code = inv_space.invStorageCode
<where> <where>
<if test="invStorageCode != null and invStorageCode != ''"> <if test="invStorageCode != null and invStorageCode != ''">
AND invStorageCode = #{invStorageCode} AND inv_space.invStorageCode = #{invStorageCode}
</if> </if>
<if test="invWarehouseCode != null and invWarehouseCode != ''"> <if test="invWarehouseCode != null and invWarehouseCode != ''">
AND invWarehouseCode = #{invWarehouseCode} AND inv_space.invWarehouseCode = #{invWarehouseCode}
</if> </if>
<if test="status != null"> <if test="status != null">
AND status = #{status} AND inv_space.status = #{status}
</if> </if>
</where> </where>
</select> </select>

@ -671,4 +671,11 @@
and (io_order.id = #{billNo} or io_order.erpFk = #{billNo}) and (io_order.id = #{billNo} or io_order.erpFk = #{billNo})
</select> </select>
<update id="updatePrintRemark">
update io_order set printRemark = #{printRemark} where id = #{orderId}
</update>
<select id="selectPrintRemarkById" resultType="java.lang.String">
select printRemark from io_order where id = #{orderId}
</select>
</mapper> </mapper>

@ -434,6 +434,6 @@
</select> </select>
<select id="selectSupIdByCode" resultType="java.lang.String"> <select id="selectSupIdByCode" resultType="java.lang.String">
select supId from inv_product_detail where originCode = #{code} limit 1 select supId from inv_product_detail where originCode = #{code}
</select> </select>
</mapper> </mapper>
Loading…
Cancel
Save