forked from rzdata/demo-empty
Compare commits
No commits in common. "d09638dd96ae312aeae4a5ee1effe60451c529b9" and "59e430eacb1aba4d74412ccf6c2a078f02de0095" have entirely different histories.
d09638dd96
...
59e430eacb
@ -1,18 +0,0 @@
|
|||||||
package net.rzdata.demo.config;
|
|
||||||
|
|
||||||
import lombok.Getter;
|
|
||||||
import lombok.Setter;
|
|
||||||
import lombok.ToString;
|
|
||||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
|
||||||
import org.springframework.context.annotation.Configuration;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 全局配置
|
|
||||||
*/
|
|
||||||
@Configuration
|
|
||||||
@ConfigurationProperties(prefix = "demo")
|
|
||||||
@Getter
|
|
||||||
@Setter
|
|
||||||
@ToString
|
|
||||||
public class DemoConfig {
|
|
||||||
}
|
|
@ -1,25 +0,0 @@
|
|||||||
package net.rzdata.demo.config;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor;
|
|
||||||
import com.baomidou.mybatisplus.extension.plugins.inner.PaginationInnerInterceptor;
|
|
||||||
import org.springframework.context.annotation.Bean;
|
|
||||||
import org.springframework.context.annotation.Configuration;
|
|
||||||
|
|
||||||
@Configuration
|
|
||||||
public class MybatisPlusConfig {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 添加插件
|
|
||||||
*/
|
|
||||||
@Bean
|
|
||||||
public MybatisPlusInterceptor mybatisPlusInterceptor() {
|
|
||||||
MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor();
|
|
||||||
// 分页插件
|
|
||||||
interceptor.addInnerInterceptor(paginationInnerInterceptor());
|
|
||||||
return interceptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
public PaginationInnerInterceptor paginationInnerInterceptor() {
|
|
||||||
return new PaginationInnerInterceptor();
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,3 +1 @@
|
|||||||
net.rzdata.demo.exception.GlobalExceptionHandler
|
net.rzdata.demo.exception.GlobalExceptionHandler
|
||||||
net.rzdata.demo.config.DemoConfig
|
|
||||||
net.rzdata.demo.config.MybatisPlusConfig
|
|
||||||
|
@ -54,10 +54,6 @@
|
|||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
<artifactId>spring-boot-starter-data-redis</artifactId>
|
<artifactId>spring-boot-starter-data-redis</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
|
||||||
<groupId>org.springdoc</groupId>
|
|
||||||
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.mysql</groupId>
|
<groupId>com.mysql</groupId>
|
||||||
<artifactId>mysql-connector-j</artifactId>
|
<artifactId>mysql-connector-j</artifactId>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user