package com.gic.haoban.manage.api.dto.chat;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.google.common.base.Objects;

import java.io.Serializable;
import java.util.List;

/**
 * 社群邀请有礼奖励规则表(TabHaobanGroupChatActivityReward)实体类
 *
 * @author makejava
 * @since 2024-09-27 16:09:56
 */
public class GroupChatActivityRewardDTO implements Serializable {
    private static final long serialVersionUID = -78111537762472232L;
    /**
     * 内容活动id
     */
    @JsonSerialize(using = ToStringSerializer.class)
    private Long chatActivityId;
    /**
     * 奖励邀请人数
     */
    private Integer inviteNumber;
    /**
     * 奖励阶梯 固定奖励默认1
     */
    private Integer inviteLevel;
    /**
     * 奖励人类型 1邀请人2受邀人
     */
    private Integer rewardInvite;
    /**
     * 最多奖励数量
     */
    private Integer limitReward;

    /**
     * 奖励明细列表
     */
    private List<GroupChatActivityRewardDetailDTO> detailList;


    public Long getChatActivityId() {
        return chatActivityId;
    }

    public void setChatActivityId(Long chatActivityId) {
        this.chatActivityId = chatActivityId;
    }

    public Integer getInviteNumber() {
        return inviteNumber;
    }

    public void setInviteNumber(Integer inviteNumber) {
        this.inviteNumber = inviteNumber;
    }

    public Integer getInviteLevel() {
        return inviteLevel;
    }

    public void setInviteLevel(Integer inviteLevel) {
        this.inviteLevel = inviteLevel;
    }

    public Integer getRewardInvite() {
        return rewardInvite;
    }

    public void setRewardInvite(Integer rewardInvite) {
        this.rewardInvite = rewardInvite;
    }

    public Integer getLimitReward() {
        return limitReward;
    }

    public void setLimitReward(Integer limitReward) {
        this.limitReward = limitReward;
    }

    public List<GroupChatActivityRewardDetailDTO> getDetailList() {
        return detailList;
    }

    public void setDetailList(List<GroupChatActivityRewardDetailDTO> detailList) {
        this.detailList = detailList;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        GroupChatActivityRewardDTO rewardDTO = (GroupChatActivityRewardDTO) o;
        return Objects.equal(chatActivityId, rewardDTO.chatActivityId) && Objects.equal(inviteNumber, rewardDTO.inviteNumber) && Objects.equal(inviteLevel, rewardDTO.inviteLevel) && Objects.equal(rewardInvite, rewardDTO.rewardInvite) && Objects.equal(limitReward, rewardDTO.limitReward) && Objects.equal(detailList, rewardDTO.detailList);
    }

    @Override
    public int hashCode() {
        return Objects.hashCode(chatActivityId, inviteNumber, inviteLevel, rewardInvite, limitReward, detailList);
    }
}

