package com.prolog.cs.biz.outbound.model.vo;

import io.swagger.annotations.ApiModelProperty;

public class BillGroupByVO {

    @ApiModelProperty(value = "波次ID")
    private String waveId;

    @ApiModelProperty(value = "货主ID")
    private String consignorId;

    @ApiModelProperty(value = "收货联系人")
    private String contactName;

    @ApiModelProperty(value = "收货联系人电话")
    private String contactTel;

    @ApiModelProperty(value = "收货地址")
    private String receiveAddress;

    @ApiModelProperty(value = "部门")
    private String saleBranchName;

    @ApiModelProperty(value = "账期类型")
    private String paymentDayType;

    private boolean sameDeptNo;
    private boolean samePaymentDayTye;

    public String getSaleBranchName() {
        return saleBranchName;
    }

    public void setSaleBranchName(String saleBranchName) {
        this.saleBranchName = saleBranchName;
    }

    public String getPaymentDayType() {
        return paymentDayType;
    }

    public void setPaymentDayType(String paymentDayType) {
        this.paymentDayType = paymentDayType;
    }

    public String getWaveId() {
        return waveId;
    }

    public void setWaveId(String waveId) {
        this.waveId = waveId;
    }

    public String getConsignorId() {
        return consignorId;
    }

    public void setConsignorId(String consignorId) {
        this.consignorId = consignorId;
    }

    public String getContactName() {
        return contactName;
    }

    public void setContactName(String contactName) {
        this.contactName = contactName;
    }

    public String getContactTel() {
        return contactTel;
    }

    public void setContactTel(String contactTel) {
        this.contactTel = contactTel;
    }

    public String getReceiveAddress() {
        return receiveAddress;
    }

    public void setReceiveAddress(String receiveAddress) {
        this.receiveAddress = receiveAddress;
    }

    public boolean isSameDeptNo() {
        return sameDeptNo;
    }

    public void setSameDeptNo(boolean sameDeptNo) {
        this.sameDeptNo = sameDeptNo;
    }

    public boolean isSamePaymentDayTye() {
        return samePaymentDayTye;
    }

    public void setSamePaymentDayTye(boolean samePaymentDayTye) {
        this.samePaymentDayTye = samePaymentDayTye;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }

        BillGroupByVO groupByVO = (BillGroupByVO) o;

        if (waveId != null ? !waveId.equals(groupByVO.waveId):groupByVO.waveId != null) {
            return false;
        }
        if (consignorId != null ? !consignorId.equals(groupByVO.consignorId):groupByVO.consignorId != null) {
            return false;
        }
        if (contactName != null ? !contactName.equals(groupByVO.contactName):groupByVO.contactName != null) {
            return false;
        }
        if (contactTel != null ? !contactTel.equals(groupByVO.contactTel):groupByVO.contactTel != null) {
            return false;
        }
        if (receiveAddress != null ? !receiveAddress.equals(groupByVO.receiveAddress):groupByVO.receiveAddress != null) {
            return false;
        }
        if (sameDeptNo) {
            if (saleBranchName != null ? !saleBranchName.equals(groupByVO.saleBranchName):groupByVO.saleBranchName != null) {
                return false;
            }
        }
        if (samePaymentDayTye) {
            return paymentDayType != null ? paymentDayType.equals(groupByVO.paymentDayType):groupByVO.paymentDayType == null;
        }
        return true;
    }

    @Override
    public int hashCode() {
        int result = waveId != null ? waveId.hashCode():0;
        result = 31 * result + (consignorId != null ? consignorId.hashCode():0);
        result = 31 * result + (contactName != null ? contactName.hashCode():0);
        result = 31 * result + (contactTel != null ? contactTel.hashCode():0);
        result = 31 * result + (receiveAddress != null ? receiveAddress.hashCode():0);
        if  (sameDeptNo) {
            result =    31 * result + (saleBranchName != null ? saleBranchName.hashCode():0);
        }

        if  (samePaymentDayTye) {
            result =    31 * result + (paymentDayType != null ? paymentDayType.hashCode():0);
        }
        return result;
    }
}
