同步问题,单据撤回问题

master
anthonywj 2 years ago
parent 42441fa449
commit e499c9db45

@ -244,7 +244,6 @@ public class SpsSyncDownloadController {
orderEntity.setId(null);
purOrderService.insert(orderEntity);
if (CollUtil.isNotEmpty(spsSyncBusOrderResponse.getPurOrderDetailEntities())) {
List<PurOrderDetailEntity> purOrderDetailEntities = spsSyncBusOrderResponse.getPurOrderDetailEntities();
for (PurOrderDetailEntity purOrderDetailEntity : purOrderDetailEntities) {
PurOrderDetailEntity codeTempEntity = new PurOrderDetailEntity();
@ -278,5 +277,11 @@ public class SpsSyncDownloadController {
}
//接收中继服务、UDI管理系统上传单据类型
//接收中继服务、UDI管理系统上传基础信息
}

@ -203,7 +203,7 @@ public class IdcServiceImpl implements IdcService {
}
}
private void fetchFailFile(String host) {
Map<String,Object> map = new HashMap<String,Object>();
map.put("sql", "select * from idc_file where createTime<date_sub(now(),interval 30 minute) order by createTime");
@ -579,7 +579,7 @@ public class IdcServiceImpl implements IdcService {
Map<String, Object> whereParams = new HashMap<String, Object>();
whereParams.put("sqlWhere", params.get("sqlWhere"));
String dataWhere = params.get("dataWhere")!=null ? params.get("dataWhere").toString() : "";
Map<String, Object> map = new HashMap<String, Object>();
String where = DBAUtils.convertWhere(column, whereParams, dataWhere);
@ -811,7 +811,7 @@ public class IdcServiceImpl implements IdcService {
private boolean analyToDB(String host, String tableName, String uniqueColumn, String
filePathColumn, List<Map<String, Object>> list, boolean isUpload) {
String tName = DBAUtils.tableRealName(tableName);
String sql = "replace " + tName + "(";
String del = "delete from " + tName + " where ";
@ -1034,27 +1034,27 @@ public class IdcServiceImpl implements IdcService {
int total = 0;
if (result!=null&&result.isSuccessful()&&MediaType.parse("application/force-download").equals(result.body().contentType())) {
try (InputStream inputStream = result.body().byteStream()) {
FileOutputStream outputStream = new FileOutputStream(filePath + filePathSlash + imagePath+fileName);
byte b[] = new byte[1024];
int len = 0;
while ((len = inputStream.read(b)) != -1) {
total += len;
outputStream.write(b, 0, len);
}
outputStream.flush();
outputStream.close();
if(!(total>0)) {
new File(filePath + filePathSlash + imagePath+fileName).delete();
executeSql("delete from idc_file where filePath='"+fileName+"'");
}
FileOutputStream outputStream = new FileOutputStream(filePath + filePathSlash + imagePath+fileName);
byte b[] = new byte[1024];
int len = 0;
while ((len = inputStream.read(b)) != -1) {
total += len;
outputStream.write(b, 0, len);
}
outputStream.flush();
outputStream.close();
if(!(total>0)) {
new File(filePath + filePathSlash + imagePath+fileName).delete();
executeSql("delete from idc_file where filePath='"+fileName+"'");
}
} catch (Exception e) {
@ -1252,7 +1252,7 @@ public class IdcServiceImpl implements IdcService {
}
private void executeSql(String sql) {
try {
jdbcTemplate.execute(sql);
@ -1262,5 +1262,5 @@ public class IdcServiceImpl implements IdcService {
}
}
}
}

@ -412,7 +412,7 @@ public class IoOrderServiceImpl implements IoOrderService {
orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST);
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_SUCCESS);
orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW);
orderEntity.setUpdateTime(new Date());
update(orderEntity);
return true;

Loading…
Cancel
Save