Commit bbaa685d by 杨林龙

优化导出报表模板

1 parent 8d6ed97e
...@@ -54,7 +54,7 @@ public class OfflineController { ...@@ -54,7 +54,7 @@ public class OfflineController {
List<OfflineExport> offlineList = offlineService.exportOfflineList(offlineSearch); List<OfflineExport> offlineList = offlineService.exportOfflineList(offlineSearch);
// 将文件写入内存流 然后上传到文件服务器 返回文件服务器的地址给前端 前端执行下载 // 将文件写入内存流 然后上传到文件服务器 返回文件服务器的地址给前端 前端执行下载
ByteArrayOutputStream outputStream = new ByteArrayOutputStream(); ByteArrayOutputStream outputStream = new ByteArrayOutputStream();
EasyExcelUtils.writeExcel(outputStream, offlineList, fileName, JudgmentExport.class); EasyExcelUtils.writeExcel(outputStream, offlineList, fileName, OfflineExport.class);
FileUploadServerData uploadServerData = FileUploadUtil.uploadToFileSystem(fileName, outputStream.toByteArray(), FileConstants.EXCEL_TYPE_XLSX); FileUploadServerData uploadServerData = FileUploadUtil.uploadToFileSystem(fileName, outputStream.toByteArray(), FileConstants.EXCEL_TYPE_XLSX);
return R.ok().data(uploadServerData.getSecureUrl()); return R.ok().data(uploadServerData.getSecureUrl());
} }
......
...@@ -48,7 +48,7 @@ public class DeviceActiveExprot { ...@@ -48,7 +48,7 @@ public class DeviceActiveExprot {
/** /**
* 设备型号 字符串类型 * 设备型号 字符串类型
**/ **/
@ExcelProperty("设备型号") @ExcelProperty("设备类型")
private String deviceTypeStr; private String deviceTypeStr;
/** /**
...@@ -59,7 +59,6 @@ public class DeviceActiveExprot { ...@@ -59,7 +59,6 @@ public class DeviceActiveExprot {
/** /**
* 是否有源 1 有源 0无源 字符串类型 * 是否有源 1 有源 0无源 字符串类型
*/ */
@ExcelProperty("设备类型")
private String sourceStr; private String sourceStr;
/** /**
......
...@@ -51,7 +51,7 @@ public class FinalPositioningExport { ...@@ -51,7 +51,7 @@ public class FinalPositioningExport {
/** /**
* 设备类型字符串 1 有线 0无线 * 设备类型字符串 1 有线 0无线
*/ */
@ExcelProperty("设备类型") @ExcelProperty("设备型号")
private String deviceTypeStr; private String deviceTypeStr;
/** /**
...@@ -62,7 +62,6 @@ public class FinalPositioningExport { ...@@ -62,7 +62,6 @@ public class FinalPositioningExport {
/** /**
* 是否有源 1 有源 0无源 * 是否有源 1 有源 0无源
*/ */
@ExcelProperty("设备型号")
private String sourceStr; private String sourceStr;
/** /**
...@@ -86,34 +85,34 @@ public class FinalPositioningExport { ...@@ -86,34 +85,34 @@ public class FinalPositioningExport {
/** /**
* 最后定位时间 * 最后定位时间
*/ */
@ExcelProperty("最后定位时间")
private String lastPoiTime; private String lastPoiTime;
/** /**
* 最后定位类型 * 最后定位类型
*/ */
@ExcelProperty("最后定位类型")
private String poiType; private String poiType;
/** /**
* 最后定位位置 * 最后定位位置
*/ */
@ExcelProperty("最后定位地址")
private String lastPoiAddress; private String lastPoiAddress;
/** /**
* Gps经度 * Gps经度
**/ **/
@ExcelProperty("经度")
private String gpsLng; private String gpsLng;
/** /**
* Gps纬度 * Gps纬度
**/ **/
@ExcelProperty("纬度")
private String gpsLat; private String gpsLat;
/** /**
* Gps最后定位地址 * Gps最后定位地址
**/ **/
@ExcelProperty("最后Gps定位地址")
private String lastGpsAddress; private String lastGpsAddress;
/** /**
......
...@@ -27,18 +27,18 @@ public class OfflineExport { ...@@ -27,18 +27,18 @@ public class OfflineExport {
private String ownerName; private String ownerName;
/** /**
* 设备号
*/
@ExcelProperty("设备号")
private String sn;
/**
* 车架号 * 车架号
*/ */
@ExcelProperty("车架号") @ExcelProperty("车架号")
private String vin; private String vin;
/** /**
* 设备号
*/
@ExcelProperty("设备号")
private String sn;
/**
* 设备类型 8:Gps 1:OBD * 设备类型 8:Gps 1:OBD
*/ */
private Integer deviceType; private Integer deviceType;
...@@ -46,7 +46,6 @@ public class OfflineExport { ...@@ -46,7 +46,6 @@ public class OfflineExport {
/** /**
* 设备类型 字符串 * 设备类型 字符串
*/ */
@ExcelProperty("设备型号")
private String deviceTypeStr; private String deviceTypeStr;
/** /**
...@@ -73,18 +72,6 @@ public class OfflineExport { ...@@ -73,18 +72,6 @@ public class OfflineExport {
private String activeDate; private String activeDate;
/** /**
* 最后Gps定位时间
*/
@ExcelProperty(" 最后Gps定位时间")
private String lastGpsTime;
/**
* 最后基站定位时间
*/
@ExcelProperty(" 最后基站定位时间")
private String lastBsTime;
/**
* GPS经度 * GPS经度
**/ **/
private String gpsAlarmLng; private String gpsAlarmLng;
...@@ -95,9 +82,15 @@ public class OfflineExport { ...@@ -95,9 +82,15 @@ public class OfflineExport {
private String gpsAlarmLat; private String gpsAlarmLat;
/** /**
* 最后Gps定位时间
*/
@ExcelProperty(" 最后Gps时间")
private String lastGpsTime;
/**
* GPS报警位置 * GPS报警位置
*/ */
@ExcelProperty("最后GPS报警位置") @ExcelProperty("最后GPS定位地址")
private String gpsAlarmAddress; private String gpsAlarmAddress;
/** /**
...@@ -111,8 +104,14 @@ public class OfflineExport { ...@@ -111,8 +104,14 @@ public class OfflineExport {
private String bsAlarmLat; private String bsAlarmLat;
/** /**
* 最后基站定位时间
*/
@ExcelProperty(" 最后基站时间")
private String lastBsTime;
/**
* BS报警位置 * BS报警位置
*/ */
@ExcelProperty("最后基站报警位置") @ExcelProperty("最后基站定位地址")
private String bsAlarmAddress; private String bsAlarmAddress;
} }
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!