|
@@ -100,7 +100,7 @@ public class CostIncomeGroupServiceImpl extends ServiceImpl<CostIncomeGroupMappe
|
|
|
.like(StrUtil.isNotBlank(productCode), CostIncomeGroup::getProductCode, productCode));
|
|
|
List<CostIncomeGroup> records = pages.getRecords();
|
|
|
List<CostIncomeGroupBeforeVO> costIncomeGroupBeforeVOList = BeanUtil.convertList(records, CostIncomeGroupBeforeVO.class);
|
|
|
- if (CollectionUtils.isEmpty(costIncomeGroupBeforeVOList)){
|
|
|
+ if (CollectionUtils.isEmpty(costIncomeGroupBeforeVOList)) {
|
|
|
PageUtils pageUtils = new PageUtils(pages);
|
|
|
pageUtils.setList(null);
|
|
|
pageUtils.setTotalAmount(new BigDecimal(0.0000));
|
|
@@ -187,7 +187,7 @@ public class CostIncomeGroupServiceImpl extends ServiceImpl<CostIncomeGroupMappe
|
|
|
throw new CostException(500, "文件上传异常");
|
|
|
}
|
|
|
// 记录文件上传记录
|
|
|
- CostIncomeFile costIncomeFile = costIncomeFileService.saveCostIncomeFile(list, user, file, hospId, incomeErrorMessageList, uploadFile, fileType,year,month);
|
|
|
+ CostIncomeFile costIncomeFile = costIncomeFileService.saveCostIncomeFile(list, user, file, hospId, incomeErrorMessageList, uploadFile, fileType, year, month);
|
|
|
Long id = costIncomeFile.getId();
|
|
|
costIncomeGroupArrayList.forEach(i -> {
|
|
|
// 设置文件Id
|
|
@@ -195,8 +195,8 @@ public class CostIncomeGroupServiceImpl extends ServiceImpl<CostIncomeGroupMappe
|
|
|
});
|
|
|
if (CollectionUtils.isEmpty(incomeErrorMessageList)) {
|
|
|
this.saveBatch(costIncomeGroupArrayList);
|
|
|
- return Result.build(200,"数据导入成功",null);
|
|
|
- }else {
|
|
|
+ return Result.build(200, "数据导入成功", null);
|
|
|
+ } else {
|
|
|
return Result.build(200, "数据未成功导入", null);
|
|
|
}
|
|
|
}
|
|
@@ -329,10 +329,10 @@ public class CostIncomeGroupServiceImpl extends ServiceImpl<CostIncomeGroupMappe
|
|
|
String openDepartmentCode = data.get(3).toString().trim();
|
|
|
String startDepartmentName = data.get(4).toString().trim();
|
|
|
String startDepartmentCode = data.get(5).toString().trim();
|
|
|
- if (StrUtil.isBlank(openDepartmentCode) && StrUtil.isBlank(openDepartmentName) && StrUtil.isBlank(startDepartmentCode) && StrUtil.isBlank(startDepartmentName)){
|
|
|
+ if (StrUtil.isBlank(openDepartmentCode) && StrUtil.isBlank(openDepartmentName) && StrUtil.isBlank(startDepartmentCode) && StrUtil.isBlank(startDepartmentName)) {
|
|
|
continue;
|
|
|
}
|
|
|
- BigDecimal beforeMoney = BigDecimal.valueOf(Double.parseDouble(("0".equals(data.get(15).toString()) || StrUtil.isBlank(data.get(15).toString())) ?"0.00":data.get(15).toString()));
|
|
|
+ BigDecimal beforeMoney = BigDecimal.valueOf(Double.parseDouble(("0".equals(data.get(15).toString()) || StrUtil.isBlank(data.get(15).toString())) ? "0.00" : data.get(15).toString()));
|
|
|
boolean checkNull = StrUtil.isNotBlank(data.get(15).toString());
|
|
|
boolean checkOne = "0".equals(data.get(15).toString());
|
|
|
// TODO 为0的时候这一行是否可以输入空的
|
|
@@ -350,7 +350,7 @@ public class CostIncomeGroupServiceImpl extends ServiceImpl<CostIncomeGroupMappe
|
|
|
}
|
|
|
// 检验收入成本项目数据是否存在
|
|
|
Product product = productMap.get(productCode.trim() + productName.trim());
|
|
|
- Department department = departmentMap.get(openDepartmentCode.trim()+openDepartmentName.trim());
|
|
|
+ Department department = departmentMap.get(openDepartmentCode.trim() + openDepartmentName.trim());
|
|
|
Department department1 = departmentMap.get(startDepartmentCode.trim() + startDepartmentName.trim());
|
|
|
if (StrUtil.isNotBlank(productCode) && StrUtil.isNotBlank(productName)) {
|
|
|
if (Objects.isNull(product)) {
|
|
@@ -446,11 +446,11 @@ public class CostIncomeGroupServiceImpl extends ServiceImpl<CostIncomeGroupMappe
|
|
|
costIncomeGroup.setStartResponsibilityCode(null);
|
|
|
costIncomeGroup.setStartResponsibilityName(null);
|
|
|
}
|
|
|
- costIncomeGroup.setDoctorNumber(StrUtil.isBlank(data.get(6).toString())?null:Long.parseLong(data.get(6).toString())).setDoctorName(data.get(7).toString())
|
|
|
- .setPatientId(StrUtil.isBlank(data.get(8).toString())?null:Long.parseLong(data.get(8).toString())).setOutpatientId(StrUtil.isBlank(data.get(9).toString())?null:Long.parseLong(data.get(9).toString()))
|
|
|
+ costIncomeGroup.setDoctorNumber(StrUtil.isBlank(data.get(6).toString()) ? null : Long.parseLong(data.get(6).toString())).setDoctorName(data.get(7).toString())
|
|
|
+ .setPatientId(StrUtil.isBlank(data.get(8).toString()) ? null : Long.parseLong(data.get(8).toString())).setOutpatientId(StrUtil.isBlank(data.get(9).toString()) ? null : Long.parseLong(data.get(9).toString()))
|
|
|
.setPatientName(data.get(10).toString()).setPatientFee(data.get(11).toString()).setReceiptFee(data.get(12).toString())
|
|
|
- .setTotalNumber(StrUtil.isBlank(data.get(13).toString())?null:Integer.parseInt(data.get(13).toString())).setUnit(data.get(14).toString())
|
|
|
- .setFeeDatetime(StrUtil.isBlank(data.get(16).toString())?null:DateUtils.StringToDate(data.get(16).toString(), DateStyleEnum.YYYY_MM_DD_HH_MM_SS));
|
|
|
+ .setTotalNumber(StrUtil.isBlank(data.get(13).toString()) ? null : Integer.parseInt(data.get(13).toString())).setUnit(data.get(14).toString())
|
|
|
+ .setFeeDatetime(StrUtil.isBlank(data.get(16).toString()) ? null : DateUtils.StringToDate(data.get(16).toString(), DateStyleEnum.YYYY_MM_DD_HH_MM_SS));
|
|
|
costIncomeGroup.setHospId(hospId);
|
|
|
costIncomeGroup.setCreateTime(System.currentTimeMillis());
|
|
|
costIncomeGroup.setDateYear(year);
|
|
@@ -464,6 +464,7 @@ public class CostIncomeGroupServiceImpl extends ServiceImpl<CostIncomeGroupMappe
|
|
|
|
|
|
/**
|
|
|
* 封装需要的数据
|
|
|
+ *
|
|
|
* @param hospId
|
|
|
* @param costIncomeGroup
|
|
|
* @param afterIncomegroup
|