|
|
@@ -40,6 +40,7 @@ import org.springframework.stereotype.Service;
|
|
|
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
import com.uas.report.SpecialProperties;
|
|
|
+import com.uas.report.SystemProperties;
|
|
|
import com.uas.report.core.exception.ReportException;
|
|
|
import com.uas.report.jasperreports.engine.export.CustomJRXlsExporter;
|
|
|
import com.uas.report.model.Master;
|
|
|
@@ -82,6 +83,9 @@ public class PrintServiceImpl implements PrintService {
|
|
|
|
|
|
@Autowired
|
|
|
private FileService fileService;
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private SystemProperties systemProperties;
|
|
|
|
|
|
@Autowired
|
|
|
private SpecialProperties specialProperties;
|
|
|
@@ -198,7 +202,7 @@ public class PrintServiceImpl implements PrintService {
|
|
|
data = outputStream.toByteArray();
|
|
|
outputStream.close();
|
|
|
}
|
|
|
- // 报表预览,则直接输出pdf,并且需要进行分页
|
|
|
+ // 报表预览,则直接输出pdf,并且也许需要分页
|
|
|
else {
|
|
|
logger.info("preview fillReport...");
|
|
|
jasperPrint = JasperFillManager.fillReport(jasperFilePath, parameters, connection);
|
|
|
@@ -632,14 +636,14 @@ public class PrintServiceImpl implements PrintService {
|
|
|
platform = Platform.PC;
|
|
|
}
|
|
|
|
|
|
- // 报表支持的最大数据库记录数目
|
|
|
+ // 支持打印的最大记录行数
|
|
|
int maxRecordSize = 0;
|
|
|
switch (platform) {
|
|
|
case PC:
|
|
|
- maxRecordSize = 100000;
|
|
|
+ maxRecordSize = systemProperties.getMaxRecordSizePc();
|
|
|
break;
|
|
|
case PHONE:
|
|
|
- maxRecordSize = 10000;
|
|
|
+ maxRecordSize = systemProperties.getMaxRecordSizePhone();
|
|
|
break;
|
|
|
}
|
|
|
|