publish 2.0.0.rc38
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
package com.tiesheng.demo.config;
|
||||
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.hutool.log.LogFactory;
|
||||
import com.tiesheng.login.pojos.RequestUserInfo;
|
||||
import com.tiesheng.login.pojos.dao.CorePlatformUnique;
|
||||
import com.tiesheng.login.service.TsLoginConfigurer;
|
||||
@@ -19,13 +21,22 @@ public class DemoWebConfigurer implements TieshengWebConfigurer, TsLoginConfigur
|
||||
@Autowired
|
||||
GlobalConfig globalConfig;
|
||||
|
||||
public static void main(String[] args) {
|
||||
RequestUserInfo info = new RequestUserInfo();
|
||||
info.setId("1");
|
||||
info.setName("name");
|
||||
info.setData(info);
|
||||
String jsonStr = JSONUtil.toJsonStr(info);
|
||||
LogFactory.get().info(jsonStr);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public RequestUserInfo getCurrentUserName(TokenBean tokenBean) {
|
||||
RequestUserInfo info = new RequestUserInfo();
|
||||
if (Objects.equals(tokenBean.getId(), "1")) {
|
||||
return info;
|
||||
}
|
||||
info.setId(tokenBean.getId());
|
||||
info.setName(tokenBean.getExtra());
|
||||
info.setData(info);
|
||||
return info;
|
||||
}
|
||||
|
||||
|
||||
@@ -3,7 +3,6 @@ package com.tiesheng.demo.controller;
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.date.TimeInterval;
|
||||
import cn.hutool.log.LogFactory;
|
||||
import cn.hutool.poi.excel.ExcelUtil;
|
||||
import com.alibaba.excel.EasyExcel;
|
||||
import com.alibaba.excel.context.AnalysisContext;
|
||||
import com.alibaba.excel.read.listener.ReadListener;
|
||||
@@ -195,18 +194,4 @@ public class TestController {
|
||||
return ApiResp.respOK("");
|
||||
}
|
||||
|
||||
@RequestMapping("poiTool")
|
||||
@TokenIgnore
|
||||
public ApiResp<String> poiTool() {
|
||||
TimeInterval timeInterval = new TimeInterval();
|
||||
|
||||
FileUploadPath file = FileUploadPath.file("/upload/test.xlsx");
|
||||
|
||||
ExcelUtil.getReader(new File(file.getAbsolutePath())).read();
|
||||
|
||||
System.out.println("timeInterval: " + timeInterval.interval());
|
||||
|
||||
return ApiResp.respOK("");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user