package com.mortals.xhx.module.access.model;
import java.util.List;
import java.util.List;
import java.util.ArrayList;
import java.math.BigDecimal;
import cn.hutool.core.date.DateUtil;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.mortals.framework.annotation.Excel;
import com.mortals.framework.model.BaseEntityLong;
import com.mortals.xhx.module.access.model.vo.AccessVo;
import com.mortals.xhx.module.access.model.AccessSystemEntity;
import lombok.Data;
/**
* 区域接入实体对象
*
* @author zxfei
* @date 2024-06-28
*/
@Data
public class AccessEntity extends AccessVo {
    private static final long serialVersionUID = 1L;

    /**
    * 区域名称
    */
    private String areaName;
    /**
    * 区域编码
    */
    private String areaCode;
    /**
    * 背景图片地址
    */
    private String bigPath;
    /**
    * 标签
    */
    private String tag;
    /**
    * 排序
    */
    private Integer sort;
    /**
    * 备注
    */
    private String remark;
    /**
    * 区域接入系统信息
    */
    private List<AccessSystemEntity> accessSystemList=new ArrayList<>();;
    public List<AccessSystemEntity> getAccessSystemList(){
      return accessSystemList;
    }

    public void setAccessSystemList(List<AccessSystemEntity> accessSystemList){
        this.accessSystemList = accessSystemList;
    }
    @Override
    public int hashCode() {
         return this.getId().hashCode();
    }
    @Override
    public boolean equals(Object obj) {
        if (obj == null) return false;
        if (obj instanceof AccessEntity) {
            AccessEntity tmp = (AccessEntity) obj;
            if (this.getId() == tmp.getId()) {
                 return true;
            }
        }
        return false;
    }

    public void initAttrValue(){
            this.areaName = "";
            this.areaCode = "";
            this.bigPath = "";
            this.tag = "";
            this.sort = 0;
            this.remark = "";
    }
}