|
|
@@ -2,14 +2,19 @@ package cn.reghao.bnt.web;
|
|
|
|
|
|
import org.springframework.boot.SpringApplication;
|
|
|
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
|
|
+import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
|
|
import org.springframework.boot.autoconfigure.domain.EntityScan;
|
|
|
import org.springframework.context.annotation.ComponentScan;
|
|
|
+import org.springframework.context.annotation.FilterType;
|
|
|
import org.springframework.data.jpa.repository.config.EnableJpaRepositories;
|
|
|
|
|
|
@SpringBootApplication
|
|
|
@EnableJpaRepositories
|
|
|
@EntityScan({"cn.reghao.bnt.web"})
|
|
|
-@ComponentScan({"cn.reghao.bnt.web", "cn.reghao.bnt.common"})
|
|
|
+@ComponentScan(basePackages = {"cn.reghao.bnt.web", "cn.reghao.bnt.common"}
|
|
|
+ ,excludeFilters = @ComponentScan.Filter(type = FilterType.REGEX, pattern = {"cn.reghao.bnt.web.admin.*"})
|
|
|
+)
|
|
|
+//@ConditionalOnProperty()
|
|
|
public class WebApplication {
|
|
|
public static void main(String[] args) {
|
|
|
SpringApplication.run(WebApplication.class, args);
|