From a53a3b3119659d6ec28b458dcefd46f4ec49d55c Mon Sep 17 00:00:00 2001 From: 疯狂的狮子li <15040126243@163.com> Date: 星期五, 17 七月 2020 16:43:47 +0800 Subject: [PATCH] Merge branch 'master' of https://gitee.com/y_project/RuoYi-Vue --- ruoyi/src/main/java/com/ruoyi/project/tool/gen/util/GenUtils.java | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ruoyi/src/main/java/com/ruoyi/project/tool/gen/util/GenUtils.java b/ruoyi/src/main/java/com/ruoyi/project/tool/gen/util/GenUtils.java index 4068643..f1f9243 100644 --- a/ruoyi/src/main/java/com/ruoyi/project/tool/gen/util/GenUtils.java +++ b/ruoyi/src/main/java/com/ruoyi/project/tool/gen/util/GenUtils.java @@ -58,11 +58,11 @@ { column.setHtmlType(GenConstants.HTML_INPUT); - // 濡傛灉鏄诞鐐瑰瀷 + // 濡傛灉鏄诞鐐瑰瀷 缁熶竴鐢˙igDecimal String[] str = StringUtils.split(StringUtils.substringBetween(column.getColumnType(), "(", ")"), ","); if (str != null && str.length == 2 && Integer.parseInt(str[1]) > 0) { - column.setJavaType(GenConstants.TYPE_DOUBLE); + column.setJavaType(GenConstants.TYPE_BIGDECIMAL); } // 濡傛灉鏄暣褰� else if (str != null && str.length == 1 && Integer.parseInt(str[0]) <= 10) @@ -147,10 +147,10 @@ */ public static String getBusinessName(String tableName) { - int lastIndex = tableName.lastIndexOf("_"); + int lastIndex = tableName.indexOf("_"); int nameLength = tableName.length(); String businessName = StringUtils.substring(tableName, lastIndex + 1, nameLength); - return businessName; + return StringUtils.toCamelCase(businessName); } /** -- Gitblit v1.9.3