去掉所有未引用多余包

dev_drug_dm
qiuyt 1 month ago
parent 61a8143802
commit dbd9ec75fa

@ -8,12 +8,9 @@ import com.glxp.api.httpClient.utils.HttpOkClient;
import com.glxp.api.req.thrsys.ThrOnhandRequest; import com.glxp.api.req.thrsys.ThrOnhandRequest;
import com.glxp.api.res.PageSimpleResponse; import com.glxp.api.res.PageSimpleResponse;
import com.glxp.api.res.thrsys.ThrInvProductResponse; import com.glxp.api.res.thrsys.ThrInvProductResponse;
import com.glxp.api.util.StringUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.util.HashMap;
import java.util.Map;
@Service @Service
public class ErpInvClientImpl implements ErpInvClient { public class ErpInvClientImpl implements ErpInvClient {

@ -1,6 +1,5 @@
package com.glxp.api.service.auth.impl; package com.glxp.api.service.auth.impl;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.StrUtil;
import com.glxp.api.dao.auth.DeptDao; import com.glxp.api.dao.auth.DeptDao;
import com.glxp.api.entity.auth.DeptEntity; import com.glxp.api.entity.auth.DeptEntity;

@ -6,26 +6,17 @@ import com.glxp.api.annotation.Log;
import com.glxp.api.common.res.BaseResponse; import com.glxp.api.common.res.BaseResponse;
import com.glxp.api.constant.BasicProcessStatus; import com.glxp.api.constant.BasicProcessStatus;
import com.glxp.api.constant.BusinessType; import com.glxp.api.constant.BusinessType;
import com.glxp.api.entity.basic.BasicCorpEntity;
import com.glxp.api.entity.basic.BasicCorpsExportLogEntity; import com.glxp.api.entity.basic.BasicCorpsExportLogEntity;
import com.glxp.api.entity.basic.BasicProductsExportLogEntity; import com.glxp.api.entity.basic.BasicProductsExportLogEntity;
import com.glxp.api.entity.sync.SyncDataSetEntity; import com.glxp.api.entity.sync.SyncDataSetEntity;
import com.glxp.api.httpClient.utils.HttpOkClient; import com.glxp.api.httpClient.utils.HttpOkClient;
import com.glxp.api.req.basic.BasicCorpsExportRequest;
import com.glxp.api.req.basic.BasicUnitMaintainFilterRequest;
import com.glxp.api.res.basic.BasicCorpExportLogResponse; import com.glxp.api.res.basic.BasicCorpExportLogResponse;
import com.glxp.api.res.basic.UdiRelevanceExportJsonResponse; import com.glxp.api.res.basic.UdiRelevanceExportJsonResponse;
import com.glxp.api.service.sync.SyncDataSetService; import com.glxp.api.service.sync.SyncDataSetService;
import com.glxp.api.util.ExcelUtil;
import org.springframework.beans.BeanUtils;
import org.springframework.scheduling.annotation.Async; import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
@Service @Service
public class BasicGenExcelService { public class BasicGenExcelService {

@ -34,7 +34,6 @@ import org.apache.commons.lang3.exception.ExceptionUtils;
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.BeanUtils;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;

@ -4,6 +4,7 @@ import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.date.DateUtil; import cn.hutool.core.date.DateUtil;
import cn.hutool.core.io.FileUtil; import cn.hutool.core.io.FileUtil;
import cn.hutool.core.thread.ThreadUtil; import cn.hutool.core.thread.ThreadUtil;
import cn.hutool.core.util.ObjectUtil;
import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.StrUtil;
import cn.hutool.core.util.XmlUtil; import cn.hutool.core.util.XmlUtil;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
@ -39,6 +40,7 @@ import com.glxp.api.service.basic.ProductInfoService;
import com.glxp.api.service.basic.UdiProductService; import com.glxp.api.service.basic.UdiProductService;
import com.glxp.api.service.sync.SyncDataSetService; import com.glxp.api.service.sync.SyncDataSetService;
import com.glxp.api.util.HttpClient; import com.glxp.api.util.HttpClient;
import com.glxp.api.util.StringUtils;
import com.glxp.api.util.alihealth.AlihealthUtils; import com.glxp.api.util.alihealth.AlihealthUtils;
import com.glxp.api.util.alihealth.AlihealthYljgUtils; import com.glxp.api.util.alihealth.AlihealthYljgUtils;
import com.glxp.api.util.udi.FilterUdiUtils; import com.glxp.api.util.udi.FilterUdiUtils;
@ -394,54 +396,56 @@ public class RelCodeBatchService extends ServiceImpl<RelCodeBatchMapper, RelCode
return; return;
List<RelCodeBatch> navList = this.list(new LambdaQueryWrapper<RelCodeBatch>() List<RelCodeBatch> navList = this.list(new LambdaQueryWrapper<RelCodeBatch>()
.eq(RelCodeBatch::getCurCode, parentCode)); .eq(RelCodeBatch::getCurCode, parentCode));
// codeTempEntity.getSupId()
//todo if(navList)是空的 1.查供应商key2根据parentCode查阿里接口3根据返回结果再次查询
if (navList == null || navList.size() == 0) { if (navList == null || navList.size() == 0) {
CustomerInfoEntity customerInfoEntity = customerInfoService.selectById(codeTempEntity.getSupId()); CustomerInfoEntity customerInfoEntity = customerInfoService.selectById(codeTempEntity.getSupId());
if(ObjectUtil.isNotNull(customerInfoEntity)
AlihealthRelCodeInsertReqeust alihealthRelCodeInsertReqeust = new AlihealthRelCodeInsertReqeust(); && StringUtils.isNotEmpty(customerInfoEntity.getAppKey())
alihealthRelCodeInsertReqeust.setAppKey(customerInfoEntity.getAppKey()); && StringUtils.isNotEmpty(customerInfoEntity.getAppSecret())
alihealthRelCodeInsertReqeust.setAppSecret(customerInfoEntity.getAppSecret()); && StringUtils.isNotEmpty(customerInfoEntity.getRefEntId())
alihealthRelCodeInsertReqeust.setCustomerId(codeTempEntity.getSupId());
alihealthRelCodeInsertReqeust.setCode(parentCode); ){
alihealthRelCodeInsertReqeust.setRefEntId(customerInfoEntity.getRefEntId()); AlihealthRelCodeInsertReqeust alihealthRelCodeInsertReqeust = new AlihealthRelCodeInsertReqeust();
alihealthRelCodeInsertReqeust.setAppKey(customerInfoEntity.getAppKey());
BaseResponse<AlihealthKytSinglerelationResponse> baseResponse = alihealthUtils.relCodeInsert(alihealthRelCodeInsertReqeust); alihealthRelCodeInsertReqeust.setAppSecret(customerInfoEntity.getAppSecret());
if (baseResponse.getCode() == 20000) { alihealthRelCodeInsertReqeust.setCustomerId(codeTempEntity.getSupId());
AlihealthKytSinglerelationResponse alihealthKytSinglerelationResponse = baseResponse.getData(); alihealthRelCodeInsertReqeust.setCode(parentCode);
// 返回的码关联关系进行插入 alihealthRelCodeInsertReqeust.setRefEntId(customerInfoEntity.getRefEntId());
RelCodeBatch relCodeBatch = alihealthKytSinglerelationResponse.disposeRelCodeBatch(alihealthRelCodeInsertReqeust.getCustomerId());
RelCodeBatch relCodeBatchOne = relCodeBatchService.getOne(new QueryWrapper<RelCodeBatch>().eq("productCode", relCodeBatch.getProductCode()) BaseResponse<AlihealthKytSinglerelationResponse> baseResponse = alihealthUtils.relCodeInsert(alihealthRelCodeInsertReqeust);
.last("limit 1") if (baseResponse.getCode() == 20000) {
); AlihealthKytSinglerelationResponse alihealthKytSinglerelationResponse = baseResponse.getData();
if (Objects.isNull(relCodeBatchOne)) { // 返回的码关联关系进行插入
relCodeBatch.setCreateUser(alihealthRelCodeInsertReqeust.getCustomerId()); RelCodeBatch relCodeBatch = alihealthKytSinglerelationResponse.disposeRelCodeBatch(alihealthRelCodeInsertReqeust.getCustomerId());
relCodeBatch.setCreateTime(new Date()); RelCodeBatch relCodeBatchOne = relCodeBatchService.getOne(new QueryWrapper<RelCodeBatch>().eq("productCode", relCodeBatch.getProductCode())
relCodeBatchService.save(relCodeBatch); .last("limit 1")
);
} else { if (Objects.isNull(relCodeBatchOne)) {
relCodeBatchService.update(relCodeBatch, new QueryWrapper<RelCodeBatch>().eq("productCode", relCodeBatch.getProductCode())); relCodeBatch.setCreateUser(alihealthRelCodeInsertReqeust.getCustomerId());
} relCodeBatch.setCreateTime(new Date());
Integer id = Objects.isNull(relCodeBatch.getId()) ? relCodeBatchOne.getId() : relCodeBatch.getId(); relCodeBatchService.save(relCodeBatch);
// 进行查询 } else {
List<RelCodeDetail> list = alihealthKytSinglerelationResponse.disposeRelRodeDetailList(id); relCodeBatchService.update(relCodeBatch, new QueryWrapper<RelCodeBatch>().eq("productCode", relCodeBatch.getProductCode()));
if (list != null && list.size() > 0) {
List curCodeList = new ArrayList();
for (RelCodeDetail relCodeDetail : list) {
curCodeList.add(relCodeDetail.getCurCode());
} }
relCodeDetailService.remove(new QueryWrapper<RelCodeDetail>().in("curCode", curCodeList)); Integer id = Objects.isNull(relCodeBatch.getId()) ? relCodeBatchOne.getId() : relCodeBatch.getId();
// 进行查询
relCodeDetailService.saveBatch(list); List<RelCodeDetail> list = alihealthKytSinglerelationResponse.disposeRelRodeDetailList(id);
if (list != null && list.size() > 0) {
List curCodeList = new ArrayList();
for (RelCodeDetail relCodeDetail : list) {
curCodeList.add(relCodeDetail.getCurCode());
}
relCodeDetailService.remove(new QueryWrapper<RelCodeDetail>().in("curCode", curCodeList));
relCodeDetailService.saveBatch(list);
}
// 插入成功就重新查询一下
navList = this.list(new LambdaQueryWrapper<RelCodeBatch>()
.eq(RelCodeBatch::getCurCode, parentCode));
} else {
log.error(baseResponse.getMessage());
} }
// 插入成功就重新查询一下
navList = this.list(new LambdaQueryWrapper<RelCodeBatch>()
.eq(RelCodeBatch::getCurCode, parentCode));
} else {
log.error(baseResponse.getMessage());
} }
}
}
if ((udiProductEntity != null && "1".equals(udiProductEntity.getPackLevel())) if ((udiProductEntity != null && "1".equals(udiProductEntity.getPackLevel()))
|| (CollUtil.isNotEmpty(navList)) || (CollUtil.isNotEmpty(navList))
) { ) {

@ -16,7 +16,6 @@ import com.glxp.api.res.inout.PlatformLinkResponse;
import com.glxp.api.res.inout.ioUploadOrderResponse; import com.glxp.api.res.inout.ioUploadOrderResponse;
import com.glxp.api.util.GennerOrderUtils; import com.glxp.api.util.GennerOrderUtils;
import com.glxp.api.util.OrderNoTypeBean; import com.glxp.api.util.OrderNoTypeBean;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import javax.annotation.Resource; import javax.annotation.Resource;

@ -7,7 +7,6 @@ import com.glxp.api.entity.inv.InvInnerOrderPdfTempEntity;
import com.glxp.api.res.inv.InnerOrderPrintResponse; import com.glxp.api.res.inv.InnerOrderPrintResponse;
import com.glxp.api.util.JasperUtils; import com.glxp.api.util.JasperUtils;
import net.sf.jasperreports.engine.JRException; import net.sf.jasperreports.engine.JRException;
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;

@ -44,7 +44,6 @@ import com.glxp.api.service.inout.impl.IoOrderInvoiceService;
import com.glxp.api.service.inv.DeviceInspectTaskDetailService; import com.glxp.api.service.inv.DeviceInspectTaskDetailService;
import com.glxp.api.service.inv.DeviceInspectTaskService; import com.glxp.api.service.inv.DeviceInspectTaskService;
import com.glxp.api.service.purchase.*; import com.glxp.api.service.purchase.*;
import com.glxp.api.service.thrsys.IThrBusTypeOriginService;
import com.glxp.api.service.thrsys.ThrManufacturerService; import com.glxp.api.service.thrsys.ThrManufacturerService;
import com.glxp.api.util.*; import com.glxp.api.util.*;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;

@ -2,7 +2,6 @@ package com.glxp.api.service.thrsys.impl;
import cn.hutool.core.util.StrUtil; import cn.hutool.core.util.StrUtil;
import com.glxp.api.dao.thrsys.ThrOrderDao; import com.glxp.api.dao.thrsys.ThrOrderDao;
import com.glxp.api.dao.thrsys.ThrOrderDetailDao;
import com.glxp.api.entity.thrsys.ThrOrderEntity; import com.glxp.api.entity.thrsys.ThrOrderEntity;
import com.glxp.api.req.thrsys.FilterThrOrderRequest; import com.glxp.api.req.thrsys.FilterThrOrderRequest;
import com.glxp.api.service.thrsys.ThrOrderService; import com.glxp.api.service.thrsys.ThrOrderService;

@ -2,6 +2,7 @@ package com.glxp.api.util.alihealth;
import com.glxp.api.util.StringUtils; import com.glxp.api.util.StringUtils;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.exception.ExceptionUtils;
import java.lang.reflect.Field; import java.lang.reflect.Field;
import java.util.Map; import java.util.Map;
@ -37,14 +38,8 @@ public class CopyUtils {
} }
} }
} }
} catch (Exception e) { } catch (Exception e) {
log.error("对象转换错误==="+e.getMessage()); log.error("对象转换错误==="+ExceptionUtils.getStackTrace(e));
e.printStackTrace();
// BeanUtil.copyProperties(source, target);
} }
} }

Loading…
Cancel
Save