From c7bc8e415fa6cf5e3dec7059e900008b2b2bc1df Mon Sep 17 00:00:00 2001
From: 疯狂的狮子li <15040126243@163.com>
Date: 星期五, 14 二月 2020 13:27:09 +0800
Subject: [PATCH] 集成 Lombok + MybatisPlus 3.3.0

---
 ruoyi/src/main/resources/application-dev.yml                          |   26 ++
 ruoyi/src/main/resources/application-test.yml                         |   22 ++
 ruoyi/src/main/java/com/ruoyi/RuoYiApplication.java                   |   11 -
 ruoyi/src/main/resources/application-prop.yml                         |   22 ++
 ruoyi/pom.xml                                                         |   41 ++++-
 ruoyi/src/main/resources/application.yml                              |   69 +++++---
 ruoyi/src/main/java/com/ruoyi/framework/config/MybatisPlusConfig.java |   38 ++++
 ruoyi/src/main/java/com/ruoyi/framework/config/MyBatisConfig.java     |  210 +++++++++++++-------------
 ruoyi/src/main/resources/banner.txt                                   |   24 --
 9 files changed, 284 insertions(+), 179 deletions(-)

diff --git a/ruoyi/pom.xml b/ruoyi/pom.xml
index b317c40..a3ebef2 100644
--- a/ruoyi/pom.xml
+++ b/ruoyi/pom.xml
@@ -35,6 +35,8 @@
 		<poi.version>3.17</poi.version>
 		<oshi.version>3.9.1</oshi.version>
 		<velocity.version>1.7</velocity.version>
+		<mybatis-plus.version>3.3.0</mybatis-plus.version>
+		<hutool.version>5.0.6</hutool.version>
 	</properties>
 
 	<dependencies>
@@ -50,7 +52,6 @@
                     <groupId>org.springframework.boot</groupId>
                 </exclusion>
             </exclusions>
-             -->
 		</dependency>
 
 		<!-- SpringBoot 娴嬭瘯 -->
@@ -104,18 +105,24 @@
 			<scope>runtime</scope>
 		</dependency>
 
-		<!-- SpringBoot闆嗘垚mybatis妗嗘灦 -->
-		<dependency>
-			<groupId>org.mybatis.spring.boot</groupId>
-			<artifactId>mybatis-spring-boot-starter</artifactId>
-			<version>${mybatis.spring.boot.starter.version}</version>
-		</dependency>
+<!--		&lt;!&ndash; SpringBoot闆嗘垚mybatis妗嗘灦 &ndash;&gt;-->
+<!--		<dependency>-->
+<!--			<groupId>org.mybatis.spring.boot</groupId>-->
+<!--			<artifactId>mybatis-spring-boot-starter</artifactId>-->
+<!--			<version>${mybatis.spring.boot.starter.version}</version>-->
+<!--		</dependency>-->
 		
 		<!-- pagehelper 鍒嗛〉鎻掍欢 -->
 		<dependency>
 			<groupId>com.github.pagehelper</groupId>
 			<artifactId>pagehelper-spring-boot-starter</artifactId>
 			<version>${pagehelper.spring.boot.starter.version}</version>
+			<exclusions>
+				<exclusion>
+					<groupId>org.mybatis</groupId>
+					<artifactId>mybatis</artifactId>
+				</exclusion>
+			</exclusions>
 		</dependency>
 
 		<!--闃块噷鏁版嵁搴撹繛鎺ユ睜 -->
@@ -238,7 +245,25 @@
 			<artifactId>velocity</artifactId>
 			<version>${velocity.version}</version>
 		</dependency>
-
+		<dependency>
+			<groupId>com.baomidou</groupId>
+			<artifactId>mybatis-plus-boot-starter</artifactId>
+			<version>${mybatis-plus.version}</version>
+		</dependency>
+		<dependency>
+			<groupId>com.baomidou</groupId>
+			<artifactId>mybatis-plus-extension</artifactId>
+			<version>${mybatis-plus.version}</version>
+		</dependency>
+		<dependency>
+			<groupId>cn.hutool</groupId>
+			<artifactId>hutool-all</artifactId>
+			<version>${hutool.version}</version>
+		</dependency>
+		<dependency>
+			<groupId>org.projectlombok</groupId>
+			<artifactId>lombok</artifactId>
+		</dependency>
 	</dependencies>
 
 	<build>
diff --git a/ruoyi/src/main/java/com/ruoyi/RuoYiApplication.java b/ruoyi/src/main/java/com/ruoyi/RuoYiApplication.java
index 32eb6f1..32ae45f 100644
--- a/ruoyi/src/main/java/com/ruoyi/RuoYiApplication.java
+++ b/ruoyi/src/main/java/com/ruoyi/RuoYiApplication.java
@@ -16,15 +16,6 @@
     {
         // System.setProperty("spring.devtools.restart.enabled", "false");
         SpringApplication.run(RuoYiApplication.class, args);
-        System.out.println("(鈾モ棤鈥库棤)锞夛緸  鑻ヤ緷鍚姩鎴愬姛   醿�(麓凇`醿�)锞�  \n" +
-                " .-------.       ____     __        \n" +
-                " |  _ _   \\      \\   \\   /  /    \n" +
-                " | ( ' )  |       \\  _. /  '       \n" +
-                " |(_ o _) /        _( )_ .'         \n" +
-                " | (_,_).' __  ___(_ o _)'          \n" +
-                " |  |\\ \\  |  ||   |(_,_)'         \n" +
-                " |  | \\ `'   /|   `-'  /           \n" +
-                " |  |  \\    /  \\      /           \n" +
-                " ''-'   `'-'    `-..-'              ");
+        System.out.println("(鈾モ棤鈥库棤)锞夛緸  鑻ヤ緷鍚姩鎴愬姛   醿�(麓凇`醿�)锞�");
     }
 }
diff --git a/ruoyi/src/main/java/com/ruoyi/framework/config/MyBatisConfig.java b/ruoyi/src/main/java/com/ruoyi/framework/config/MyBatisConfig.java
index 7ecfd9d..fc9841f 100644
--- a/ruoyi/src/main/java/com/ruoyi/framework/config/MyBatisConfig.java
+++ b/ruoyi/src/main/java/com/ruoyi/framework/config/MyBatisConfig.java
@@ -1,105 +1,105 @@
-package com.ruoyi.framework.config;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.List;
-import javax.sql.DataSource;
-import org.apache.ibatis.io.VFS;
-import org.apache.ibatis.session.SqlSessionFactory;
-import org.mybatis.spring.SqlSessionFactoryBean;
-import org.mybatis.spring.boot.autoconfigure.SpringBootVFS;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.context.annotation.Bean;
-import org.springframework.context.annotation.Configuration;
-import org.springframework.core.env.Environment;
-import org.springframework.core.io.Resource;
-import org.springframework.core.io.support.PathMatchingResourcePatternResolver;
-import org.springframework.core.io.support.ResourcePatternResolver;
-import org.springframework.core.type.classreading.CachingMetadataReaderFactory;
-import org.springframework.core.type.classreading.MetadataReader;
-import org.springframework.core.type.classreading.MetadataReaderFactory;
-import org.springframework.util.ClassUtils;
-
-/**
- * Mybatis鏀寔*鍖归厤鎵弿鍖�
- * 
- * @author ruoyi
- */
-@Configuration
-public class MyBatisConfig
-{
-    @Autowired
-    private Environment env;
-
-    static final String DEFAULT_RESOURCE_PATTERN = "**/*.class";
-
-    public static String setTypeAliasesPackage(String typeAliasesPackage)
-    {
-        ResourcePatternResolver resolver = (ResourcePatternResolver) new PathMatchingResourcePatternResolver();
-        MetadataReaderFactory metadataReaderFactory = new CachingMetadataReaderFactory(resolver);
-        List<String> allResult = new ArrayList<String>();
-        try
-        {
-            for (String aliasesPackage : typeAliasesPackage.split(","))
-            {
-                List<String> result = new ArrayList<String>();
-                aliasesPackage = ResourcePatternResolver.CLASSPATH_ALL_URL_PREFIX
-                        + ClassUtils.convertClassNameToResourcePath(aliasesPackage.trim()) + "/" + DEFAULT_RESOURCE_PATTERN;
-                Resource[] resources = resolver.getResources(aliasesPackage);
-                if (resources != null && resources.length > 0)
-                {
-                    MetadataReader metadataReader = null;
-                    for (Resource resource : resources)
-                    {
-                        if (resource.isReadable())
-                        {
-                            metadataReader = metadataReaderFactory.getMetadataReader(resource);
-                            try
-                            {
-                                result.add(Class.forName(metadataReader.getClassMetadata().getClassName()).getPackage().getName());
-                            }
-                            catch (ClassNotFoundException e)
-                            {
-                                e.printStackTrace();
-                            }
-                        }
-                    }
-                }
-                if (result.size() > 0)
-                {
-                    HashSet<String> hashResult = new HashSet<String>(result);
-                    allResult.addAll(hashResult);
-                }
-            }
-            if (allResult.size() > 0)
-            {
-                typeAliasesPackage = String.join(",", (String[]) allResult.toArray(new String[0]));
-            }
-            else
-            {
-                throw new RuntimeException("mybatis typeAliasesPackage 璺緞鎵弿閿欒,鍙傛暟typeAliasesPackage:" + typeAliasesPackage + "鏈壘鍒颁换浣曞寘");
-            }
-        }
-        catch (IOException e)
-        {
-            e.printStackTrace();
-        }
-        return typeAliasesPackage;
-    }
-
-    @Bean
-    public SqlSessionFactory sqlSessionFactory(DataSource dataSource) throws Exception
-    {
-        String typeAliasesPackage = env.getProperty("mybatis.typeAliasesPackage");
-        String mapperLocations = env.getProperty("mybatis.mapperLocations");
-        typeAliasesPackage = setTypeAliasesPackage(typeAliasesPackage);
-        VFS.addImplClass(SpringBootVFS.class);
-
-        final SqlSessionFactoryBean sessionFactory = new SqlSessionFactoryBean();
-        sessionFactory.setDataSource(dataSource);
-        sessionFactory.setTypeAliasesPackage(typeAliasesPackage);
-        sessionFactory.setMapperLocations(new PathMatchingResourcePatternResolver().getResources(mapperLocations));
-        return sessionFactory.getObject();
-    }
-}
\ No newline at end of file
+//package com.ruoyi.framework.config;
+//
+//import java.io.IOException;
+//import java.util.ArrayList;
+//import java.util.HashSet;
+//import java.util.List;
+//import javax.sql.DataSource;
+//import org.apache.ibatis.io.VFS;
+//import org.apache.ibatis.session.SqlSessionFactory;
+//import org.mybatis.spring.SqlSessionFactoryBean;
+//import org.mybatis.spring.boot.autoconfigure.SpringBootVFS;
+//import org.springframework.beans.factory.annotation.Autowired;
+//import org.springframework.context.annotation.Bean;
+//import org.springframework.context.annotation.Configuration;
+//import org.springframework.core.env.Environment;
+//import org.springframework.core.io.Resource;
+//import org.springframework.core.io.support.PathMatchingResourcePatternResolver;
+//import org.springframework.core.io.support.ResourcePatternResolver;
+//import org.springframework.core.type.classreading.CachingMetadataReaderFactory;
+//import org.springframework.core.type.classreading.MetadataReader;
+//import org.springframework.core.type.classreading.MetadataReaderFactory;
+//import org.springframework.util.ClassUtils;
+//
+///**
+// * Mybatis鏀寔*鍖归厤鎵弿鍖�
+// *
+// * @author ruoyi
+// */
+//@Configuration
+//public class MyBatisConfig
+//{
+//    @Autowired
+//    private Environment env;
+//
+//    static final String DEFAULT_RESOURCE_PATTERN = "**/*.class";
+//
+//    public static String setTypeAliasesPackage(String typeAliasesPackage)
+//    {
+//        ResourcePatternResolver resolver = (ResourcePatternResolver) new PathMatchingResourcePatternResolver();
+//        MetadataReaderFactory metadataReaderFactory = new CachingMetadataReaderFactory(resolver);
+//        List<String> allResult = new ArrayList<String>();
+//        try
+//        {
+//            for (String aliasesPackage : typeAliasesPackage.split(","))
+//            {
+//                List<String> result = new ArrayList<String>();
+//                aliasesPackage = ResourcePatternResolver.CLASSPATH_ALL_URL_PREFIX
+//                        + ClassUtils.convertClassNameToResourcePath(aliasesPackage.trim()) + "/" + DEFAULT_RESOURCE_PATTERN;
+//                Resource[] resources = resolver.getResources(aliasesPackage);
+//                if (resources != null && resources.length > 0)
+//                {
+//                    MetadataReader metadataReader = null;
+//                    for (Resource resource : resources)
+//                    {
+//                        if (resource.isReadable())
+//                        {
+//                            metadataReader = metadataReaderFactory.getMetadataReader(resource);
+//                            try
+//                            {
+//                                result.add(Class.forName(metadataReader.getClassMetadata().getClassName()).getPackage().getName());
+//                            }
+//                            catch (ClassNotFoundException e)
+//                            {
+//                                e.printStackTrace();
+//                            }
+//                        }
+//                    }
+//                }
+//                if (result.size() > 0)
+//                {
+//                    HashSet<String> hashResult = new HashSet<String>(result);
+//                    allResult.addAll(hashResult);
+//                }
+//            }
+//            if (allResult.size() > 0)
+//            {
+//                typeAliasesPackage = String.join(",", (String[]) allResult.toArray(new String[0]));
+//            }
+//            else
+//            {
+//                throw new RuntimeException("mybatis typeAliasesPackage 璺緞鎵弿閿欒,鍙傛暟typeAliasesPackage:" + typeAliasesPackage + "鏈壘鍒颁换浣曞寘");
+//            }
+//        }
+//        catch (IOException e)
+//        {
+//            e.printStackTrace();
+//        }
+//        return typeAliasesPackage;
+//    }
+//
+//    @Bean
+//    public SqlSessionFactory sqlSessionFactory(DataSource dataSource) throws Exception
+//    {
+//        String typeAliasesPackage = env.getProperty("mybatis.typeAliasesPackage");
+//        String mapperLocations = env.getProperty("mybatis.mapperLocations");
+//        typeAliasesPackage = setTypeAliasesPackage(typeAliasesPackage);
+//        VFS.addImplClass(SpringBootVFS.class);
+//
+//        final SqlSessionFactoryBean sessionFactory = new SqlSessionFactoryBean();
+//        sessionFactory.setDataSource(dataSource);
+//        sessionFactory.setTypeAliasesPackage(typeAliasesPackage);
+//        sessionFactory.setMapperLocations(new PathMatchingResourcePatternResolver().getResources(mapperLocations));
+//        return sessionFactory.getObject();
+//    }
+//}
\ No newline at end of file
diff --git a/ruoyi/src/main/java/com/ruoyi/framework/config/MybatisPlusConfig.java b/ruoyi/src/main/java/com/ruoyi/framework/config/MybatisPlusConfig.java
new file mode 100644
index 0000000..5c56edd
--- /dev/null
+++ b/ruoyi/src/main/java/com/ruoyi/framework/config/MybatisPlusConfig.java
@@ -0,0 +1,38 @@
+package com.ruoyi.framework.config;
+
+import com.baomidou.mybatisplus.extension.plugins.OptimisticLockerInterceptor;
+import com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor;
+import com.baomidou.mybatisplus.extension.plugins.SqlExplainInterceptor;
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.Configuration;
+import org.springframework.transaction.annotation.EnableTransactionManagement;
+
+@EnableTransactionManagement(proxyTargetClass = true)
+@Configuration
+public class MybatisPlusConfig {
+
+	/**
+	 * 鍒嗛〉鎻掍欢锛岃嚜鍔ㄨ瘑鍒暟鎹簱绫诲瀷
+	 */
+	@Bean
+	public PaginationInterceptor paginationInterceptor() {
+		return new PaginationInterceptor();
+	}
+
+	/**
+	 * 涔愯閿佹彃浠�
+	 */
+	@Bean
+	public OptimisticLockerInterceptor optimisticLockerInterceptor() {
+		return new OptimisticLockerInterceptor();
+	}
+
+	/**
+	 * 濡傛灉鏄鍏ㄨ〃鐨勫垹闄ゆ垨鏇存柊鎿嶄綔锛屽氨浼氱粓姝㈣鎿嶄綔
+	 */
+	@Bean
+	public SqlExplainInterceptor sqlExplainInterceptor() {
+		return new SqlExplainInterceptor();
+	}
+
+}
diff --git a/ruoyi/src/main/resources/application-druid.yml b/ruoyi/src/main/resources/application-dev.yml
similarity index 70%
copy from ruoyi/src/main/resources/application-druid.yml
copy to ruoyi/src/main/resources/application-dev.yml
index 13e1a5c..29bed64 100644
--- a/ruoyi/src/main/resources/application-druid.yml
+++ b/ruoyi/src/main/resources/application-dev.yml
@@ -6,9 +6,9 @@
         druid:
             # 涓诲簱鏁版嵁婧�
             master:
-                url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
+                url: jdbc:mysql://192.168.0.222:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
                 username: root
-                password: password
+                password: root
             # 浠庡簱鏁版嵁婧�
             slave:
                 # 浠庢暟鎹簮寮�鍏�/榛樿鍏抽棴
@@ -54,4 +54,24 @@
                     merge-sql: true
                 wall:
                     config:
-                        multi-statement-allow: true
\ No newline at end of file
+                        multi-statement-allow: true
+    # redis 閰嶇疆
+    redis:
+        # 鍦板潃
+        host: 192.168.0.222
+        # 绔彛锛岄粯璁や负6379
+        port: 6379
+        # 瀵嗙爜
+        password:
+        # 杩炴帴瓒呮椂鏃堕棿
+        timeout: 10s
+        lettuce:
+            pool:
+                # 杩炴帴姹犱腑鐨勬渶灏忕┖闂茶繛鎺�
+                min-idle: 0
+                # 杩炴帴姹犱腑鐨勬渶澶х┖闂茶繛鎺�
+                max-idle: 8
+                # 杩炴帴姹犵殑鏈�澶ф暟鎹簱杩炴帴鏁�
+                max-active: 8
+                # #杩炴帴姹犳渶澶ч樆濉炵瓑寰呮椂闂达紙浣跨敤璐熷�艰〃绀烘病鏈夐檺鍒讹級
+                max-wait: -1ms
\ No newline at end of file
diff --git a/ruoyi/src/main/resources/application-druid.yml b/ruoyi/src/main/resources/application-prop.yml
similarity index 78%
rename from ruoyi/src/main/resources/application-druid.yml
rename to ruoyi/src/main/resources/application-prop.yml
index 13e1a5c..cc840f9 100644
--- a/ruoyi/src/main/resources/application-druid.yml
+++ b/ruoyi/src/main/resources/application-prop.yml
@@ -54,4 +54,24 @@
                     merge-sql: true
                 wall:
                     config:
-                        multi-statement-allow: true
\ No newline at end of file
+                        multi-statement-allow: true
+    # redis 閰嶇疆
+    redis:
+        # 鍦板潃
+        host: localhost
+        # 绔彛锛岄粯璁や负6379
+        port: 6379
+        # 瀵嗙爜
+        password:
+        # 杩炴帴瓒呮椂鏃堕棿
+        timeout: 10s
+        lettuce:
+            pool:
+                # 杩炴帴姹犱腑鐨勬渶灏忕┖闂茶繛鎺�
+                min-idle: 0
+                # 杩炴帴姹犱腑鐨勬渶澶х┖闂茶繛鎺�
+                max-idle: 8
+                # 杩炴帴姹犵殑鏈�澶ф暟鎹簱杩炴帴鏁�
+                max-active: 8
+                # #杩炴帴姹犳渶澶ч樆濉炵瓑寰呮椂闂达紙浣跨敤璐熷�艰〃绀烘病鏈夐檺鍒讹級
+                max-wait: -1ms
\ No newline at end of file
diff --git a/ruoyi/src/main/resources/application-druid.yml b/ruoyi/src/main/resources/application-test.yml
similarity index 78%
copy from ruoyi/src/main/resources/application-druid.yml
copy to ruoyi/src/main/resources/application-test.yml
index 13e1a5c..cc840f9 100644
--- a/ruoyi/src/main/resources/application-druid.yml
+++ b/ruoyi/src/main/resources/application-test.yml
@@ -54,4 +54,24 @@
                     merge-sql: true
                 wall:
                     config:
-                        multi-statement-allow: true
\ No newline at end of file
+                        multi-statement-allow: true
+    # redis 閰嶇疆
+    redis:
+        # 鍦板潃
+        host: localhost
+        # 绔彛锛岄粯璁や负6379
+        port: 6379
+        # 瀵嗙爜
+        password:
+        # 杩炴帴瓒呮椂鏃堕棿
+        timeout: 10s
+        lettuce:
+            pool:
+                # 杩炴帴姹犱腑鐨勬渶灏忕┖闂茶繛鎺�
+                min-idle: 0
+                # 杩炴帴姹犱腑鐨勬渶澶х┖闂茶繛鎺�
+                max-idle: 8
+                # 杩炴帴姹犵殑鏈�澶ф暟鎹簱杩炴帴鏁�
+                max-active: 8
+                # #杩炴帴姹犳渶澶ч樆濉炵瓑寰呮椂闂达紙浣跨敤璐熷�艰〃绀烘病鏈夐檺鍒讹級
+                max-wait: -1ms
\ No newline at end of file
diff --git a/ruoyi/src/main/resources/application.yml b/ruoyi/src/main/resources/application.yml
index 4ced552..fbabd99 100644
--- a/ruoyi/src/main/resources/application.yml
+++ b/ruoyi/src/main/resources/application.yml
@@ -42,7 +42,7 @@
     # 鍥介檯鍖栬祫婧愭枃浠惰矾寰�
     basename: i18n/messages
   profiles: 
-    active: druid
+    active: dev
   # 鏂囦欢涓婁紶
   servlet:
      multipart:
@@ -55,26 +55,6 @@
     restart:
       # 鐑儴缃插紑鍏�
       enabled: true
-  # redis 閰嶇疆
-  redis:
-    # 鍦板潃
-    host: localhost
-    # 绔彛锛岄粯璁や负6379
-    port: 6379
-    # 瀵嗙爜
-    password: 
-    # 杩炴帴瓒呮椂鏃堕棿
-    timeout: 10s
-    lettuce:
-      pool:
-        # 杩炴帴姹犱腑鐨勬渶灏忕┖闂茶繛鎺�
-        min-idle: 0
-        # 杩炴帴姹犱腑鐨勬渶澶х┖闂茶繛鎺�
-        max-idle: 8
-        # 杩炴帴姹犵殑鏈�澶ф暟鎹簱杩炴帴鏁�
-        max-active: 8
-        # #杩炴帴姹犳渶澶ч樆濉炵瓑寰呮椂闂达紙浣跨敤璐熷�艰〃绀烘病鏈夐檺鍒讹級
-        max-wait: -1ms
 
 # token閰嶇疆
 token:
@@ -85,14 +65,47 @@
     # 浠ょ墝鏈夋晥鏈燂紙榛樿30鍒嗛挓锛�
     expireTime: 30
   
+## MyBatis閰嶇疆
+#mybatis:
+#    # 鎼滅储鎸囧畾鍖呭埆鍚�
+#    typeAliasesPackage: com.ruoyi.project.**.domain
+#    # 閰嶇疆mapper鐨勬壂鎻忥紝鎵惧埌鎵�鏈夌殑mapper.xml鏄犲皠鏂囦欢
+#    mapperLocations: classpath*:mybatis/**/*Mapper.xml
+#    # 鍔犺浇鍏ㄥ眬鐨勯厤缃枃浠�
+#    configLocation: classpath:mybatis/mybatis-config.xml
+
 # MyBatis閰嶇疆
-mybatis:
-    # 鎼滅储鎸囧畾鍖呭埆鍚�
-    typeAliasesPackage: com.ruoyi.project.**.domain
-    # 閰嶇疆mapper鐨勬壂鎻忥紝鎵惧埌鎵�鏈夌殑mapper.xml鏄犲皠鏂囦欢
-    mapperLocations: classpath*:mybatis/**/*Mapper.xml
-    # 鍔犺浇鍏ㄥ眬鐨勯厤缃枃浠�
-    configLocation: classpath:mybatis/mybatis-config.xml
+mybatis-plus:
+  mapper-locations: classpath*:mybatis/**/*Mapper.xml
+  #瀹炰綋鎵弿锛屽涓猵ackage鐢ㄩ�楀彿鎴栬�呭垎鍙峰垎闅�
+  typeAliasesPackage: com.ruoyi.project
+  configuration:
+    map-underscore-to-camel-case: true
+    cache-enabled: true
+  global-config:
+    banner: false
+    #鍒锋柊mapper 璋冭瘯绁炲櫒
+    refresh: true
+    db-config:
+      #涓婚敭绫诲瀷  0:"鏁版嵁搴揑D鑷", 1:"鐢ㄦ埛杈撳叆ID",2:"鍏ㄥ眬鍞竴ID (鏁板瓧绫诲瀷鍞竴ID)", 3:"鍏ㄥ眬鍞竴ID UUID";
+      id-type: auto
+      #瀛楁绛栫暐 0:"蹇界暐鍒ゆ柇",1:"闈� NULL 鍒ゆ柇"),2:"闈炵┖鍒ゆ柇"
+      field-strategy: not_empty
+      #椹煎嘲涓嬪垝绾胯浆鎹�
+      db-column-underline: true
+      #鏁版嵁搴撳ぇ鍐欎笅鍒掔嚎杞崲
+      #capital-mode: true
+      #搴忓垪鎺ュ彛瀹炵幇绫婚厤缃�
+      #key-generator: com.baomidou.springboot.xxx
+      #閫昏緫鍒犻櫎閰嶇疆
+      logic-delete-value: 1
+      logic-not-delete-value: 0
+      #鏁版嵁搴撶被鍨�
+      db-type: mysql
+    #鑷畾涔塖QL娉ㄥ叆鍣�
+    #sql-injector: com.baomidou.mybatisplus.mapper.LogicSqlInjector
+    #鑷畾涔夊~鍏呯瓥鐣ユ帴鍙e疄鐜�
+    #meta-object-handler: com.baomidou.springboot.xxx
 
 # PageHelper鍒嗛〉鎻掍欢
 pagehelper: 
diff --git a/ruoyi/src/main/resources/banner.txt b/ruoyi/src/main/resources/banner.txt
index 0931cb8..fee1ce3 100644
--- a/ruoyi/src/main/resources/banner.txt
+++ b/ruoyi/src/main/resources/banner.txt
@@ -1,24 +1,2 @@
 Application Version: ${ruoyi.version}
-Spring Boot Version: ${spring-boot.version}
-////////////////////////////////////////////////////////////////////
-//                          _ooOoo_                               //
-//                         o8888888o                              //
-//                         88" . "88                              //
-//                         (| ^_^ |)                              //
-//                         O\  =  /O                              //
-//                      ____/`---'\____                           //
-//                    .'  \\|     |//  `.                         //
-//                   /  \\|||  :  |||//  \                        //
-//                  /  _||||| -:- |||||-  \                       //
-//                  |   | \\\  -  /// |   |                       //
-//                  | \_|  ''\---/''  |   |                       //
-//                  \  .-\__  `-`  ___/-. /                       //
-//                ___`. .'  /--.--\  `. . ___                     //
-//              ."" '<  `.___\_<|>_/___.'  >'"".                  //
-//            | | :  `- \`.;`\ _ /`;.`/ - ` : | |                 //
-//            \  \ `-.   \_ __\ /__ _/   .-` /  /                 //
-//      ========`-.____`-.___\_____/___.-`____.-'========         //
-//                           `=---='                              //
-//      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^        //
-//             浣涚淇濅綉       姘镐笉瀹曟満      姘告棤BUG               //
-////////////////////////////////////////////////////////////////////
\ No newline at end of file
+Spring Boot Version: ${spring-boot.version}
\ No newline at end of file

--
Gitblit v1.9.3