禅道相关bug修改

master
anthonywj 2 years ago
parent 30fa6198b5
commit 411499358d

@ -37,7 +37,7 @@ public class DeptUserController {
IoOrderService ioOrderService; IoOrderService ioOrderService;
@Resource @Resource
WarehouseUserService warehouseUserService; WarehouseUserService warehouseUserService;
@AuthRuleAnnotation("") @AuthRuleAnnotation("")

@ -90,7 +90,7 @@ public class IoOrderController extends BaseController {
if (filterOrderRequest.getSourceLocalType() == 1) { if (filterOrderRequest.getSourceLocalType() == 1) {
filterOrderRequest.setSourceTypes(Arrays.asList(1, 2, 3, 4, 5)); filterOrderRequest.setSourceTypes(Arrays.asList(1, 2, 3, 4, 5));
} else { } else {
filterOrderRequest.setSourceTypes(Arrays.asList(6,7, 8, 9, 10, 11, 12, 13, 14, 15, 17)); filterOrderRequest.setSourceTypes(Arrays.asList(6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 17));
} }
} }
@ -418,7 +418,7 @@ public class IoOrderController extends BaseController {
} else if (stockOrderEntity.getStatus() == ConstantStatus.ORDER_STATUS_CHECK_SUCCESS) { } else if (stockOrderEntity.getStatus() == ConstantStatus.ORDER_STATUS_CHECK_SUCCESS) {
//1.校验是否为委托验收人 //1.校验是否为委托验收人
if (!stockOrderEntity.getEntrustEnd()==true) { if (!stockOrderEntity.getEntrustEnd() == true) {
BasicEntrustRecRequest basicEntrustRecRequest = new BasicEntrustRecRequest(); BasicEntrustRecRequest basicEntrustRecRequest = new BasicEntrustRecRequest();
basicEntrustRecRequest.setAction(stockOrderEntity.getAction()); basicEntrustRecRequest.setAction(stockOrderEntity.getAction());
basicEntrustRecRequest.setEntrustUser(userId); basicEntrustRecRequest.setEntrustUser(userId);

@ -156,7 +156,7 @@ public class IoOrderDetailBizController extends BaseController {
datas.add(addBizProductReqeust); datas.add(addBizProductReqeust);
} }
for (AddBizProductReqeust item : datas) { for (AddBizProductReqeust item : datas) {
UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectSupGroupById(item.getRelId()); UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectSupGroupById(item.getRelId(), addBizProductReqeust.getSupId());
// todo 查询产品是否已经通过认证 // todo 查询产品是否已经通过认证
BasicBussinessTypeEntity bussinessTypeEntity = basicBussinessTypeService.findByAction(orderEntity.getAction()); BasicBussinessTypeEntity bussinessTypeEntity = basicBussinessTypeService.findByAction(orderEntity.getAction());
@ -169,6 +169,13 @@ public class IoOrderDetailBizController extends BaseController {
} }
} }
if (bussinessTypeEntity.isVailDispatch()) {
if (!udiRelevanceResponse.isDispatch()) {
return ResultVOUtils.error(500, "该产品不可配送,请联系院方!");
}
}
IoOrderDetailBizEntity ioOrderDetailBizEntity = new IoOrderDetailBizEntity(); IoOrderDetailBizEntity ioOrderDetailBizEntity = new IoOrderDetailBizEntity();
ioOrderDetailBizEntity.setOrderIdFk(orderEntity.getBillNo()); ioOrderDetailBizEntity.setOrderIdFk(orderEntity.getBillNo());
ioOrderDetailBizEntity.setBindRlFk(udiRelevanceResponse.getId()); ioOrderDetailBizEntity.setBindRlFk(udiRelevanceResponse.getId());

@ -23,7 +23,7 @@ public class CompanyController {
@GetMapping("/warehouse/info/company") @GetMapping("/warehouse/info/company")
public BaseResponse getCompanyInfo(CompanyRequest companyRequest) { public BaseResponse getCompanyInfo(CompanyRequest companyRequest) {
CompanyEntity companyEntity = companyService.findCompany(companyRequest.getCustomerId()); CompanyEntity companyEntity = companyService.findCompany(companyRequest.getCustomerId());
if (companyEntity != null) { if (companyEntity != null) {
return ResultVOUtils.success(companyEntity); return ResultVOUtils.success(companyEntity);
} }
return ResultVOUtils.error(500, "企业信息为空"); return ResultVOUtils.error(500, "企业信息为空");

@ -10,6 +10,7 @@ public class FilterUdiRelRequest extends ListPageRequest {
private String ylqxzcrbarmc; private String ylqxzcrbarmc;
private String cpmctymc; private String cpmctymc;
private String entireCpmctymc;
private String nameCode; private String nameCode;
private String uuid; private String uuid;
private String originUuid; private String originUuid;

@ -64,6 +64,9 @@ public class DeptUserServiceImpl implements DeptUserService {
@Override @Override
public boolean delete(Long deptId, Long userId) { public boolean delete(Long deptId, Long userId) {
return deptUserDao.deleteByDept(deptId, userId); return deptUserDao.deleteByDept(deptId, userId);
} }

@ -55,7 +55,7 @@ public interface UdiRelevanceService extends IService<UdiRelevanceEntity> {
UdiRelevanceResponse selectUdiId(Long id); UdiRelevanceResponse selectUdiId(Long id);
UdiRelevanceResponse selectSupGroupById(Long id); UdiRelevanceResponse selectSupGroupById(Long id, String supId);
UdiRelevanceEntity selectUpdateByUuid(String uuid); UdiRelevanceEntity selectUpdateByUuid(String uuid);

@ -208,8 +208,10 @@ public class UdiRelevanceServiceImpl extends ServiceImpl<UdiRelevanceDao, UdiRel
} }
@Override @Override
public UdiRelevanceResponse selectSupGroupById(Long id) { public UdiRelevanceResponse selectSupGroupById(Long id, String supId) {
FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest(); FilterUdiRelRequest filterUdiRelRequest = new FilterUdiRelRequest();
if (StrUtil.isNotEmpty(supId))
filterUdiRelRequest.setUnitFk(supId);
filterUdiRelRequest.setId(id); filterUdiRelRequest.setId(id);
filterUdiRelRequest.setDiType(1); filterUdiRelRequest.setDiType(1);
return udiRelevanceDao.selectOneUdiJoinSup(filterUdiRelRequest); return udiRelevanceDao.selectOneUdiJoinSup(filterUdiRelRequest);

@ -308,7 +308,7 @@ public class IoAddInoutService {
public void genOrderDetailCode(IoOrderEntity orderEntity, IoCodeTempEntity codeTempEntity) { public void genOrderDetailCode(IoOrderEntity orderEntity, IoCodeTempEntity codeTempEntity) {
List<IoOrderDetailCodeEntity> ioOrderDetailCodeEntities = orderDetailCodeDao.selectList(new QueryWrapper<IoOrderDetailCodeEntity>().select("id", "count", "reCount", "bindRlFk", "batchNo").eq("orderIdFk", orderEntity.getBillNo())); List<IoOrderDetailCodeEntity> ioOrderDetailCodeEntities = orderDetailCodeDao.selectList(new QueryWrapper<IoOrderDetailCodeEntity>().select("id", "count", "reCount", "bindRlFk", "batchNo").eq("orderIdFk", orderEntity.getBillNo()));
UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectSupGroupById(codeTempEntity.getRelId()); UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectSupGroupById(codeTempEntity.getRelId(), orderEntity.getFromCorp());
// UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectGroupById(codeTempEntity.getRelId()); // UdiRelevanceResponse udiRelevanceResponse = udiRelevanceService.selectGroupById(codeTempEntity.getRelId());
if (CollUtil.isEmpty(ioOrderDetailCodeEntities)) { if (CollUtil.isEmpty(ioOrderDetailCodeEntities)) {
orderDetailCodeService.insert(buildEntity(orderEntity, codeTempEntity, udiRelevanceResponse)); orderDetailCodeService.insert(buildEntity(orderEntity, codeTempEntity, udiRelevanceResponse));

@ -491,20 +491,27 @@ public class IoOrderServiceImpl implements IoOrderService {
public boolean rollbackUnReOrder(String billNo) { public boolean rollbackUnReOrder(String billNo) {
IoOrderEntity orderEntity = findByBillNo(billNo); IoOrderEntity orderEntity = findByBillNo(billNo);
List<IoCodeEntity> codeEntityList = codeService.findByOrderId(billNo); if (orderEntity.getStatus() == ConstantStatus.ORDER_STATUS_CHECK_SUCCESS) {
List<IoCodeTempEntity> codeTempEntities = new ArrayList<>(); List<IoCodeEntity> codeEntityList = codeService.findByOrderId(billNo);
for (IoCodeEntity codeEntity : codeEntityList) { List<IoCodeTempEntity> codeTempEntities = new ArrayList<>();
IoCodeTempEntity codeTempEntity = new IoCodeTempEntity(); for (IoCodeEntity codeEntity : codeEntityList) {
BeanUtils.copyProperties(codeEntity, codeTempEntity); IoCodeTempEntity codeTempEntity = new IoCodeTempEntity();
codeTempEntity.setId(null); BeanUtils.copyProperties(codeEntity, codeTempEntity);
codeTempEntities.add(codeTempEntity); codeTempEntity.setId(null);
codeTempEntities.add(codeTempEntity);
}
codeTempService.insertBatch(codeTempEntities);
codeService.deleteCodeByOrderId(billNo);
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK);
orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST);
orderEntity.setUpdateTime(new Date());
update(orderEntity);
} else if (orderEntity.getStatus() == ConstantStatus.ORDER_STATUS_CHECK_REW) {
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_SUCCESS);
orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST);
orderEntity.setUpdateTime(new Date());
update(orderEntity);
} }
codeTempService.insertBatch(codeTempEntities);
codeService.deleteCodeByOrderId(billNo);
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK);
orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST);
orderEntity.setUpdateTime(new Date());
update(orderEntity);
return true; return true;
} }
@ -805,7 +812,7 @@ public class IoOrderServiceImpl implements IoOrderService {
@Override @Override
public List<IoOrderEntity> selectList(Long userId) { public List<IoOrderEntity> selectList(Long userId) {
List<IoOrderEntity> ioOrderEntities = orderDao.selectList(new QueryWrapper<IoOrderEntity>().eq("createUser",userId)); List<IoOrderEntity> ioOrderEntities = orderDao.selectList(new QueryWrapper<IoOrderEntity>().eq("createUser", userId));
return ioOrderEntities; return ioOrderEntities;
} }

@ -21,8 +21,8 @@ import javax.annotation.Resource;
import java.util.Arrays; import java.util.Arrays;
@Component //@Component
@EnableScheduling //@EnableScheduling
public class AsyncHeartTask implements SchedulingConfigurer { public class AsyncHeartTask implements SchedulingConfigurer {
final Logger logger = LoggerFactory.getLogger(AsyncHeartTask.class); final Logger logger = LoggerFactory.getLogger(AsyncHeartTask.class);

@ -327,6 +327,10 @@
<if test="nameCode != '' and nameCode != null"> <if test="nameCode != '' and nameCode != null">
AND nameCode LIKE concat(#{nameCode}, '%') AND nameCode LIKE concat(#{nameCode}, '%')
</if> </if>
<if test="entireCpmctymc != '' and entireCpmctymc != null">
AND cpmctymc = #{entireCpmctymc}
</if>
<if test="cpmctymc != '' and cpmctymc != null"> <if test="cpmctymc != '' and cpmctymc != null">
AND cpmctymc LIKE concat('%', #{cpmctymc}, '%') AND cpmctymc LIKE concat('%', #{cpmctymc}, '%')
</if> </if>
@ -335,9 +339,9 @@
</if> </if>
<if test="unionCode != '' and unionCode != null"> <if test="unionCode != '' and unionCode != null">
and ( and (
nameCode LIKE concat('%', #{unionCode}, '%') nameCode LIKE concat('%', #{unionCode}, '%')
or ybbm LIKE concat('%', #{unionCode}, '%') or ybbm LIKE concat('%', #{unionCode}, '%')
or sptm LIKE concat('%', #{unionCode}, '%')) or sptm LIKE concat('%', #{unionCode}, '%'))
</if> </if>
<if test="isDisable == false"> <if test="isDisable == false">
AND (basic_udirel.isDisable is null or basic_udirel.isDisable = false) AND (basic_udirel.isDisable is null or basic_udirel.isDisable = false)
@ -367,30 +371,30 @@
<if test="filterType != null and filterType == 1"> <if test="filterType != null and filterType == 1">
AND (thirdId <![CDATA[<>]]> '' or thirdId1 <![CDATA[<>]]> '' or thirdId2 <![CDATA[<>]]> '' or AND (thirdId <![CDATA[<>]]> '' or thirdId1 <![CDATA[<>]]> '' or thirdId2 <![CDATA[<>]]> '' or
thirdId3 <![CDATA[<>]]> '' or thirdId4 <![CDATA[<>]]> '') thirdId3 <![CDATA[<>]]> '' or thirdId4 <![CDATA[<>]]> '')
and basic_products.originUuid <![CDATA[<>]]> '' and basic_products.originUuid <![CDATA[<>]]> ''
</if> </if>
<if test="filterType != null and filterType == 2"> <if test="filterType != null and filterType == 2">
AND basic_products.originUuid is NULL AND basic_products.originUuid is NULL
</if> </if>
<if test="filterType != null and filterType == 3"> <if test="filterType != null and filterType == 3">
AND (mainId is NULL or mainId = '') AND (mainId is NULL or mainId = '')
and basic_products.originUuid <![CDATA[<>]]> '' and basic_products.originUuid <![CDATA[<>]]> ''
</if> </if>
<if test="filterType != null and filterType == 4"> <if test="filterType != null and filterType == 4">
AND thirdId1 is NULL AND thirdId1 is NULL
and basic_products.originUuid <![CDATA[<>]]> '' and basic_products.originUuid <![CDATA[<>]]> ''
</if> </if>
<if test="filterType != null and filterType == 5"> <if test="filterType != null and filterType == 5">
AND thirdId2 is NULL AND thirdId2 is NULL
and basic_products.originUuid <![CDATA[<>]]> '' and basic_products.originUuid <![CDATA[<>]]> ''
</if> </if>
<if test="filterType != null and filterType == 6"> <if test="filterType != null and filterType == 6">
AND thirdId3 is NULL AND thirdId3 is NULL
and basic_products.originUuid <![CDATA[<>]]> '' and basic_products.originUuid <![CDATA[<>]]> ''
</if> </if>
<if test="filterType != null and filterType == 7"> <if test="filterType != null and filterType == 7">
AND thirdId4 is NULL AND thirdId4 is NULL
and basic_products.originUuid <![CDATA[<>]]> '' and basic_products.originUuid <![CDATA[<>]]> ''
</if> </if>
<if test="filterType != null and filterType == 10"> <if test="filterType != null and filterType == 10">
AND basic_udirel.updateTime is NULL AND basic_udirel.updateTime is NULL
@ -408,7 +412,7 @@
and originUuid = #{originUuid} and originUuid = #{originUuid}
</if> </if>
<if test="manufactory != null and manufactory != ''"> <if test="manufactory != null and manufactory != ''">
and manufactory LIKE concat('%',#{manufactory},'%') and manufactory LIKE concat('%', #{manufactory}, '%')
</if> </if>
<if test="dispatch != null"> <if test="dispatch != null">
and basic_udirel.dispatch = #{dispatch} and basic_udirel.dispatch = #{dispatch}
@ -585,8 +589,6 @@
<if test="tyshxydm != '' and tyshxydm != null"> <if test="tyshxydm != '' and tyshxydm != null">
AND basic_products.tyshxydm = #{tyshxydm} AND basic_products.tyshxydm = #{tyshxydm}
</if> </if>
</where> </where>
GROUP BY cpmctymc, manufactory GROUP BY cpmctymc, manufactory
</select> </select>
@ -1125,65 +1127,65 @@
<select id="selectOneUdiJoinSup" resultType="com.glxp.api.res.basic.UdiRelevanceResponse"> <select id="selectOneUdiJoinSup" resultType="com.glxp.api.res.basic.UdiRelevanceResponse">
select basic_udirel.*, select basic_udirel.*,
basic_products.originUuid, basic_products.originUuid,
basic_products.nameCode, basic_products.nameCode,
basic_products.deviceRecordKey, basic_products.deviceRecordKey,
basic_products.packRatio, basic_products.packRatio,
basic_products.packUnit, basic_products.packUnit,
basic_products.packLevel, basic_products.packLevel,
basic_products.bhxjsl, basic_products.bhxjsl,
basic_products.bhzxxsbzsl, basic_products.bhzxxsbzsl,
basic_products.zxxsbzbhsydysl, basic_products.zxxsbzbhsydysl,
basic_products.bhxjcpbm, basic_products.bhxjcpbm,
basic_products.bzcj, basic_products.bzcj,
basic_products.cpmctymc, basic_products.cpmctymc,
basic_products.cplb, basic_products.cplb,
basic_products.flbm, basic_products.flbm,
basic_products.ggxh, basic_products.ggxh,
basic_products.qxlb, basic_products.qxlb,
basic_products.tyshxydm, basic_products.tyshxydm,
basic_products.ylqxzcrbarmc, basic_products.ylqxzcrbarmc,
basic_products.zczbhhzbapzbh, basic_products.zczbhhzbapzbh,
basic_products.ylqxzcrbarywmc, basic_products.ylqxzcrbarywmc,
basic_products.sydycpbs, basic_products.sydycpbs,
basic_products.sjcpbm, basic_products.sjcpbm,
basic_products.versionNumber, basic_products.versionNumber,
basic_products.diType, basic_products.diType,
basic_products.ybbm, basic_products.ybbm,
basic_products.sptm, basic_products.sptm,
basic_products.manufactory, basic_products.manufactory,
basic_products.measname, basic_products.measname,
basic_products.productType, basic_products.productType,
basic_products.scbssfbhph, basic_products.scbssfbhph,
basic_products.scbssfbhxlh, basic_products.scbssfbhxlh,
basic_products.scbssfbhscrq, basic_products.scbssfbhscrq,
basic_products.scbssfbhsxrq, basic_products.scbssfbhsxrq,
basic_products.cpms, basic_products.cpms,
basic_products.allowNoBatch, basic_products.allowNoBatch,
basic_products.allowNoExpire, basic_products.allowNoExpire,
basic_products.allowNoProduct, basic_products.allowNoProduct,
basic_products.allowNoSerial, basic_products.allowNoSerial,
basic_products.spmc, basic_products.spmc,
basic_products.cplx, basic_products.cplx,
basic_products.hchzsb, basic_products.hchzsb,
basic_products.cpdls, basic_products.cpdls,
company_product_relevance.price, company_product_relevance.price,
basic_products.basicPrductRemak1, basic_products.basicPrductRemak1,
basic_products.basicPrductRemak2, basic_products.basicPrductRemak2,
basic_products.basicPrductRemak3, basic_products.basicPrductRemak3,
basic_products.basicPrductRemak4, basic_products.basicPrductRemak4,
basic_products.basicPrductRemak5, basic_products.basicPrductRemak5,
basic_products.basicPrductRemak6, basic_products.basicPrductRemak6,
basic_products.basicPrductRemak7, basic_products.basicPrductRemak7,
basic_products.basicPrductRemak8, basic_products.basicPrductRemak8,
company_product_relevance.unitFk, company_product_relevance.unitFk,
basic_corp.name companyName basic_corp.name companyName
FROM basic_udirel FROM basic_udirel
inner JOIN basic_products inner JOIN basic_products
ON basic_products.uuid = basic_udirel.uuid ON basic_products.uuid = basic_udirel.uuid
left join company_product_relevance left join company_product_relevance
on basic_udirel.id = company_product_relevance.udiRlIdFk on basic_udirel.id = company_product_relevance.udiRlIdFk
left JOIN basic_corp on basic_corp.erpId = company_product_relevance.customerId left JOIN basic_corp on basic_corp.erpId = company_product_relevance.customerId
<where> <where>
<if test="ylqxzcrbarmc != '' and ylqxzcrbarmc != null"> <if test="ylqxzcrbarmc != '' and ylqxzcrbarmc != null">
AND ylqxzcrbarmc LIKE concat('%', #{ylqxzcrbarmc}, '%') AND ylqxzcrbarmc LIKE concat('%', #{ylqxzcrbarmc}, '%')

@ -32,6 +32,7 @@
LEFT JOIN io_order a1 ON a1.billNo = a2.orderIdFk LEFT JOIN io_order a1 ON a1.billNo = a2.orderIdFk
LEFT JOIN basic_corp b1 ON b1.erpId = a1.fromCorp LEFT JOIN basic_corp b1 ON b1.erpId = a1.fromCorp
<where> <where>
a1.status = 7
<if test="orderIdFk != null and orderIdFk != ''"> <if test="orderIdFk != null and orderIdFk != ''">
AND a2.orderIdFk = #{orderIdFk} AND a2.orderIdFk = #{orderIdFk}
</if> </if>

Loading…
Cancel
Save