环境说明
springboot2.2.6(不同版本的解决问题方式可能不一样,我也尝试多次才可以)
解决方案
response.setHeader("content-Type", "application/vnd.ms-excel;charset=utf-8");
response.setHeader("Content-Disposition", "attachment;fileName="+ fileName +";filename*=utf-8''"+URLEncoder.encode(fileName,"UTF-8"));