Commit 288afaa9 authored by hongguangwu's avatar hongguangwu

MVP1.6.3 特殊导入

parent 93e3b20b
......@@ -853,24 +853,26 @@ public class TSalaryStandardOriginalServiceImpl extends ServiceImpl<TSalaryStand
detail = detailMap.get(column.getKey());
if (detail != null && Common.isNotNull(detail.getModelName())) {
value = column.getValue();
try {
if ("REDUCE".equals(detail.getFlag())) {
value = String.valueOf(new BigDecimal(value).negate());
if (Common.isNotNull(value)) {
try {
if ("REDUCE".equals(detail.getFlag())) {
value = String.valueOf(new BigDecimal(value).negate());
}
oldValue = newRowMap.get(detail.getModelName());
if (Common.isNotNull(oldValue)) {
value = String.valueOf(new BigDecimal(oldValue).add(new BigDecimal(value))
.setScale(SalaryConstants.PLACES, BigDecimal.ROUND_HALF_UP));
}
} catch (NumberFormatException e) {
return R.failed("数据行第 " + i + " 行,第 " + (Integer.parseInt(column.getKey()) + 1) + " 列 不是金额,不可以进行加减计算!");
}
oldValue = newRowMap.get(detail.getModelName());
if (oldValue != null) {
value = String.valueOf(new BigDecimal(oldValue).add(new BigDecimal(value))
.setScale(SalaryConstants.PLACES, BigDecimal.ROUND_HALF_UP));
newRowMap.put(detail.getModelName(), value);
if (SalaryConstants.ID_NUMBER.equals(detail.getModelName())) {
check.setIdCard(value);
}
if (SalaryConstants.EMP_NAME2.equals(detail.getModelName())) {
check.setName(value);
}
} catch (NumberFormatException e) {
return R.failed("数据行第 " + i + " 行,第 " + (Integer.parseInt(column.getKey()) + 1) + " 列 不是金额,不可以进行加减计算!");
}
newRowMap.put(detail.getModelName(), value);
if (SalaryConstants.ID_NUMBER.equals(detail.getModelName())) {
check.setIdCard(value);
}
if (SalaryConstants.EMP_NAME2.equals(detail.getModelName())) {
check.setName(value);
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment