唐耀东
2022-08-22 83187f51aef5692354bd88ed166a748e32cc78fb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package com.ruoyi.web.controller.system;
 
import com.ruoyi.common.config.RuoYiConfig;
import com.ruoyi.common.utils.StringUtils;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
 
/**
 * 首页
 *
 * @author Lion Li
 */
@Api(value = "首页控制器", tags = {"首页管理"})
@RequiredArgsConstructor(onConstructor_ = @Autowired)
@RestController
public class SysIndexController {
 
    /**
     * 系统基础配置
     */
    private final RuoYiConfig ruoyiConfig;
 
    /**
     * 访问首页,提示语
     */
    @ApiOperation("访问首页,提示语")
    @GetMapping("/")
    public String index() {
        return StringUtils.format("欢迎使用{}后台管理框架,当前版本:v{},请通过前端地址访问。", ruoyiConfig.getName(), ruoyiConfig.getVersion());
    }
}