Beetl 模板引擎 3.15.7 发布,Java 模板引擎
完成需求I7KEB8,默认运算采用精度运算。 Beetl默认情况下当遇到数字以h结尾的时候,认为是BigDecimal类型,随后运算使用高精度运算。 var a= 3434.33h*233334; 新版本增加配置,不允许显示的使用h表示高精度类型 BIGDECIMAL=true 则默认所有数字都翻译成BigDecimal Script script = groupTemplate.getScript("return 5/3;",loader); script.execute(); if(script.isSuccess()){ Object value = script.getResult().get("return"); Assert.assertTrue(value instanceof BigDecimal); Assert.assertEquals(value,new BigDecimal(5).divide(new BigDecimal(3),ALU.scale, ALU.round )); }else{ Assert.fail(); } Mav...