package com.zcxk.rmcp.api.dto.device;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.bind.annotation.RequestParam;

import java.time.LocalDateTime;

/**
 * @author linqingwei
 * @date 2021-07-29 10:30
 */
@Data
@ApiModel
public class DeviceQueryDto {

    @ApiModelProperty(value = "分类id")
    private Integer categoryId;

    @ApiModelProperty(value = "产品id")
    private Integer productId;

    @ApiModelProperty(value = "公司id")
    private Integer companyOrgId;

    @ApiModelProperty(value = "部门id")
    private Integer deptOrgId;

    @ApiModelProperty(value = "小区id")
    private Integer communityId;

    @ApiModelProperty(value = "设备编号")
    private String deviceNo;

    @ApiModelProperty(value = "安装地址")
    private String address;

    @ApiModelProperty(value = "集中器id")
    private Integer concentratorId;

    @ApiModelProperty(value = "集中器编号")
    private String concentratorNo;

    @ApiModelProperty(value = "采集器id")
    private Integer collectorId;

    @ApiModelProperty(value = "采集器编号")
    private String collectorNo;

    @ApiModelProperty(value = "通道号id")
    private Integer channelNumberId;

    @ApiModelProperty(value = "设备状态  1:正常 2:故障 3:无 4: 预警 5:未启用")
    private Integer deviceStatus;

    @ApiModelProperty(value = "阀门状态 0：关阀 1：开阀  2：异常")
    private Integer valveStatus;

    @DateTimeFormat(pattern = "yyyyMMddHHmmss")
    @ApiModelProperty(value = "开始时间 格式：yyyyMMddHHmmss")
    private LocalDateTime startDate;

    @DateTimeFormat(pattern = "yyyyMMddHHmmss")
    @ApiModelProperty(value = "结束时间 格式：yyyyMMddHHmmss")
    private LocalDateTime endDate;

    @ApiModelProperty(value = "排序参数，对应列表字段 example:sortColumn=sd.date_create",example = "sd.date_create")
    private String sortColumn;

    @ApiModelProperty(value = "排序方式，顺序：ASC  倒序：DESC example:sortOrder=DESC",example = "DESC")
    private String sortOrder;
}
