业务流程,资质证书,单据类型等相关修改

master
anthonywj 2 years ago
parent 4b54a7d2aa
commit 4d00e27958

@ -28,7 +28,7 @@ public class ConstantStatus {
public static final Integer ORDER_STATS_ERROR = 4; public static final Integer ORDER_STATS_ERROR = 4;
/** /**
* *
*/ */
public static final Integer ORDER_STATUS_CHECK_SUCCESS = 5; public static final Integer ORDER_STATUS_CHECK_SUCCESS = 5;
@ -37,6 +37,13 @@ public class ConstantStatus {
*/ */
public static final Integer ORDER_STATUS_CHECK_FAIL = 6; public static final Integer ORDER_STATUS_CHECK_FAIL = 6;
/**
*
*/
public static final Integer ORDER_STATUS_CHECK_REW = 10;
/** /**
* *
*/ */
@ -83,9 +90,11 @@ public class ConstantStatus {
//订单处理状态 //订单处理状态
public static final Integer ORDER_DEAL_DRAFT = 1; //草稿 public static final Integer ORDER_DEAL_DRAFT = 1; //草稿
public static final Integer ORDER_DEAL_POST = 2; //已提交 public static final Integer ORDER_DEAL_POST = 2; //已提交,待交接
public static final Integer ORDER_DEAL_REW = 4; //交接中,待审核
public static final Integer ORDER_DEAL_CHECK = 3; //已审核 public static final Integer ORDER_DEAL_CHECK = 3; //已审核
//ERP校验状态 //ERP校验状态
public static final Integer ORDER_CHECK_SUCCESS = 2; //校验成功 public static final Integer ORDER_CHECK_SUCCESS = 2; //校验成功
public static final Integer ORDER_CHECK_FAIL = 1; //校验失败 public static final Integer ORDER_CHECK_FAIL = 1; //校验失败

@ -237,7 +237,7 @@ public class UdiRlSupController extends BaseController {
UdiProductEntity udiProductEntity = new UdiProductEntity(); UdiProductEntity udiProductEntity = new UdiProductEntity();
BeanUtils.copyProperties(udiProductEntity, udiInfoExportRequest.getSupplementRequest()); BeanUtils.copyProperties(udiProductEntity, udiInfoExportRequest.getSupplementRequest());
udiProductService.insertUdiInfo(udiProductEntity); udiProductService.insertUdiInfo(udiProductEntity);
return ResultVOUtils.success("后台正在导入,请稍后刷新查看"); return ResultVOUtils.success("选入成功");
} }
@AuthRuleAnnotation("") @AuthRuleAnnotation("")

@ -29,6 +29,7 @@ import com.glxp.api.res.inout.IoOrderInvoiceResponse;
import com.glxp.api.service.auth.InvWarehouseService; import com.glxp.api.service.auth.InvWarehouseService;
import com.glxp.api.service.basic.*; import com.glxp.api.service.basic.*;
import com.glxp.api.service.inout.*; import com.glxp.api.service.inout.*;
import com.glxp.api.service.purchase.SupProductService;
import com.glxp.api.service.thrsys.ThrOrderDetailService; import com.glxp.api.service.thrsys.ThrOrderDetailService;
import com.glxp.api.service.thrsys.ThrOrderService; import com.glxp.api.service.thrsys.ThrOrderService;
import com.glxp.api.service.thrsys.ThrSystemBusApiService; import com.glxp.api.service.thrsys.ThrSystemBusApiService;
@ -79,7 +80,6 @@ public class IoOrderDetailBizController extends BaseController {
IoOrderInvoiceService ioOrderInvoiceService; IoOrderInvoiceService ioOrderInvoiceService;
//获取单据业务详情---临时接口查询 //获取单据业务详情---临时接口查询
@AuthRuleAnnotation("") @AuthRuleAnnotation("")
@GetMapping("udiwms/inout/order/draft/biz") @GetMapping("udiwms/inout/order/draft/biz")
@ -90,7 +90,8 @@ public class IoOrderDetailBizController extends BaseController {
pageSimpleResponse.setList(orderEntityList); pageSimpleResponse.setList(orderEntityList);
return ResultVOUtils.success(pageSimpleResponse); return ResultVOUtils.success(pageSimpleResponse);
} }
@Resource
SupProductService supProductService;
//录入业务单据详情 //录入业务单据详情
@AuthRuleAnnotation("") @AuthRuleAnnotation("")
@ -137,6 +138,10 @@ public class IoOrderDetailBizController extends BaseController {
} }
for (AddBizProductReqeust item : datas) { for (AddBizProductReqeust item : datas) {
UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectGroupById(item.getRelId()); UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectGroupById(item.getRelId());
// todo 查询产品是否已经通过认证
// 1111
IoOrderDetailBizEntity ioOrderDetailBizEntity = new IoOrderDetailBizEntity(); IoOrderDetailBizEntity ioOrderDetailBizEntity = new IoOrderDetailBizEntity();
ioOrderDetailBizEntity.setOrderIdFk(orderEntity.getBillNo()); ioOrderDetailBizEntity.setOrderIdFk(orderEntity.getBillNo());
ioOrderDetailBizEntity.setBindRlFk(udiRelevanceResponse.getId()); ioOrderDetailBizEntity.setBindRlFk(udiRelevanceResponse.getId());
@ -162,6 +167,8 @@ public class IoOrderDetailBizController extends BaseController {
return ResultVOUtils.success(orderEntity); return ResultVOUtils.success(orderEntity);
} }
//修改业务单据详情 //修改业务单据详情
@AuthRuleAnnotation("") @AuthRuleAnnotation("")
@PostMapping("/udiwms/inout/order/updateBizProduct") @PostMapping("/udiwms/inout/order/updateBizProduct")
@ -417,32 +424,32 @@ public class IoOrderDetailBizController extends BaseController {
} }
/** /**
* *
* *
* @param id * @param id
* @return * @return
*/ */
@GetMapping("/udiwms/inout/biz/deleteById") @GetMapping("/udiwms/inout/biz/deleteById")
public BaseResponse deleteById(Integer id) { public BaseResponse deleteById(Integer id) {
return ResultVOUtils.success(ioOrderInvoiceService.deleteByInvId(id)); return ResultVOUtils.success(ioOrderInvoiceService.deleteByInvId(id));
} }
/** /**
* *
* *
* @param ioOrderInvoiceRequest * @param ioOrderInvoiceRequest
* @return * @return
*/ */
@PostMapping("/udiwms/inout/biz/updateById") @PostMapping("/udiwms/inout/biz/updateById")
public BaseResponse deleteById(@RequestBody IoOrderInvoiceRequest ioOrderInvoiceRequest) { public BaseResponse deleteById(@RequestBody IoOrderInvoiceRequest ioOrderInvoiceRequest) {
return ResultVOUtils.success(ioOrderInvoiceService.updateByInvId(ioOrderInvoiceRequest)); return ResultVOUtils.success(ioOrderInvoiceService.updateByInvId(ioOrderInvoiceRequest));
} }
@PostMapping("/udiwms/inout/biz/insertInvoice") @PostMapping("/udiwms/inout/biz/insertInvoice")
@ -453,7 +460,7 @@ public BaseResponse deleteById(@RequestBody IoOrderInvoiceRequest ioOrderInvoice
for (IoOrderDetailResultEntity ioOrderDetailResultEntity : list) { for (IoOrderDetailResultEntity ioOrderDetailResultEntity : list) {
IoOrderInvoiceEntity ioOrderInvoiceEntity = new IoOrderInvoiceEntity(); IoOrderInvoiceEntity ioOrderInvoiceEntity = new IoOrderInvoiceEntity();
ioOrderInvoiceEntity.setOrderIdFk(ioOrderDetailResultEntity.getOrderIdFk()); ioOrderInvoiceEntity.setOrderIdFk(ioOrderDetailResultEntity.getOrderIdFk());
ioOrderInvoiceEntity.setBindRlFk(ioOrderDetailResultEntity.getBindRlFk()+""); ioOrderInvoiceEntity.setBindRlFk(ioOrderDetailResultEntity.getBindRlFk() + "");
ioOrderInvoiceEntity.setBatchNo(ioOrderDetailResultEntity.getBatchNo()); ioOrderInvoiceEntity.setBatchNo(ioOrderDetailResultEntity.getBatchNo());
ioOrderInvoiceEntity.setProductDate(ioOrderDetailResultEntity.getProductDate()); ioOrderInvoiceEntity.setProductDate(ioOrderDetailResultEntity.getProductDate());
ioOrderInvoiceEntity.setExpireDate(ioOrderDetailResultEntity.getExpireDate()); ioOrderInvoiceEntity.setExpireDate(ioOrderDetailResultEntity.getExpireDate());
@ -461,7 +468,6 @@ public BaseResponse deleteById(@RequestBody IoOrderInvoiceRequest ioOrderInvoice
} }
return ResultVOUtils.success("成功"); return ResultVOUtils.success("成功");
} }

@ -97,7 +97,16 @@ public class IoOrderReviewController extends BaseController {
if (orderEntity == null) { if (orderEntity == null) {
return ResultVOUtils.error(500, "未找到该业务单据"); return ResultVOUtils.error(500, "未找到该业务单据");
} }
return updateReview(getUser(), orderEntity);
if (orderEntity.getStatus() == ConstantStatus.ORDER_STATUS_CHECK_REW) {
return updateReview(getUser(), orderEntity);
} else if (orderEntity.getStatus() == ConstantStatus.ORDER_STATUS_CHECK_SUCCESS) {
return thirdUpdateReview(getUser(), orderEntity);
} else {
return ResultVOUtils.error(500, "当前单据状态非处于审核状态!");
}
} }
//前端第三次验收 //前端第三次验收
@ -366,7 +375,7 @@ public class IoOrderReviewController extends BaseController {
//前端第三次验收 //前端第三次验收
public BaseResponse thirdUpdateReview(AuthAdmin authAdmin, IoOrderEntity orderEntity) { public BaseResponse thirdUpdateReview(AuthAdmin authAdmin, IoOrderEntity orderEntity) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_AUDITED); orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
orderEntity.setReviewUser(authAdmin.getId() + ""); orderEntity.setReviewUser(authAdmin.getId() + "");
orderEntity.setUpdateTime(new Date()); orderEntity.setUpdateTime(new Date());
orderEntity.setAuditTime(new Date()); orderEntity.setAuditTime(new Date());
@ -375,6 +384,7 @@ public class IoOrderReviewController extends BaseController {
redisUtil.del(ConstantStatus.REDIS_BILLNO + orderEntity.getBillNo()); redisUtil.del(ConstantStatus.REDIS_BILLNO + orderEntity.getBillNo());
redisUtil.del(ConstantStatus.REDIS_BILLNO_CODES + orderEntity.getBillNo()); redisUtil.del(ConstantStatus.REDIS_BILLNO_CODES + orderEntity.getBillNo());
//验收完成->进入流程 //验收完成->进入流程
ioCheckInoutService.checkThird(orderEntity);
return ResultVOUtils.success("更新成功"); return ResultVOUtils.success("更新成功");
} }

@ -42,6 +42,11 @@ public class InvPreinOrderController extends BaseController {
@GetMapping("/udiwms/inv/prein/filter") @GetMapping("/udiwms/inv/prein/filter")
public BaseResponse filterOrder(FilterInvPreinRequest filterInvPreinRequest) { public BaseResponse filterOrder(FilterInvPreinRequest filterInvPreinRequest) {
if (!isHosUser()) {
filterInvPreinRequest.setFromCorp(getCustomerId());
}
List<InvPreinOrderResponse> list = invPreinOrderService.filterList(filterInvPreinRequest); List<InvPreinOrderResponse> list = invPreinOrderService.filterList(filterInvPreinRequest);
PageInfo<InvPreinOrderResponse> pageInfo = new PageInfo<>(list); PageInfo<InvPreinOrderResponse> pageInfo = new PageInfo<>(list);
return ResultVOUtils.page(pageInfo); return ResultVOUtils.page(pageInfo);

@ -265,7 +265,7 @@ public class SupCompanyController {
for (SupCertEntity supCertEntity : supCertEntityList) { for (SupCertEntity supCertEntity : supCertEntityList) {
msg+=supCertEntity.getName()+","; msg+=supCertEntity.getName()+",";
} }
return ResultVOUtils.error(500, "审核失败,还有" + msg.substring(0,msg.length()-1) + "证书还未确认!"); return ResultVOUtils.error(500, "审核失败,还有必须提交证书未确认(" + msg.substring(0,msg.length()-1) + ")");
} }
} }

@ -364,8 +364,7 @@ public class SupManufacturerController {
for (SupCertEntity supCertEntity : supCertEntityList) { for (SupCertEntity supCertEntity : supCertEntityList) {
msg+=supCertEntity.getName()+","; msg+=supCertEntity.getName()+",";
} }
return ResultVOUtils.error(500, "审核失败,还有" + msg.substring(0,msg.length()-1) + "证书还未确认!"); return ResultVOUtils.error(500, "审核失败,还有必须提交证书未确认(" + msg.substring(0,msg.length()-1) + ")"); }
}
} }
supManufacturerEntity.setUpdateTime(new Date()); supManufacturerEntity.setUpdateTime(new Date());

@ -153,13 +153,11 @@ public class SupProductController {
UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectGroupById(Long.valueOf(selectProductBindRequest.getRelIdFk())); UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectGroupById(Long.valueOf(selectProductBindRequest.getRelIdFk()));
SupProductEntity supProductEntity = new SupProductEntity(); SupProductEntity supProductEntity = new SupProductEntity();
BeanUtils.copyProperties(udiRelevanceResponse, supProductEntity); BeanUtils.copyProperties(udiRelevanceResponse, supProductEntity);
supProductEntity.setProductId(selectProductBindRequest.getProductId()); supProductEntity.setProductId(selectProductBindRequest.getProductId());
supProductEntity.setRecordCode(udiRelevanceResponse.getZczbhhzbapzbh()); supProductEntity.setRecordCode(udiRelevanceResponse.getZczbhhzbapzbh());
supProductEntity.setRelIdFk(selectProductBindRequest.getRelIdFk()); supProductEntity.setRelIdFk(udiRelevanceResponse.getId() + "");
supProductEntity.setRecordProductName(udiRelevanceResponse.getCpmctymc()); supProductEntity.setRecordProductName(udiRelevanceResponse.getCpmctymc());
supProductEntity.setProductType(udiRelevanceResponse.getQxlb()); supProductEntity.setProductType(udiRelevanceResponse.getQxlb());
supProductEntity.setProductDirectoryCode(udiRelevanceResponse.getFlbm()); supProductEntity.setProductDirectoryCode(udiRelevanceResponse.getFlbm());
@ -200,51 +198,51 @@ public class SupProductController {
//提交审核 //提交审核
if (supProductEntity.getAuditStatus() == ConstantStatus.AUDIT_CHANGE || supProductEntity.getAuditStatus() == ConstantStatus.AUDIT_UN) { if (supProductEntity.getAuditStatus() == ConstantStatus.AUDIT_CHANGE || supProductEntity.getAuditStatus() == ConstantStatus.AUDIT_UN) {
//判断是否上级供应商是否审核通过 //判断是否上级供应商是否审核通过
SupManufacturerEntity supManufacturerEntity = supManufacturerService.findManufacturer(supProductEntity.getManufacturerIdFk()); SupManufacturerEntity supManufacturerEntity = supManufacturerService.findManufacturer(supProductEntity.getManufacturerIdFk());
if (supManufacturerEntity.getAuditStatus() == ConstantStatus.AUDIT_UN if (supManufacturerEntity.getAuditStatus() == ConstantStatus.AUDIT_UN
|| supManufacturerEntity.getAuditStatus() == ConstantStatus.AUDIT_DRAFT) { || supManufacturerEntity.getAuditStatus() == ConstantStatus.AUDIT_DRAFT) {
return ResultVOUtils.error(500, "所属生产企业资质未通过审核,暂时无法提交!"); return ResultVOUtils.error(500, "所属生产企业资质未通过审核,暂时无法提交!");
} }
//验证证书是否齐全 //验证证书是否齐全
FilterCertSetsRequest filterCertSetsRequest = new FilterCertSetsRequest(); FilterCertSetsRequest filterCertSetsRequest = new FilterCertSetsRequest();
filterCertSetsRequest.setType(ConstantStatus.CERT_PRODUCT); filterCertSetsRequest.setType(ConstantStatus.CERT_PRODUCT);
List<SupCertSetEntity> supCertSetEntities = supCertSetService.filterCertSets(filterCertSetsRequest); List<SupCertSetEntity> supCertSetEntities = supCertSetService.filterCertSets(filterCertSetsRequest);
List<SupCertEntity> supCertEntityList = supCertService.findAll(supProductEntity.getCustomerId(), supProductEntity.getManufacturerIdFk(), supProductEntity.getProductId()); List<SupCertEntity> supCertEntityList = supCertService.findAll(supProductEntity.getCustomerId(), supProductEntity.getManufacturerIdFk(), supProductEntity.getProductId());
ListIterator<SupCertSetEntity> iterable = supCertSetEntities.listIterator(); ListIterator<SupCertSetEntity> iterable = supCertSetEntities.listIterator();
while (iterable.hasNext()) { while (iterable.hasNext()) {
SupCertSetEntity supCertSetEntity = iterable.next(); SupCertSetEntity supCertSetEntity = iterable.next();
if (supCertSetEntity.getImports() != null && supCertSetEntity.getImports() == 1 || StrUtil.isNotEmpty(supCertSetEntity.getCplx()) && supCertSetEntity.getCplx().equals("全部") if (supCertSetEntity.getImports() != null && supCertSetEntity.getImports() == 1 || StrUtil.isNotEmpty(supCertSetEntity.getCplx()) && supCertSetEntity.getCplx().equals("全部")
|| StrUtil.isNotEmpty(supCertSetEntity.getHchzsb()) && supCertSetEntity.getHchzsb().equals("全部") || StrUtil.isNotEmpty(supCertSetEntity.getHchzsb()) && supCertSetEntity.getHchzsb().equals("全部")
|| (supCertSetEntity.getImports() != null && supCertSetEntity.getImports() == 2 || (supCertSetEntity.getImports() != null && supCertSetEntity.getImports() == 2
&& StrUtil.trimToEmpty(supProductEntity.getRecordCode()).contains("进")) && StrUtil.trimToEmpty(supProductEntity.getRecordCode()).contains("进"))
|| (supCertSetEntity.getImports() != null && supCertSetEntity.getImports() == 3 && !StrUtil.trimToEmpty(supProductEntity.getRecordCode()).contains("进")) || (supCertSetEntity.getImports() != null && supCertSetEntity.getImports() == 3 && !StrUtil.trimToEmpty(supProductEntity.getRecordCode()).contains("进"))
|| (StrUtil.trimToEmpty(supProductEntity.getProductType()).equals(supCertSetEntity.getCplx())) || (StrUtil.trimToEmpty(supProductEntity.getProductType()).equals(supCertSetEntity.getCplx()))
|| (StrUtil.trimToEmpty(supProductEntity.getHchzsb()).equals(supCertSetEntity.getHchzsb())) || (StrUtil.trimToEmpty(supProductEntity.getHchzsb()).equals(supCertSetEntity.getHchzsb()))
|| StrUtil.isNotEmpty(supCertSetEntity.getFlbm()) && (supCertSetEntity.getFlbm().contains(StrUtil.trimToEmpty(supProductEntity.getProductDirectoryCode()))) || StrUtil.isNotEmpty(supCertSetEntity.getFlbm()) && (supCertSetEntity.getFlbm().contains(StrUtil.trimToEmpty(supProductEntity.getProductDirectoryCode())))
) { ) {
for (SupCertEntity supCertEntity : supCertEntityList) { for (SupCertEntity supCertEntity : supCertEntityList) {
if (supCertEntity.getName().equals(supCertSetEntity.getName())) { if (supCertEntity.getName().equals(supCertSetEntity.getName())) {
if (StrUtil.isNotEmpty(supCertEntity.getFilePath())) { if (StrUtil.isNotEmpty(supCertEntity.getFilePath())) {
iterable.remove(); iterable.remove();
break; break;
}
} }
} }
} else {
iterable.remove();
} }
} else {
iterable.remove();
} }
} String errMsg = "";
String errMsg = ""; if (supCertSetEntities.size() > 0) {
if (supCertSetEntities.size() > 0) { for (SupCertSetEntity supCertSetEntity : supCertSetEntities) {
for (SupCertSetEntity supCertSetEntity : supCertSetEntities) { errMsg = errMsg + "," + supCertSetEntity.getName();
errMsg = errMsg + "," + supCertSetEntity.getName(); }
return ResultVOUtils.error(500, errMsg.substring(1) + "等证书未上传,无法提交审核!");
} }
return ResultVOUtils.error(500, errMsg.substring(1) + "等证书未上传,无法提交审核!");
}
} }
supProductEntity.setUpdateTime(new Date()); supProductEntity.setUpdateTime(new Date());
@ -314,7 +312,7 @@ public class SupProductController {
return ResultVOUtils.error(500, "必传证书不齐全"); return ResultVOUtils.error(500, "必传证书不齐全");
} }
} }
String msg=""; String msg = "";
// 查询是否包含审核未通过的证书 // 查询是否包含审核未通过的证书
if (supProductEntity.getAuditStatus() == ConstantStatus.AUDIT_PASS || if (supProductEntity.getAuditStatus() == ConstantStatus.AUDIT_PASS ||
supProductEntity.getAuditStatus() == ConstantStatus.AUDIT_CHANGE_PASS) { supProductEntity.getAuditStatus() == ConstantStatus.AUDIT_CHANGE_PASS) {
@ -327,9 +325,9 @@ public class SupProductController {
List<SupCertEntity> supCertEntityList = supCertService.filterCompanyCert(filterSupCertRequest); List<SupCertEntity> supCertEntityList = supCertService.filterCompanyCert(filterSupCertRequest);
if (CollUtil.isNotEmpty(supCertEntityList)) { if (CollUtil.isNotEmpty(supCertEntityList)) {
for (SupCertEntity supCertEntity : supCertEntityList) { for (SupCertEntity supCertEntity : supCertEntityList) {
msg+=supCertEntity.getName()+","; msg += supCertEntity.getName() + ",";
} }
return ResultVOUtils.error(500, "审核失败,还有" + msg.substring(0,msg.length()-1) + "证书还未确认!"); return ResultVOUtils.error(500, "审核失败,还有必须提交证书未确认(" + msg.substring(0, msg.length() - 1) + ")");
} }
} }

@ -363,7 +363,29 @@ public class BasicBussinessTypeEntity {
@TableField(value = "actionType") @TableField(value = "actionType")
private Integer actionType; //1带票正常2.预验收。3寄售 private int actionType; //1带票正常2.预验收。3寄售
@TableField(value = "thrCheckEnable")
private boolean thrCheckEnable;
@TableField(value = "thrCheckWebNew")
private boolean thrCheckWebNew;
@TableField(value = "thrCheckPdaUn")
private boolean thrCheckPdaUn;
@TableField(value = "thrCheckPdaEd")
private boolean thrCheckPdaEd;
@TableField(value = "thrCheckUdims")
private boolean thrCheckUdims;
@TableField(value = "thrCheckPc")
private boolean thrCheckPc;
@TableField(value = "thrCheckSp")
private boolean thrCheckSp;
@TableField(value = "thrCheckChange")
private boolean thrCheckChange;
@TableField(value = "thrCheckBalance")
private boolean thrCheckBalance;
@TableField(value = "thrCheckCopy")
private boolean thrCheckCopy;
} }

@ -275,7 +275,19 @@ public class BussinessTypeSaveRequest {
private boolean vailDispatch; //校验是否可配送 private boolean vailDispatch; //校验是否可配送
private int vailGroupBuy; //校验是否集采产品 0:全部1只采集集采产品2只采集非集采产品 private int vailGroupBuy; //校验是否集采产品 0:全部1只采集集采产品2只采集非集采产品
private Integer busType; //1:正常2送货3.到货 private Integer busType; //1:正常2送货3.到货
private Integer actionType; private int actionType;
private boolean inStock; private boolean inStock;
private boolean thrCheckEnable;
private boolean thrCheckWebNew;
private boolean thrCheckPdaUn;
private boolean thrCheckPdaEd;
private boolean thrCheckUdims;
private boolean thrCheckPc;
private boolean thrCheckSp;
private boolean thrCheckChange;
private boolean thrCheckBalance;
private boolean thrCheckCopy;
} }

@ -1,5 +1,6 @@
package com.glxp.api.res.basic; package com.glxp.api.res.basic;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.Data; import lombok.Data;
/** /**
@ -127,8 +128,18 @@ public class BasicBussinessTypeResponse {
private int vailGroupBuy; //校验是否集采产品 0:全部1只采集集采产品2只采集非集采产品 private int vailGroupBuy; //校验是否集采产品 0:全部1只采集集采产品2只采集非集采产品
private Integer busType; //1:正常2送货3.到货 private Integer busType; //1:正常2送货3.到货
private Integer actionType; private int actionType;
private boolean inStock; private boolean inStock;
private boolean thrCheckEnable;
private boolean thrCheckWebNew;
private boolean thrCheckPdaUn;
private boolean thrCheckPdaEd;
private boolean thrCheckUdims;
private boolean thrCheckPc;
private boolean thrCheckSp;
private boolean thrCheckChange;
private boolean thrCheckBalance;
private boolean thrCheckCopy;
} }

@ -96,7 +96,7 @@ public class IoCheckInoutService {
} }
} }
//校验流程 //校验流程 //一次校验
public void check(String orderId) { public void check(String orderId) {
IoOrderEntity orderEntity = orderService.findByBillNo(orderId); IoOrderEntity orderEntity = orderService.findByBillNo(orderId);
//过滤非未校验或校验异常 //过滤非未校验或校验异常
@ -229,9 +229,10 @@ public class IoCheckInoutService {
orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST); orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST);
orderEntity.setUpdateTime(new Date()); orderEntity.setUpdateTime(new Date());
orderService.update(orderEntity); orderService.update(orderEntity);
checkSecond(orderEntity); checkThird(orderEntity);
} }
//一次校验完成 //一次校验完成
public void checkFirstFinish(IoOrderEntity orderEntity) { public void checkFirstFinish(IoOrderEntity orderEntity) {
List<IoOrderDetailCodeEntity> orderDetailCodeEntities = orderDetailCodeService.findByOrderId(orderEntity.getBillNo()); List<IoOrderDetailCodeEntity> orderDetailCodeEntities = orderDetailCodeService.findByOrderId(orderEntity.getBillNo());
@ -332,7 +333,7 @@ public class IoCheckInoutService {
orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST); orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST);
orderEntity.setUpdateTime(new Date()); orderEntity.setUpdateTime(new Date());
orderService.update(orderEntity); orderService.update(orderEntity);
checkSecond(orderEntity); checkThird(orderEntity);
} }
} }
@ -536,6 +537,59 @@ public class IoCheckInoutService {
} }
//三次校验(中间层)
public void checkThird(IoOrderEntity orderEntity) {
BasicBussinessTypeEntity bussinessTypeEntity = basicBussinessTypeService.findByAction(orderEntity.getAction());
if (orderEntity.getStatus() != ConstantStatus.ORDER_STATUS_AUDITED && orderEntity.getStatus() != ConstantStatus.ORDER_STATUS_CHECK_REW) {
if (bussinessTypeEntity.isThrCheckEnable()) {
if (orderEntity.getFromType().intValue() == ConstantStatus.FROM_UDIMS) {
if (!bussinessTypeEntity.isThrCheckUdims()) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
} else if (orderEntity.getFromType().intValue() == ConstantStatus.FROM_WEBNEW) {
if (!bussinessTypeEntity.isThrCheckWebNew()) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
} else if (orderEntity.getFromType().intValue() == ConstantStatus.FROM_PDAED) {
if (!bussinessTypeEntity.isThrCheckPdaEd()) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
} else if (orderEntity.getFromType().intValue() == ConstantStatus.FROM_PDAUN) {
if (!bussinessTypeEntity.isThrCheckPdaUn()) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
} else if (orderEntity.getFromType().intValue() == ConstantStatus.FROM_PC) {
if (!bussinessTypeEntity.isThrCheckPc()) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
} else if (orderEntity.getFromType().intValue() == ConstantStatus.FROM_CHANGE) {
if (!bussinessTypeEntity.isThrCheckChange()) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
} else if (orderEntity.getFromType().intValue() == ConstantStatus.FROM_PEACE_CHANGE) {
if (!bussinessTypeEntity.isThrCheckBalance()) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
} else if (orderEntity.getFromType().intValue() == ConstantStatus.FROM_COPY) {
if (!bussinessTypeEntity.isThrCheckCopy()) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
}
} else {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
}
}
if (orderEntity.getStatus() == ConstantStatus.ORDER_STATUS_CHECK_REW) {
orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_REW);
orderEntity.setUpdateTime(new Date());
orderEntity.setAuditTime(new Date());
orderService.update(orderEntity);
checkSecond(orderEntity);
}
}
//二次校验 //二次校验
public void checkSecond(IoOrderEntity orderEntity) { public void checkSecond(IoOrderEntity orderEntity) {
BasicBussinessTypeEntity bussinessTypeEntity = basicBussinessTypeService.findByAction(orderEntity.getAction()); BasicBussinessTypeEntity bussinessTypeEntity = basicBussinessTypeService.findByAction(orderEntity.getAction());

@ -525,8 +525,8 @@ public class IoOrderServiceImpl implements IoOrderService {
filterOrderRequest.setDealStatuses(Arrays.asList(2)); filterOrderRequest.setDealStatuses(Arrays.asList(2));
break; break;
case Constant.ORDER_STATUS_AUDITED: case Constant.ORDER_STATUS_AUDITED:
filterOrderRequest.setStatuses(Arrays.asList(7)); filterOrderRequest.setStatuses(Arrays.asList(7,10));
filterOrderRequest.setDealStatuses(Arrays.asList(3)); filterOrderRequest.setDealStatuses(Arrays.asList(3,4));
break; break;
case Constant.ORDER_STATUS_SUP_SEARCH: case Constant.ORDER_STATUS_SUP_SEARCH:
filterOrderRequest.setStatuses(Arrays.asList(5, 7)); filterOrderRequest.setStatuses(Arrays.asList(5, 7));

@ -68,7 +68,9 @@
entrutSpms, codeFillCheck, defaultSubInv, defaultInv, orderVisibleType, entrutSpms, codeFillCheck, defaultSubInv, defaultInv, orderVisibleType,
checkCopy, secCheckCopy, originAction, advanceType, changeEnable, checkCopy, secCheckCopy, originAction, advanceType, changeEnable,
spUse, preIn, supplementAll, createUser, createTime, preInBack, vailDispatch, spUse, preIn, supplementAll, createUser, createTime, preInBack, vailDispatch,
vailGroupBuy, busType, inStock,actionType) vailGroupBuy, busType, inStock, actionType
, thrCheckEnable, thrCheckWebNew, thrCheckPdaUn, thrCheckPdaEd, thrCheckUdims, thrCheckPc, thrCheckSp
, thrCheckChange, thrCheckBalance, thrCheckCopy)
values (#{mainAction}, values (#{mainAction},
#{action}, #{action},
#{name}, #{name},
@ -120,7 +122,10 @@
#{preIn}, #{preIn},
#{supplementAll}, #{supplementAll},
#{createUser}, #{createUser},
#{createTime}, #{preInBack}, #{vailDispatch}, #{vailGroupBuy}#{busType}, #{inStock}#{actionType}) #{createTime}, #{preInBack}, #{vailDispatch}, #{vailGroupBuy}, #{busType}, #{inStock}, #{actionType}
, #{thrCheckEnable}, #{thrCheckWebNew}, #{thrCheckPdaUn}, #{thrCheckPdaEd}, #{thrCheckUdims},
#{thrCheckPc}
, #{thrCheckSp}, #{thrCheckChange}, #{thrCheckBalance}, #{thrCheckCopy})
</insert> </insert>
<select id="selectBusList" resultType="com.glxp.api.entity.basic.BasicBussinessTypeEntity"> <select id="selectBusList" resultType="com.glxp.api.entity.basic.BasicBussinessTypeEntity">

@ -181,7 +181,7 @@
specification, structure, `scope`, specification, structure, `scope`,
other, filePath, remark, other, filePath, remark,
createTime, updateTime, manufacturerIdFk, customerId, productId createTime, updateTime, manufacturerIdFk, customerId, productId
, auditStatus, auditComment, sptm, ybbm, measname, cpms, hchzsb) , auditStatus, auditComment, sptm, ybbm, measname, cpms, hchzsb,relIdFk)
values ( values (
#{enterpriseId}, #{enterpriseId},
#{recordCode}, #{recordCode},
@ -222,7 +222,7 @@
#{ybbm}, #{ybbm},
#{measname}, #{measname},
#{cpms}, #{cpms},
#{hchzsb} #{hchzsb},#{relIdFk}
) )
</insert> </insert>

@ -28,7 +28,16 @@ CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'busType', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'inStock', 'tinyint', 1); CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'inStock', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'actionType', 'tinyint', 1); CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'actionType', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckEnable', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckWebNew', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckPdaUn', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckPdaEd', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckUdims', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckPc', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckSp', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckChange', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckBalance', 'tinyint', 1);
CALL Pro_Temp_ColumnWork('basic_bussiness_type', 'thrCheckCopy', 'tinyint', 1);

Loading…
Cancel
Save