记得上下班打卡 | git大法好,push需谨慎

Commit 8d2f5b62 authored by zhengfuxin's avatar zhengfuxin

修改配置文件、

parent d8d216d2
package com.liquidnet.service.config;
import com.liquidnet.common.web.config.WebMvcConfig;
import com.liquidnet.common.web.filter.GlobalAuthorityInterceptor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
@Configuration
public class SmileWebMvcConfig extends WebMvcConfig {
@Autowired
public GlobalAuthorityInterceptor globalAuthorityInterceptor;
@Override
protected void addInterceptors(InterceptorRegistry registry) {
registry.addInterceptor(this.globalAuthorityInterceptor).addPathPatterns("/**");
super.addInterceptors(registry);
}
}
...@@ -50,7 +50,10 @@ public class SmileUserController { ...@@ -50,7 +50,10 @@ public class SmileUserController {
@ApiOperation("获得学校") @ApiOperation("获得学校")
public ResponseDto<List<SmileSchoolVo>> getSchool() { public ResponseDto<List<SmileSchoolVo>> getSchool() {
String userId = CurrentUtil.getCurrentUid(); String userId = CurrentUtil.getCurrentUid();
List<SmileSchoolVo> list= (List<SmileSchoolVo>) redisUtil.get(SmileRedisConst.SMILE_SCHOOL.concat(userId)); List<SmileSchoolVo> list=null;
if(redisUtil.hasKey(SmileRedisConst.SMILE_SCHOOL.concat(userId))){
list= (List<SmileSchoolVo>) redisUtil.get(SmileRedisConst.SMILE_SCHOOL.concat(userId));
}
return ResponseDto.success(list); return ResponseDto.success(list);
} }
@GetMapping("getPerformance") @GetMapping("getPerformance")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment