mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/per-boe/java-servers.git
synced 2025-12-11 11:56:50 +08:00
测试
This commit is contained in:
@@ -26,6 +26,7 @@ import com.xboe.constants.Constants;
|
|||||||
import com.xboe.core.IAuthorizationToken;
|
import com.xboe.core.IAuthorizationToken;
|
||||||
import com.xboe.core.JsonResponse;
|
import com.xboe.core.JsonResponse;
|
||||||
import com.xboe.core.api.ApiBaseController;
|
import com.xboe.core.api.ApiBaseController;
|
||||||
|
import com.xboe.core.event.IEventDataSender;
|
||||||
import com.xboe.system.logs.entity.SysLogLogin;
|
import com.xboe.system.logs.entity.SysLogLogin;
|
||||||
import com.xboe.system.logs.service.ISysLogLoginService;
|
import com.xboe.system.logs.service.ISysLogLoginService;
|
||||||
import com.xboe.system.user.entity.SysManager;
|
import com.xboe.system.user.entity.SysManager;
|
||||||
@@ -62,6 +63,9 @@ public class SysLoginApi extends ApiBaseController {
|
|||||||
@Autowired
|
@Autowired
|
||||||
StringRedisTemplate redisTemplate;
|
StringRedisTemplate redisTemplate;
|
||||||
|
|
||||||
|
@Autowired(required = false)
|
||||||
|
private IEventDataSender eventSender;
|
||||||
|
|
||||||
@GetMapping("/captcha")
|
@GetMapping("/captcha")
|
||||||
public JsonResponse<Map<String, String>> captcha() {
|
public JsonResponse<Map<String, String>> captcha() {
|
||||||
SpecCaptcha specCaptcha = new SpecCaptcha(130, 48, 5);
|
SpecCaptcha specCaptcha = new SpecCaptcha(130, 48, 5);
|
||||||
@@ -77,6 +81,24 @@ public class SysLoginApi extends ApiBaseController {
|
|||||||
return success(map);
|
return success(map);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GetMapping("/login/send")
|
||||||
|
public JsonResponse<Map<String, String>> sendMessage() {
|
||||||
|
Map<String, String> rs=new HashMap<String, String>();
|
||||||
|
|
||||||
|
if(eventSender!=null) {
|
||||||
|
try {
|
||||||
|
eventSender.send("测试消息","keykey", "all测试消息","1231231", "1", "aaaa", "asdqadqw","wqwrqre","");
|
||||||
|
}catch(Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
return error("发送失败"+e.getMessage());
|
||||||
|
}
|
||||||
|
}else {
|
||||||
|
//log.error();
|
||||||
|
return error("未配置事件消息发送的实现");
|
||||||
|
}
|
||||||
|
return success(rs);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据用户名和密码登录
|
* 根据用户名和密码登录
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user