publish 2.0.0.rc6

This commit is contained in:
曾文豪
2024-07-11 16:03:07 +08:00
parent 59926aa2f4
commit e709050ba3
72 changed files with 33 additions and 32 deletions

View File

@@ -40,11 +40,11 @@ public class DemoWebConfigurer implements TieshengWebConfigurer {
public void redirect(TokenBean bean, String to, String extra, HttpServletResponse response) {
// 默认跳转到mobile
to = StrUtil.emptyToDefault(to, "mobile");
to = StrUtil.emptyToDefault(to, "static/mobile");
bean.setEnvironmentType(to);
if (Objects.equals(bean.getEnvironmentType(), "mobile")) {
globalConfig.redirect("mobile", "/?token=" + bean.toToken(), response);
if (Objects.equals(bean.getEnvironmentType(), "static/mobile")) {
globalConfig.redirect("static/mobile", "/?token=" + bean.toToken(), response);
}
}

View File

@@ -57,8 +57,8 @@ public class TestController {
@RequestMapping("/index")
@TokenIgnore
public ApiResp<String> index(TokenBean tokenBean) {
return ApiResp.respOK("hello world");
public void index(HttpServletResponse response) {
globalConfig.redirect("mobile", "/test", response);
}
@RequestMapping("/redirect")