Merge remote-tracking branch 'origin/dev' into dev

# Conflicts:
#	src/main/java/com/glxp/api/service/thrsys/impl/ThrDeptServiceImpl.java
pro
anthonywj 2 years ago
commit e1bf9bad81

@ -210,7 +210,7 @@ public class BasicOrderPrintController {
data.put("data", list); data.put("data", list);
String param = JSON.toJSONString(data); String param = JSON.toJSONString(data);
JasperUtils.jasperReport(request, response, param, systemPDFTemplateEntity.getPath(), "pdf"); JasperUtils.jasperReport(request, response, param, filePath + "/pdf/template/"+systemPDFTemplateEntity.getPath(), "pdf");
} }
public String getStatusName(Integer type){ public String getStatusName(Integer type){

@ -137,6 +137,7 @@ public class ThrDeptServiceImpl extends ServiceImpl<ThrDeptDao, ThrDeptEntity> i
if (baseResponse.getCode() == 20000) { if (baseResponse.getCode() == 20000) {
List<UdiwmsWarehouseDetail> responseList = baseResponse.getData().getList(); List<UdiwmsWarehouseDetail> responseList = baseResponse.getData().getList();
List<ThrDeptEntity> list = new ArrayList<>(); List<ThrDeptEntity> list = new ArrayList<>();
List<ThrInvWarehouseEntity> warehouseList = new ArrayList<>();
for (UdiwmsWarehouseDetail response : responseList) { for (UdiwmsWarehouseDetail response : responseList) {
ThrDeptEntity thrDeptEntity = new ThrDeptEntity(); ThrDeptEntity thrDeptEntity = new ThrDeptEntity();
thrDeptEntity.setPid(0); thrDeptEntity.setPid(0);
@ -148,23 +149,21 @@ public class ThrDeptServiceImpl extends ServiceImpl<ThrDeptDao, ThrDeptEntity> i
thrDeptEntity.setUpdateTime(new Date()); thrDeptEntity.setUpdateTime(new Date());
list.add(thrDeptEntity); list.add(thrDeptEntity);
List<UdiwmsWarehouseDetail.SubWarehouse> subWarehouseList = response.getSubWarehouses();
if (CollUtil.isNotEmpty(subWarehouseList)) {
for (UdiwmsWarehouseDetail.SubWarehouse subWarehouse : subWarehouseList) {
ThrInvWarehouseEntity thrInvWarehouseEntity = new ThrInvWarehouseEntity(); ThrInvWarehouseEntity thrInvWarehouseEntity = new ThrInvWarehouseEntity();
thrInvWarehouseEntity.setCode(subWarehouse.getCode()); thrInvWarehouseEntity.setCode(response.getCode());
thrInvWarehouseEntity.setName(subWarehouse.getName()); thrInvWarehouseEntity.setName(response.getName());
thrInvWarehouseEntity.setRemark(subWarehouse.getRemark()); thrInvWarehouseEntity.setRemark(response.getRemark());
thrInvWarehouseEntity.setThirdSysFk(thirdSysFk); thrInvWarehouseEntity.setThirdSysFk(thirdSysFk);
thrInvWarehouseEntity.setParentId(response.getCode()); thrInvWarehouseEntity.setParentId(response.getCode());
thrInvWarehouseEntity.setId(IdUtil.getSnowflake(6, 1).nextId() + ""); thrInvWarehouseEntity.setId(IdUtil.getSnowflake(6, 1).nextId() + "");
thrInvWarehouseEntity.setUpdateTime(new Date()); thrInvWarehouseEntity.setUpdateTime(new Date());
thrInvWarehouseDao.insertThrInvWarehouse(thrInvWarehouseEntity); warehouseList.add(thrInvWarehouseEntity);
}
}
} }
//插入数据 //插入数据
thrDeptDao.insertInvWarehouses(list); thrDeptDao.insertInvWarehouses(list);
thrInvWarehouseDao.insertThrInvWarehouses(warehouseList);
if (list.size() >= limit) { if (list.size() >= limit) {
page++; page++;
} else { } else {

Loading…
Cancel
Save