update
This commit is contained in:
parent
78f7779e8d
commit
b6acd4bf59
|
|
@ -9,7 +9,7 @@ FN.use = org.beetl.sql.core.engine.UseFunction
|
|||
FN.globalUse = org.beetl.sql.core.engine.GlobalUseFunction
|
||||
FN.text = org.beetl.sql.core.engine.TextFunction
|
||||
FN.join = org.beetl.sql.ext.JoinFunction
|
||||
FN.isEmpty = org.beetl.sql.ext.EmptyExpressionFunction
|
||||
FN.isEmpty = org.beetl.sql.core.engine.EmptyExpressionFunction
|
||||
FN.isNotEmpty = org.beetl.sql.core.engine.NotEmptyExpressionFunction
|
||||
FN.db.testNull = org.beetl.sql.core.engine.TestNullFunction
|
||||
FN.db.dynamicSql = org.beetl.sql.core.engine.DynamicSqlFunction
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ FN.use = org.beetl.sql.core.engine.UseFunction
|
|||
FN.globalUse = org.beetl.sql.core.engine.GlobalUseFunction
|
||||
FN.text = org.beetl.sql.core.engine.TextFunction
|
||||
FN.join = org.beetl.sql.ext.JoinFunction
|
||||
FN.isEmpty = org.beetl.sql.ext.EmptyExpressionFunction
|
||||
FN.isEmpty = org.beetl.sql.core.engine.EmptyExpressionFunction
|
||||
FN.isNotEmpty = org.beetl.sql.core.engine.NotEmptyExpressionFunction
|
||||
FN.db.testNull = org.beetl.sql.core.engine.TestNullFunction
|
||||
FN.db.dynamicSql = org.beetl.sql.core.engine.DynamicSqlFunction
|
||||
|
|
|
|||
|
|
@ -18,15 +18,21 @@ package com.smallchill.core.beetl;
|
|||
import org.beetl.sql.core.InterceptorContext;
|
||||
import org.beetl.sql.ext.DebugInterceptor;
|
||||
|
||||
import com.smallchill.core.constant.Cst;
|
||||
import com.smallchill.core.toolbox.kit.DateKit;
|
||||
import com.smallchill.core.toolbox.kit.Prop;
|
||||
import com.smallchill.core.toolbox.kit.PropKit;
|
||||
|
||||
/**
|
||||
* 重写beetlsql输出的sql语句格式
|
||||
*/
|
||||
public class ReportInterceptor extends DebugInterceptor {
|
||||
|
||||
public static boolean productMode = !Cst.me().isDevMode();
|
||||
public static boolean productMode;
|
||||
|
||||
static {
|
||||
Prop prop = PropKit.use("config.properties");
|
||||
productMode = !prop.getBoolean("config.devMode", false);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void before(InterceptorContext ctx) {
|
||||
|
|
|
|||
|
|
@ -37,11 +37,7 @@ public class Convert {
|
|||
public static Object parse(Class<?> clazz, Object value) {
|
||||
try {
|
||||
if (clazz.isAssignableFrom(String.class)) {
|
||||
// ----2016-12-19---zhuangqian----防止beetlsql对空字符串不检测导致无法入库的问题----
|
||||
if (StrKit.isBlank(String.valueOf(value)))
|
||||
return " ";
|
||||
else
|
||||
return String.valueOf(value);
|
||||
return String.valueOf(value);
|
||||
}
|
||||
return clazz.cast(value);
|
||||
} catch (ClassCastException e) {
|
||||
|
|
@ -83,8 +79,6 @@ public class Convert {
|
|||
if (null == clazz || null == valueStr) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (StrKit.isBlank(valueStr)) return null;
|
||||
|
||||
BasicType basicType = null;
|
||||
try {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user