|
@@ -1,5 +1,8 @@
|
|
|
package cn.iocoder.yudao.module.iot.controller.admin.product.vo.product;
|
|
|
|
|
|
+import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
|
|
|
+import cn.iocoder.yudao.framework.excel.core.convert.DictConvert;
|
|
|
+import cn.iocoder.yudao.module.iot.enums.DictTypeConstants;
|
|
|
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
|
|
|
import com.alibaba.excel.annotation.ExcelProperty;
|
|
|
import io.swagger.v3.oas.annotations.media.Schema;
|
|
@@ -28,12 +31,15 @@ public class IotProductRespVO {
|
|
|
private Long categoryId;
|
|
|
|
|
|
@Schema(description = "产品分类名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
|
|
|
+ @ExcelProperty("产品分类")
|
|
|
private String categoryName;
|
|
|
|
|
|
@Schema(description = "产品图标", example = "https://iocoder.cn/1.svg")
|
|
|
+ @ExcelProperty("产品图标")
|
|
|
private String icon;
|
|
|
|
|
|
@Schema(description = "产品图标", example = "https://iocoder.cn/1.png")
|
|
|
+ @ExcelProperty("产品图标")
|
|
|
private String picUrl;
|
|
|
|
|
|
@Schema(description = "产品描述", example = "你猜")
|
|
@@ -41,19 +47,23 @@ public class IotProductRespVO {
|
|
|
private String description;
|
|
|
|
|
|
@Schema(description = "产品状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
|
|
|
- @ExcelProperty("产品状态")
|
|
|
+ @ExcelProperty(value = "产品状态", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictTypeConstants.PRODUCT_STATUS)
|
|
|
private Integer status;
|
|
|
|
|
|
@Schema(description = "设备类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
|
|
|
- @ExcelProperty("设备类型")
|
|
|
+ @ExcelProperty(value = "设备类型", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictTypeConstants.PRODUCT_DEVICE_TYPE)
|
|
|
private Integer deviceType;
|
|
|
|
|
|
@Schema(description = "联网方式", example = "2")
|
|
|
- @ExcelProperty("联网方式")
|
|
|
+ @ExcelProperty(value = "联网方式", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictTypeConstants.NET_TYPE)
|
|
|
private Integer netType;
|
|
|
|
|
|
@Schema(description = "接入网关协议", example = "2")
|
|
|
- @ExcelProperty("接入网关协议")
|
|
|
+ @ExcelProperty(value = "接入网关协议", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictTypeConstants.PROTOCOL_TYPE)
|
|
|
private Integer protocolType;
|
|
|
|
|
|
@Schema(description = "协议编号(脚本解析 id)", requiredMode = Schema.RequiredMode.REQUIRED, example = "13177")
|
|
@@ -61,11 +71,13 @@ public class IotProductRespVO {
|
|
|
private Long protocolId;
|
|
|
|
|
|
@Schema(description = "数据格式")
|
|
|
- @ExcelProperty("数据格式")
|
|
|
+ @ExcelProperty(value = "数据格式", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictTypeConstants.DATA_FORMAT)
|
|
|
private Integer dataFormat;
|
|
|
|
|
|
@Schema(description = "数据校验级别", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
|
|
|
- @ExcelProperty("数据校验级别")
|
|
|
+ @ExcelProperty(value = "数据校验级别", converter = DictConvert.class)
|
|
|
+ @DictFormat(DictTypeConstants.VALIDATE_TYPE)
|
|
|
private Integer validateType;
|
|
|
|
|
|
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
|