新增 yudao-spring-boot-starter-banner
组件,用于项目启动时打印开发文档、接口文档等
This commit is contained in:
parent
e5f343a3e9
commit
69a3a835a5
@ -79,6 +79,11 @@
|
|||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- 业务组件 -->
|
<!-- 业务组件 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>cn.iocoder.boot</groupId>
|
||||||
|
<artifactId>yudao-spring-boot-starter-banner</artifactId>
|
||||||
|
<version>${revision}</version>
|
||||||
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.iocoder.boot</groupId>
|
<groupId>cn.iocoder.boot</groupId>
|
||||||
<artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId>
|
<artifactId>yudao-spring-boot-starter-biz-operatelog</artifactId>
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
<modules>
|
<modules>
|
||||||
<module>yudao-common</module>
|
<module>yudao-common</module>
|
||||||
|
<module>yudao-spring-boot-starter-banner</module>
|
||||||
<module>yudao-spring-boot-starter-mybatis</module>
|
<module>yudao-spring-boot-starter-mybatis</module>
|
||||||
<module>yudao-spring-boot-starter-redis</module>
|
<module>yudao-spring-boot-starter-redis</module>
|
||||||
<module>yudao-spring-boot-starter-web</module>
|
<module>yudao-spring-boot-starter-web</module>
|
||||||
|
30
yudao-framework/yudao-spring-boot-starter-banner/pom.xml
Normal file
30
yudao-framework/yudao-spring-boot-starter-banner/pom.xml
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
|
<parent>
|
||||||
|
<artifactId>yudao-framework</artifactId>
|
||||||
|
<groupId>cn.iocoder.boot</groupId>
|
||||||
|
<version>${revision}</version>
|
||||||
|
</parent>
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<artifactId>yudao-spring-boot-starter-banner</artifactId>
|
||||||
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
|
<name>${project.artifactId}</name>
|
||||||
|
<description>Banner 用于在 console 控制台,打印开发文档、接口文档等</description>
|
||||||
|
<url>https://github.com/YunaiV/ruoyi-vue-pro</url>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>cn.iocoder.boot</groupId>
|
||||||
|
<artifactId>yudao-common</artifactId>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-starter</artifactId>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
|
||||||
|
</project>
|
@ -0,0 +1,20 @@
|
|||||||
|
package cn.iocoder.yudao.framework.banner.config;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.banner.core.BannerApplicationRunner;
|
||||||
|
import org.springframework.context.annotation.Bean;
|
||||||
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Banner 的自动配置类
|
||||||
|
*
|
||||||
|
* @author 芋道源码
|
||||||
|
*/
|
||||||
|
@Configuration
|
||||||
|
public class YudaoBannerAutoConfiguration {
|
||||||
|
|
||||||
|
@Bean
|
||||||
|
public BannerApplicationRunner bannerApplicationRunner() {
|
||||||
|
return new BannerApplicationRunner();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -1,19 +1,19 @@
|
|||||||
package cn.iocoder.yudao.server.framework.tip.core;
|
package cn.iocoder.yudao.framework.banner.core;
|
||||||
|
|
||||||
import cn.hutool.core.thread.ThreadUtil;
|
import cn.hutool.core.thread.ThreadUtil;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.springframework.boot.ApplicationArguments;
|
import org.springframework.boot.ApplicationArguments;
|
||||||
import org.springframework.boot.ApplicationRunner;
|
import org.springframework.boot.ApplicationRunner;
|
||||||
import org.springframework.stereotype.Component;
|
|
||||||
|
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 项目启动成功后,提供文档相关的地址
|
* 项目启动成功后,提供文档相关的地址
|
||||||
|
*
|
||||||
|
* @author 芋道源码
|
||||||
*/
|
*/
|
||||||
@Component
|
|
||||||
@Slf4j
|
@Slf4j
|
||||||
public class TipApplicationRunner implements ApplicationRunner {
|
public class BannerApplicationRunner implements ApplicationRunner {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void run(ApplicationArguments args) throws Exception {
|
public void run(ApplicationArguments args) throws Exception {
|
@ -0,0 +1,6 @@
|
|||||||
|
/**
|
||||||
|
* Banner 用于在 console 控制台,打印开发文档、接口文档等
|
||||||
|
*
|
||||||
|
* @author 芋道源码
|
||||||
|
*/
|
||||||
|
package cn.iocoder.yudao.framework.banner;
|
@ -0,0 +1,2 @@
|
|||||||
|
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
|
||||||
|
cn.iocoder.yudao.framework.banner.config.YudaoBannerAutoConfiguration
|
@ -13,7 +13,7 @@ import org.springframework.context.annotation.Configuration;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 数据全新啊的自动配置类
|
* 数据权限的自动配置类
|
||||||
*
|
*
|
||||||
* @author 芋道源码
|
* @author 芋道源码
|
||||||
*/
|
*/
|
||||||
|
@ -63,6 +63,10 @@
|
|||||||
<artifactId>spring-boot-configuration-processor</artifactId>
|
<artifactId>spring-boot-configuration-processor</artifactId>
|
||||||
<optional>true</optional>
|
<optional>true</optional>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>cn.iocoder.boot</groupId>
|
||||||
|
<artifactId>yudao-spring-boot-starter-banner</artifactId>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
<!-- 服务保障相关 -->
|
<!-- 服务保障相关 -->
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -1,4 +0,0 @@
|
|||||||
/**
|
|
||||||
* 目的:项目启动成功后,提供文档相关的地址
|
|
||||||
*/
|
|
||||||
package cn.iocoder.yudao.server.framework.tip;
|
|
Loading…
Reference in New Issue
Block a user