第三方bug修改

pro
郑明梁 2 years ago
parent f81471d4e6
commit 4b4d6beb7a

@ -105,11 +105,11 @@ public class ThrBusTypeOriginController {
return ResultVOUtils.error(ResultEnum.PARAM_VERIFY_FALL, bindingResult.getFieldError().getDefaultMessage()); return ResultVOUtils.error(ResultEnum.PARAM_VERIFY_FALL, bindingResult.getFieldError().getDefaultMessage());
} }
if (thrBusTypeOriginEntity != null) { if (thrBusTypeOriginEntity != null) {
//校验单据类型代码是否重复 // 校验单据类型代码是否重复
// boolean exists = thrBusTypeOriginService.checkActionExists(thrBusTypeOriginEntity.getAction(), thrBusTypeOriginEntity.getThirdSys()); boolean exists = thrBusTypeOriginService.checkActionExists(thrBusTypeOriginEntity.getAction(), thrBusTypeOriginEntity.getThirdSys());
// if (exists) { if (exists) {
// return ResultVOUtils.error(500, "单据类型已存在!"); return ResultVOUtils.error(500, "单据类型已存在!");
// } }
thrBusTypeOriginService.updateBusOriginType(thrBusTypeOriginEntity); thrBusTypeOriginService.updateBusOriginType(thrBusTypeOriginEntity);
} else { } else {
ResultVOUtils.error(999, "参数错误"); ResultVOUtils.error(999, "参数错误");

@ -286,9 +286,9 @@ public class ThrOrderController {
return ResultVOUtils.error(500, "当前任务正在下载更新业务单据信息,请稍后重试!"); return ResultVOUtils.error(500, "当前任务正在下载更新业务单据信息,请稍后重试!");
} else { } else {
redisUtil.set(Constant.dlThrOrders, "true", 10 * 30); redisUtil.set(Constant.dlThrOrders, "true", 10 * 30);
if (filterThrProductsRequest.getBillAction() == null) { // if (filterThrProductsRequest.getBillAction() == null) {
return ResultVOUtils.error(500, "未选择业务类型!"); // return ResultVOUtils.error(500, "未选择业务类型!");
} // }
ThrOrderImportLogEntity thrOrderImportLogEntity = new ThrOrderImportLogEntity(); ThrOrderImportLogEntity thrOrderImportLogEntity = new ThrOrderImportLogEntity();
String genKey = CustomUtil.getId(); String genKey = CustomUtil.getId();
@ -356,8 +356,8 @@ public class ThrOrderController {
} }
//只查询第三方单据 //只查询第三方单据
@GetMapping("/udiwms/thirdOrder/filter") @PostMapping("/udiwms/thirdOrder/filter")
public BaseResponse filterThirdOrder(FilterThrOrderRequest filterErpOrderRequest, public BaseResponse filterThirdOrder(@RequestBody FilterThrOrderRequest filterErpOrderRequest,
BindingResult bindingResult) { BindingResult bindingResult) {
if (bindingResult.hasErrors()) { if (bindingResult.hasErrors()) {
@ -390,7 +390,7 @@ public class ThrOrderController {
if (data != null && data.size() > 0) { if (data != null && data.size() > 0) {
for (ThrOrderEntity thrOrderEntity : data) { for (ThrOrderEntity thrOrderEntity : data) {
FilterThrOrderDetailRequest filterThrOrderDetailRequest = new FilterThrOrderDetailRequest(); FilterThrOrderDetailRequest filterThrOrderDetailRequest = new FilterThrOrderDetailRequest();
filterThrOrderDetailRequest.setOrderIdFk(thrOrderEntity.getId() + ""); filterThrOrderDetailRequest.setOrderIdFk(thrOrderEntity.getBillNo() + "");
List<ThrOrderDetailEntity> thrOrderDetailEntities = thrOrderDetailService.filterThrOrderDetailDetail(filterThrOrderDetailRequest); List<ThrOrderDetailEntity> thrOrderDetailEntities = thrOrderDetailService.filterThrOrderDetailDetail(filterThrOrderDetailRequest);
ThrOrderResponse erpOrderResponse = new ThrOrderResponse(); ThrOrderResponse erpOrderResponse = new ThrOrderResponse();
BeanUtils.copyProperties(thrOrderEntity, erpOrderResponse); BeanUtils.copyProperties(thrOrderEntity, erpOrderResponse);

@ -47,6 +47,10 @@ public class ThrOrderEntity {
@TableField(value = "billType") @TableField(value = "billType")
private String billType; private String billType;
@TableField(value = "originType")
private String originType;
/** /**
* *
*/ */
@ -161,6 +165,7 @@ public class ThrOrderEntity {
@TableField(value = "remark") @TableField(value = "remark")
private String remark; private String remark;
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
public static final String COL_ID = "id"; public static final String COL_ID = "id";

@ -1,5 +1,6 @@
package com.glxp.api.res.thrsys; package com.glxp.api.res.thrsys;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.Data; import lombok.Data;
import java.math.BigDecimal; import java.math.BigDecimal;
@ -37,6 +38,7 @@ public class ThrOrderResponse {
private String remark3; //备注3 private String remark3; //备注3
private String invWarehouseName; private String invWarehouseName;
private String fromSubInvName; private String fromSubInvName;
private String billTypeName;
public static class SubErpOrder { public static class SubErpOrder {
private Integer id; private Integer id;
@ -56,7 +58,6 @@ public class ThrOrderResponse {
private String detailId; //明细ID private String detailId; //明细ID
private String corpName; //往来单位 private String corpName; //往来单位
private BigDecimal price; //单价 private BigDecimal price; //单价
public String getDetailId() { public String getDetailId() {
return detailId; return detailId;
} }

@ -6,7 +6,7 @@
resultType="com.glxp.api.entity.thrsys.ThrOrderEntity"> resultType="com.glxp.api.entity.thrsys.ThrOrderEntity">
SELECT thr_order.*, thr_bustype_origin.name billTypeName SELECT thr_order.*, thr_bustype_origin.name billTypeName
FROM thr_order FROM thr_order
left join thr_bustype_origin on thr_order.billType = thr_bustype_origin.action LEFT JOIN thr_bustype_origin ON thr_order.billType = thr_bustype_origin.action
<where> <where>
<if test="billNo != '' and billNo != null"> <if test="billNo != '' and billNo != null">
AND billNo = #{billNo} AND billNo = #{billNo}
@ -15,7 +15,7 @@
AND thr_order.id = #{id} AND thr_order.id = #{id}
</if> </if>
<if test="billAction != '' and billAction != null"> <if test="billAction != '' and billAction != null">
AND billType = #{billAction} AND thr_bustype_origin.action = #{billAction}
</if> </if>
<if test="billFlag != '' and billFlag != null"> <if test="billFlag != '' and billFlag != null">
AND billFlag = #{billFlag} AND billFlag = #{billFlag}

Loading…
Cancel
Save