mirror of
http://git.pig4cloud.com/pig/pigx.git
synced 2026-11-08 20:49:00 +08:00
🐛 修复 GenDsConfController 下载数据源文档时no such field 错误
This commit is contained in:
1 parent
68e97384e6
commit
9fa8b13b6e
1 file changed
+1
-2
+1
-2
@@ -18,7 +18,6 @@ package com.pig4cloud.pigx.codegen.controller;
|
||||
|
||||
import cn.hutool.core.io.IoUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.hutool.http.ContentType;
|
||||
import cn.smallbun.screw.boot.config.Screw;
|
||||
import cn.smallbun.screw.boot.properties.ScrewProperties;
|
||||
import com.baomidou.dynamic.datasource.DynamicRoutingDataSource;
|
||||
@@ -146,7 +145,7 @@ public class GenDsConfController {
|
||||
byte[] data = screw.documentGeneration(dsName, dataSource, screwProperties).toByteArray();
|
||||
response.reset();
|
||||
response.addHeader(HttpHeaders.CONTENT_LENGTH, String.valueOf(data.length));
|
||||
response.setContentType(ContentType.OCTET_STREAM.getValue());
|
||||
response.setContentType("application/octet-stream");
|
||||
IoUtil.write(response.getOutputStream(), Boolean.FALSE, data);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user