Commit 6fb59e10 LN

修改导出csv乱码问题

1 个父辈 48a77011
......@@ -12,12 +12,13 @@ import java.io.Writer;
public class CNCsvView extends CsvView{
@Override
public String getMimeType() {
return "text/csv";
return "text/csv;charset=GB2312";
// return "text/csv";
}
@Override
public void doExport(Writer out) throws IOException, JspException {
out.write(new String(new byte[] { (byte) 0xEF, (byte) 0xBB,(byte) 0xBF }));
super.doExport(out);
}
// @Override
// public void doExport(Writer out) throws IOException, JspException {
// out.write(new String(new byte[] { (byte) 0xEF, (byte) 0xBB,(byte) 0xBF }));
// super.doExport(out);
// }
}
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!