package com.yihu.jw.entity.iot.company;

import com.yihu.jw.entity.UuidIdentityEntityWithOperator;
import com.yihu.jw.entity.util.StringFStringEncryptConverter;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * 企业表
 * @author yeshijie on 2018/1/15.
 */
@Entity
@Table(name = "iot_company")
public class IotCompanyDO extends UuidIdentityEntityWithOperator implements Serializable {

    @Column(name = "saas_id")
    private String saasId;//
    @Column(name = "status")
    private String status;//审核状态（预留字段）
    @Column(name = "name")
    private String name;//企业名称
    @Column(name = "is_three_in_one")
    private Integer isThreeInOne;//是否三证合一（1是，0否）
    @Column(name = "business_license")
    private String businessLicense;//统一社会信用代码/营业执照
    @Column(name = "business_start_time")
    private Date businessStartTime;//营业开始时间
    @Column(name = "business_end_time")
    private Date businessEndTime;//营业结束时间
    @Column(name = "organization_address")
    private String organizationAddress;//机构地址
    @Column(name = "office_phone")
    private String officePhone;//办公电话
    @Column(name = "contacts_name")
    private String contactsName;//联系人姓名
    @Column(name = "contacts_mobile")
    private String contactsMobile;//联系人手机号码
    @Column(name = "contacts_idcard")
    private String contactsIdcard;//联系人身份证号
    @Column(name = "contacts_email")
    private String contactsEmail;//联系人邮件
    @Column(name = "business_license_img")
    private String businessLicenseImg;//统一社会信用代码证照片
    @Column(name = "organization_code_img")
    private String organizationCodeImg;//组织机构代码证照片
    @Column(name = "tax_registration_img")
    private String taxRegistrationImg;//税务登记证照片
    @Column(name = "contacts_idcard_img")
    private String contactsIdcardImg;//联系人身份证照片
    @Column(name = "account")
    private String account;//账号
    @Column(name = "ehr_user_id")
    private String ehrUserId;//    ehr用户id，修改密码时使用
    @Column(name = "del")
    private Integer del;//删除标志(1有效，0删除)

    @Transient
    private List<IotCompanyTypeDO> typeList;//类型

    //    新增加的字段
    @Column(name = "enter_type")
    private String enterType;//厂商入驻类型 1:供应商  2：代理商 3：厂商
    @Column(name = "account_type")
    private String accountType;//注册类型（1：厂商注册  0：平台注册）
    @Column(name = "audit_message")
    private String auditMessage;//审核不通过信息说明
    @Column(name = "audit_time")
    private Date auditTime;//审核时间
    @Column(name = "audit_name")
    private String auditName;//审核人姓名
    @Transient
    private List<IotCompanyAppDO> appList;//应用实体

    public String getSaasId() {
        return saasId;
    }

    public void setSaasId(String saasId) {
        this.saasId = saasId;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Integer getIsThreeInOne() {
        return isThreeInOne;
    }

    public void setIsThreeInOne(Integer isThreeInOne) {
        this.isThreeInOne = isThreeInOne;
    }

    public String getBusinessLicense() {
        return businessLicense;
    }

    public void setBusinessLicense(String businessLicense) {
        this.businessLicense = businessLicense;
    }

    public Date getBusinessStartTime() {
        return businessStartTime;
    }

    public void setBusinessStartTime(Date businessStartTime) {
        this.businessStartTime = businessStartTime;
    }

    public Date getBusinessEndTime() {
        return businessEndTime;
    }

    public void setBusinessEndTime(Date businessEndTime) {
        this.businessEndTime = businessEndTime;
    }

    public String getOrganizationAddress() {
        return organizationAddress;
    }

    public void setOrganizationAddress(String organizationAddress) {
        this.organizationAddress = organizationAddress;
    }

    @Convert(converter = StringFStringEncryptConverter.class)
    public String getOfficePhone() {
        return officePhone;
    }

    public void setOfficePhone(String officePhone) {
        this.officePhone = officePhone;
    }

    @Convert(converter = StringFStringEncryptConverter.class)
    public String getContactsName() {
        return contactsName;
    }

    public void setContactsName(String contactsName) {
        this.contactsName = contactsName;
    }

    @Convert(converter = StringFStringEncryptConverter.class)
    public String getContactsMobile() {
        return contactsMobile;
    }

    public void setContactsMobile(String contactsMobile) {
        this.contactsMobile = contactsMobile;
    }

    @Convert(converter = StringFStringEncryptConverter.class)
    public String getContactsIdcard() {
        return contactsIdcard;
    }

    public void setContactsIdcard(String contactsIdcard) {
        this.contactsIdcard = contactsIdcard;
    }

    public String getContactsEmail() {
        return contactsEmail;
    }

    public void setContactsEmail(String contactsEmail) {
        this.contactsEmail = contactsEmail;
    }

    public String getBusinessLicenseImg() {
        return businessLicenseImg;
    }

    public void setBusinessLicenseImg(String businessLicenseImg) {
        this.businessLicenseImg = businessLicenseImg;
    }

    public String getOrganizationCodeImg() {
        return organizationCodeImg;
    }

    public void setOrganizationCodeImg(String organizationCodeImg) {
        this.organizationCodeImg = organizationCodeImg;
    }

    public String getTaxRegistrationImg() {
        return taxRegistrationImg;
    }

    public void setTaxRegistrationImg(String taxRegistrationImg) {
        this.taxRegistrationImg = taxRegistrationImg;
    }

    public String getContactsIdcardImg() {
        return contactsIdcardImg;
    }

    public void setContactsIdcardImg(String contactsIdcardImg) {
        this.contactsIdcardImg = contactsIdcardImg;
    }

    public String getAccount() {
        return account;
    }

    public void setAccount(String account) {
        this.account = account;
    }

    public String getEhrUserId() {
        return ehrUserId;
    }

    public void setEhrUserId(String ehrUserId) {
        this.ehrUserId = ehrUserId;
    }

    public Integer getDel() {
        return del;
    }

    public void setDel(Integer del) {
        this.del = del;
    }

    @Transient
    public List<IotCompanyTypeDO> getTypeList() {
        return typeList;
    }

    public void setTypeList(List<IotCompanyTypeDO> typeList) {
        this.typeList = typeList;
    }

    public String getEnterType() {
        return enterType;
    }

    public void setEnterType(String enterType) {
        this.enterType = enterType;
    }

    public String getAccountType() {
        return accountType;
    }

    public void setAccountType(String accountType) {
        this.accountType = accountType;
    }

    public String getAuditMessage() {
        return auditMessage;
    }

    public void setAuditMessage(String auditMessage) {
        this.auditMessage = auditMessage;
    }

    public Date getAuditTime() {
        return auditTime;
    }

    public void setAuditTime(Date auditTime) {
        this.auditTime = auditTime;
    }

    @Convert(converter = StringFStringEncryptConverter.class)
    public String getAuditName() {
        return auditName;
    }

    public void setAuditName(String auditName) {
        this.auditName = auditName;
    }

    @Transient
    public List<IotCompanyAppDO> getAppList() {
        return appList;
    }

    public void setAppList(List<IotCompanyAppDO> appList) {
        this.appList = appList;
    }
}
