package com.bonus.canteen.core.report.statistics.order.summary.param;

import cn.hutool.core.collection.CollUtil;
import com.bonus.canteen.core.report.statistics.order.basic.dto.ReportOrderInfoDTO;
import com.bonus.canteen.core.report.statistics.param.ReportBaseParam;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.time.LocalDate;
import java.util.List;

@ApiModel("按设备收入汇总入参")
public class ReportMachineParam extends ReportBaseParam {
   @ApiModelProperty("食堂id")
   private Long canteenId;
   @ApiModelProperty("档口id")
   private Long stallId;
   @ApiModelProperty("组织id")
   private Long orgId;
   @ApiModelProperty("组织id集合")
   private List<Long> orgIds;
   @ApiModelProperty("食堂档口id集合")
   private List<Long> canteenStallIds;
   @ApiModelProperty("食堂档口类型 1-食堂 2-档口")
   private Integer treeType;
   @ApiModelProperty("设备名称")
   private String machineName;
   @ApiModelProperty("设备类型")
   private Integer sourceType;
   @ApiModelProperty("餐次类型")
   private Integer mealtimeType;
   @ApiModelProperty("设备sn")
   private String machineSn;
   @ApiModelProperty("关键字查询,设备编号、名称、sn")
   private String keyword;
   @ApiModelProperty("区域id")
   private Long areaId;
   @ApiModelProperty("区域id集合")
   private List<Long> areaIdList;
   @ApiModelProperty("设备编号")
   private String machineNum;
   private LocalDate statisticDate;
   private String consumeSource;
   private Integer ifTotal = 2;
   private List<String> machineSnList;

   public ReportMachineParam(ReportOrderInfoDTO baseInfo, LocalDate statisticDate) {
      this.canteenId = baseInfo.getReportOrderInfo().getCanteenId();
      this.stallId = baseInfo.getReportOrderInfo().getStallId();
      this.orgId = baseInfo.getReportOrderInfo().getOrgId();
      this.startDate = statisticDate;
      this.endDate = statisticDate;
      this.ageTypes = CollUtil.newArrayList(new Integer[]{baseInfo.getReportOrderInfo().getAgeType()});
      this.sourceType = baseInfo.getReportOrderInfo().getSourceType();
      this.machineSn = baseInfo.getReportOrderInfo().getMachineSn();
      this.mealtimeType = baseInfo.getReportOrderInfo().getMealtimeType();
   }

   public Long getCanteenId() {
      return this.canteenId;
   }

   public Long getStallId() {
      return this.stallId;
   }

   public Long getOrgId() {
      return this.orgId;
   }

   public List<Long> getOrgIds() {
      return this.orgIds;
   }

   public List<Long> getCanteenStallIds() {
      return this.canteenStallIds;
   }

   public Integer getTreeType() {
      return this.treeType;
   }

   public String getMachineName() {
      return this.machineName;
   }

   public Integer getSourceType() {
      return this.sourceType;
   }

   public Integer getMealtimeType() {
      return this.mealtimeType;
   }

   public String getMachineSn() {
      return this.machineSn;
   }

   public String getKeyword() {
      return this.keyword;
   }

   public Long getAreaId() {
      return this.areaId;
   }

   public List<Long> getAreaIdList() {
      return this.areaIdList;
   }

   public String getMachineNum() {
      return this.machineNum;
   }

   public LocalDate getStatisticDate() {
      return this.statisticDate;
   }

   public String getConsumeSource() {
      return this.consumeSource;
   }

   public Integer getIfTotal() {
      return this.ifTotal;
   }

   public List<String> getMachineSnList() {
      return this.machineSnList;
   }

   public ReportMachineParam setCanteenId(final Long canteenId) {
      this.canteenId = canteenId;
      return this;
   }

   public ReportMachineParam setStallId(final Long stallId) {
      this.stallId = stallId;
      return this;
   }

   public ReportMachineParam setOrgId(final Long orgId) {
      this.orgId = orgId;
      return this;
   }

   public ReportMachineParam setOrgIds(final List<Long> orgIds) {
      this.orgIds = orgIds;
      return this;
   }

   public ReportMachineParam setCanteenStallIds(final List<Long> canteenStallIds) {
      this.canteenStallIds = canteenStallIds;
      return this;
   }

   public ReportMachineParam setTreeType(final Integer treeType) {
      this.treeType = treeType;
      return this;
   }

   public ReportMachineParam setMachineName(final String machineName) {
      this.machineName = machineName;
      return this;
   }

   public ReportMachineParam setSourceType(final Integer sourceType) {
      this.sourceType = sourceType;
      return this;
   }

   public ReportMachineParam setMealtimeType(final Integer mealtimeType) {
      this.mealtimeType = mealtimeType;
      return this;
   }

   public ReportMachineParam setMachineSn(final String machineSn) {
      this.machineSn = machineSn;
      return this;
   }

   public ReportMachineParam setKeyword(final String keyword) {
      this.keyword = keyword;
      return this;
   }

   public ReportMachineParam setAreaId(final Long areaId) {
      this.areaId = areaId;
      return this;
   }

   public ReportMachineParam setAreaIdList(final List<Long> areaIdList) {
      this.areaIdList = areaIdList;
      return this;
   }

   public ReportMachineParam setMachineNum(final String machineNum) {
      this.machineNum = machineNum;
      return this;
   }

   public ReportMachineParam setStatisticDate(final LocalDate statisticDate) {
      this.statisticDate = statisticDate;
      return this;
   }

   public ReportMachineParam setConsumeSource(final String consumeSource) {
      this.consumeSource = consumeSource;
      return this;
   }

   public ReportMachineParam setIfTotal(final Integer ifTotal) {
      this.ifTotal = ifTotal;
      return this;
   }

   public ReportMachineParam setMachineSnList(final List<String> machineSnList) {
      this.machineSnList = machineSnList;
      return this;
   }

   public String toString() {
      Long var10000 = this.getCanteenId();
      return "ReportMachineParam(canteenId=" + var10000 + ", stallId=" + this.getStallId() + ", orgId=" + this.getOrgId() + ", orgIds=" + String.valueOf(this.getOrgIds()) + ", canteenStallIds=" + String.valueOf(this.getCanteenStallIds()) + ", treeType=" + this.getTreeType() + ", machineName=" + this.getMachineName() + ", sourceType=" + this.getSourceType() + ", mealtimeType=" + this.getMealtimeType() + ", machineSn=" + this.getMachineSn() + ", keyword=" + this.getKeyword() + ", areaId=" + this.getAreaId() + ", areaIdList=" + String.valueOf(this.getAreaIdList()) + ", machineNum=" + this.getMachineNum() + ", statisticDate=" + String.valueOf(this.getStatisticDate()) + ", consumeSource=" + this.getConsumeSource() + ", ifTotal=" + this.getIfTotal() + ", machineSnList=" + String.valueOf(this.getMachineSnList()) + ")";
   }

   public ReportMachineParam(final Long canteenId, final Long stallId, final Long orgId, final List<Long> orgIds, final List<Long> canteenStallIds, final Integer treeType, final String machineName, final Integer sourceType, final Integer mealtimeType, final String machineSn, final String keyword, final Long areaId, final List<Long> areaIdList, final String machineNum, final LocalDate statisticDate, final String consumeSource, final Integer ifTotal, final List<String> machineSnList) {
      this.canteenId = canteenId;
      this.stallId = stallId;
      this.orgId = orgId;
      this.orgIds = orgIds;
      this.canteenStallIds = canteenStallIds;
      this.treeType = treeType;
      this.machineName = machineName;
      this.sourceType = sourceType;
      this.mealtimeType = mealtimeType;
      this.machineSn = machineSn;
      this.keyword = keyword;
      this.areaId = areaId;
      this.areaIdList = areaIdList;
      this.machineNum = machineNum;
      this.statisticDate = statisticDate;
      this.consumeSource = consumeSource;
      this.ifTotal = ifTotal;
      this.machineSnList = machineSnList;
   }

   public ReportMachineParam() {
   }
}
