package com.neusoft.smart.pos.dto.ota.request;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

@Data
@ApiModel
public class UpgradeStrategyGroupRequest {
	
	private Integer id;
	
	@NotNull(message = "策略名称不可为空")
	@ApiModelProperty(name = "deviceId", value = "策略名称", dataType = "String", example = "1", required = true)
	private String strategyName;
	
	@NotNull(message = "更新包id不可为空")
	@ApiModelProperty(name = "packageId", value = "更新包id", dataType = "Integer", example = "1", required = true)
	private Integer packageId;
	
	@NotNull(message = "升级开始时间不可为空")
	@ApiModelProperty(name = "upgradeStartTime", value = "升级开始时间", dataType = "Date", example = "20178-02-01 14:00:00", required = true)
	@JsonFormat(pattern="yyyy-MM-dd HH:mm")
	private Date upgradeStartTime;
	
	@ApiModelProperty(name = "upgradeEndTime", value = "升级结束时间", dataType = "Date", example = "20178-02-01 14:00:00", required = true)
	private Date upgradeEndTime;
	
	private Integer isForce;
	
	private Integer organizationId;
	
	private Integer createdBy;
	
	private Date createdDate;
	
	private Integer lastModifiedBy;
	
	private Date lastModifiedDate;
	
	private Integer status;
	
	@NotNull(message = "升级设备列表不可为空")
	@ApiModelProperty(name = "devices", value = "升级设备列表", dataType = "List", example = "[]", required = true)
	private List<UpgradeStrategyDeviceRequest> devices;
	
	
}
