mirror of
https://gitee.com/dromara/RuoYi-Vue-Plus.git
synced 2026-09-21 10:35:57 +08:00
1、注册开关直接返回boolean值
This commit is contained in:
parent
4eafc54483
commit
e8f81b2d54
@ -2,6 +2,7 @@ package com.ruoyi.web.controller;
|
||||
|
||||
import cn.dev33.satoken.annotation.SaIgnore;
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.convert.Convert;
|
||||
import com.ruoyi.common.core.domain.R;
|
||||
import com.ruoyi.common.core.domain.model.EmailLoginBody;
|
||||
import com.ruoyi.common.core.domain.model.LoginBody;
|
||||
@ -27,9 +28,7 @@ import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.net.URL;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 认证
|
||||
@ -159,11 +158,8 @@ public class AuthController {
|
||||
*/
|
||||
@SaIgnore
|
||||
@GetMapping("/registerEnabled")
|
||||
public R<Map<String, Object>> registerEnabled() {
|
||||
Map<String, Object> ajax = new HashMap<>();
|
||||
String register = configService.selectConfigByKey("sys.account.registerUser");
|
||||
ajax.put("register", register);
|
||||
return R.ok(ajax);
|
||||
public R<Boolean> registerEnabled() {
|
||||
return R.ok(Convert.toBool(configService.selectConfigByKey("sys.account.registerUser")));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user