Commit 9c9ee3e4 authored by neo's avatar neo

[Bugfix] fixed bb fromart exception and use munual val

parent 887a9b34
......@@ -116,10 +116,17 @@ public class BB extends FunctionBase implements FreeRefFunction {
} else {
String evalStr = OperandResolver.coerceValueToString(eval);
logger.debug("[BB_debug] eval other cell value {}", evalStr);
cellValue = new BigDecimal(evalStr).setScale(4,
BigDecimal.ROUND_HALF_DOWN);
if (!dss.isEmpty())
cellValue = cellValue.add(dss.get(0).getAmount());
try {
cellValue = new BigDecimal(evalStr).setScale(4,
BigDecimal.ROUND_HALF_DOWN);
if (!dss.isEmpty())
cellValue = cellValue.add(dss.get(0).getAmount());
} catch (Exception e) {
if (!dss.isEmpty())
cellValue = dss.get(0).getAmount();
else throw e;
}
}
nullCellDto.extractFromGroup(bo, formulaContext.getPeriod(), formulaContext.getYear(), cellTemplateData);
......
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