springboot的jsonp怎么设置
1 回答
冉冉说
TA贡献1877条经验 获得超1个赞
package com.zkn.learnspringboot.config;
import org.springframework.web.bind.annotation.ControllerAdvice;
import org.springframework.web.servlet.mvc.method.annotation.AbstractJsonpResponseBodyAdvice;
/**
* Created by wb-zhangkenan on 2016/12/1.
*/
@ControllerAdvice(basePackages = "com.zkn.learnspringboot.web.controller")
public class JsonpAdvice extends AbstractJsonpResponseBodyAdvice{
public JsonpAdvice() {
super("callback","jsonp");
}
}
- 1 回答
- 0 关注
- 1153 浏览
添加回答
举报
0/150
提交
取消