|
@@ -1,6 +1,10 @@
|
|
|
package com.xy.dto;
|
|
|
|
|
|
+import com.alibaba.excel.annotation.ExcelProperty;
|
|
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
|
|
+import com.xy.annotate.DictFormat;
|
|
|
+import com.xy.consts.DictConsts;
|
|
|
+import com.xy.convert.DictConvert;
|
|
|
import com.xy.utils.DataTime;
|
|
|
import com.xy.utils.PageBean;
|
|
|
import io.swagger.annotations.ApiModelProperty;
|
|
@@ -129,9 +133,25 @@ public class DeviceInfoDto {
|
|
|
@Accessors(chain = true)
|
|
|
public static class Page extends Vo {
|
|
|
|
|
|
+ @ApiModelProperty("是否导出当前页")
|
|
|
+ private Boolean exportPage = true;
|
|
|
+
|
|
|
@ApiModelProperty(value = "分页对象", required = true)
|
|
|
private PageBean page;
|
|
|
|
|
|
+ /**
|
|
|
+ * size -1 不分页
|
|
|
+ *
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public PageBean getPage() {
|
|
|
+ if (!this.exportPage) {
|
|
|
+ this.page.setSize(-1L);
|
|
|
+ }
|
|
|
+ return page;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
@ApiModelProperty("资产/sn/sim号")
|
|
|
private String no;
|
|
|
|
|
@@ -174,27 +194,35 @@ public class DeviceInfoDto {
|
|
|
public String getEndActiveTime() {
|
|
|
return endActiveTime == null ? null : DataTime.toString(endActiveTime.atTime(23, 59, 59));
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
}
|
|
|
|
|
|
@Data
|
|
|
@Accessors(chain = true)
|
|
|
public static class Vo {
|
|
|
|
|
|
+ @ExcelProperty("设备编号")
|
|
|
@ApiModelProperty("设备id")
|
|
|
private Long deviceId;
|
|
|
|
|
|
+ @ExcelProperty("设备名称")
|
|
|
@ApiModelProperty("设备名称")
|
|
|
private String deviceName;
|
|
|
|
|
|
+ @ExcelProperty(value = "设备类型", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_TYPE)
|
|
|
@ApiModelProperty("设备类型")
|
|
|
private Integer deviceType;
|
|
|
|
|
|
+ @ExcelProperty("商户设备资产编号")
|
|
|
@ApiModelProperty("商户设备资产编号")
|
|
|
private String mercDeviceCode;
|
|
|
|
|
|
@ApiModelProperty("商户id")
|
|
|
private Long mercId;
|
|
|
|
|
|
+ @ExcelProperty(value = "商户编码")
|
|
|
@ApiModelProperty("商户编码")
|
|
|
private String mercCode;
|
|
|
|
|
@@ -210,6 +238,8 @@ public class DeviceInfoDto {
|
|
|
@ApiModelProperty("区域id")
|
|
|
private Long districtId;
|
|
|
|
|
|
+ @ExcelProperty(value = "激活状态", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_ACTIVE_STATUS)
|
|
|
@ApiModelProperty("激活状态")
|
|
|
private Integer activeState;
|
|
|
|
|
@@ -217,12 +247,16 @@ public class DeviceInfoDto {
|
|
|
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
|
|
private LocalDateTime activeTime;
|
|
|
|
|
|
+ @ExcelProperty(value = "运营状态", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_BUSY_STATUS)
|
|
|
@ApiModelProperty("运营状态")
|
|
|
private Integer busyState;
|
|
|
|
|
|
@ApiModelProperty("显示状态")
|
|
|
private Boolean showStatus;
|
|
|
|
|
|
+ @ExcelProperty(value = "冻结状态", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_FREEZE_STATUS)
|
|
|
@ApiModelProperty("冻结状态")
|
|
|
private Integer freezeStatus;
|
|
|
|
|
@@ -235,6 +269,8 @@ public class DeviceInfoDto {
|
|
|
@ApiModelProperty("纬度")
|
|
|
private String lat;
|
|
|
|
|
|
+ @ExcelProperty(value = "故障等级", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_FAULT_LEVEL)
|
|
|
@ApiModelProperty("故障等级")
|
|
|
private Integer faultLevel;
|
|
|
|
|
@@ -249,6 +285,7 @@ public class DeviceInfoDto {
|
|
|
@ApiModelProperty("系统信息")
|
|
|
private DeviceSysinfoDto.Vo deviceSysinfo;
|
|
|
|
|
|
+
|
|
|
@ApiModelProperty("状态信息")
|
|
|
private DeviceStatusDto.Vo deviceStatus;
|
|
|
|
|
@@ -260,20 +297,97 @@ public class DeviceInfoDto {
|
|
|
@Accessors(chain = true)
|
|
|
public static class Vo2 extends Vo {
|
|
|
|
|
|
+ @ExcelProperty("所属商户")
|
|
|
@ApiModelProperty("商户名称")
|
|
|
private String mercName;
|
|
|
|
|
|
@ApiModelProperty("距离")
|
|
|
private Integer m;
|
|
|
|
|
|
+ @ExcelProperty("点位")
|
|
|
@ApiModelProperty("点位名称")
|
|
|
private String placeName;
|
|
|
|
|
|
+ @ExcelProperty("线路")
|
|
|
@ApiModelProperty("线路名称")
|
|
|
private String placeLineName;
|
|
|
+ @ExcelProperty("区域")
|
|
|
+ @ApiModelProperty("区域名称")
|
|
|
+ private String districtName;
|
|
|
+
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ @Data
|
|
|
+ @Accessors(chain = true)
|
|
|
+ public static class DeviceExcelVO {
|
|
|
+
|
|
|
+ @ExcelProperty("所属商户")
|
|
|
+ @ApiModelProperty("商户名称")
|
|
|
+ private String mercName;
|
|
|
+
|
|
|
|
|
|
+ @ExcelProperty("点位")
|
|
|
+ @ApiModelProperty("点位名称")
|
|
|
+ private String placeName;
|
|
|
+
|
|
|
+ @ExcelProperty("线路")
|
|
|
+ @ApiModelProperty("线路名称")
|
|
|
+ private String placeLineName;
|
|
|
+ @ExcelProperty("区域")
|
|
|
@ApiModelProperty("区域名称")
|
|
|
private String districtName;
|
|
|
+
|
|
|
+
|
|
|
+ @ExcelProperty("设备编号")
|
|
|
+ @ApiModelProperty("设备id")
|
|
|
+ private Long deviceId;
|
|
|
+
|
|
|
+ @ExcelProperty("设备名称")
|
|
|
+ @ApiModelProperty("设备名称")
|
|
|
+ private String deviceName;
|
|
|
+
|
|
|
+ @ExcelProperty(value = "设备类型", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_TYPE)
|
|
|
+ @ApiModelProperty("设备类型")
|
|
|
+ private Integer deviceType;
|
|
|
+
|
|
|
+ @ExcelProperty("商户设备资产编号")
|
|
|
+ @ApiModelProperty("商户设备资产编号")
|
|
|
+ private String mercDeviceCode;
|
|
|
+
|
|
|
+ @ApiModelProperty("商户id")
|
|
|
+ private Long mercId;
|
|
|
+
|
|
|
+ @ExcelProperty(value = "商户编码")
|
|
|
+ @ApiModelProperty("商户编码")
|
|
|
+ private String mercCode;
|
|
|
+
|
|
|
+
|
|
|
+ @ExcelProperty(value = "激活状态", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_ACTIVE_STATUS)
|
|
|
+ @ApiModelProperty("激活状态")
|
|
|
+ private Integer activeState;
|
|
|
+
|
|
|
+
|
|
|
+ @ExcelProperty(value = "运营状态", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_BUSY_STATUS)
|
|
|
+ @ApiModelProperty("运营状态")
|
|
|
+ private Integer busyState;
|
|
|
+
|
|
|
+
|
|
|
+ @ExcelProperty(value = "冻结状态", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_FREEZE_STATUS)
|
|
|
+ @ApiModelProperty("冻结状态")
|
|
|
+ private Integer freezeStatus;
|
|
|
+
|
|
|
+
|
|
|
+ @ExcelProperty(value = "故障等级", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictConsts.DEVICE_FAULT_LEVEL)
|
|
|
+ @ApiModelProperty("故障等级")
|
|
|
+ private Integer faultLevel;
|
|
|
+
|
|
|
}
|
|
|
|
|
|
|