package com.zcxk.charge.api.dto.watepump;

import com.zcxk.charge.api.vo.DeviceVo;
import com.zcxk.core.utils.encrypt.Md5;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.extern.slf4j.Slf4j;

import java.util.List;

/**
 * @ClassName ReprotWaterPumpQueryDto
 * @Description: 泵站查询条件
 * @Author lihui
 * @Date 2021/4/20
 * @Version V1.0
 **/
@Data
@Slf4j
public class ReprotWaterPumpQueryDto {

    @ApiModelProperty(value = "租户标识")
    private String tenantId;

    @ApiModelProperty(value = "设备信息")
    private Integer deviceId;

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

    @ApiModelProperty(value = "设备属性")
    private Long attributeId;

    @ApiModelProperty(value = "年")
    private Integer year;

    @ApiModelProperty(value = "月")
    private Integer month;

    @ApiModelProperty(value = "日")
    private Integer day;

    @ApiModelProperty(value = "状态")
    private Integer state;

    @ApiModelProperty(value = "md5查询")
    private String md5Query;

    @ApiModelProperty(value = "开始时间")
    private String beginTime;

    @ApiModelProperty(value = "设备IDS")
    private List<DeviceVo> deviceIds;

    @ApiModelProperty(value = "场景ID")
    private Long sceneId;

    public String getMd5Query () {
        return Md5.hash(tenantId + deviceId + deviceCode + attributeId + year + month);
    }

}
