package com.willalp.system.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.willalp.common.annotation.Excel;
import com.willalp.common.core.domain.BaseEntity;

/**
 * 用户机构对象 sys_user_organization
 *
 * @author willalp
 * @date 2021-12-23
 */

@TableName("sys_user_organization")
public class SysUserOrganization {

    /** 主键 */
    @TableId(type = IdType.AUTO)
    private Integer id;

    /** 用户编码 */
    @Excel(name = "用户编码")
    private String loginName;

    /** 机构代码 */
    @Excel(name = "机构代码")
    private String organizationCode;

    /** 用户类型 */
    @Excel(name = "用户类型")
    private String userType;

    /** 账户积分 */
    @Excel(name = "账户积分")
    private BigDecimal integral;

    /** 记账额度 */
    @Excel(name = "记账额度")
    private BigDecimal quota;

    /** 押金 */
    @Excel(name = "押金")
    private BigDecimal deposit;

    /** 有效日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "有效日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date effectiveDate;

    @Excel(name = "是否默认机构")
    private Integer isDefault;

    @TableField(exist = false)
    private String nickName;

    public void setId(Integer id)
    {
        this.id = id;
    }

    public Integer getId()
    {
        return id;
    }
    public void setLoginName(String loginName)
    {
        this.loginName = loginName;
    }

    public String getLoginName()
    {
        return loginName;
    }
    public void setOrganizationCode(String organizationCode)
    {
        this.organizationCode = organizationCode;
    }

    public String getOrganizationCode()
    {
        return organizationCode;
    }
    public void setUserType(String userType)
    {
        this.userType = userType;
    }

    public String getUserType()
    {
        return userType;
    }
    public void setIntegral(BigDecimal integral)
    {
        this.integral = integral;
    }

    public BigDecimal getIntegral()
    {
        return integral;
    }
    public void setEffectiveDate(Date effectiveDate)
    {
        this.effectiveDate = effectiveDate;
    }

    public Date getEffectiveDate()
    {
        return effectiveDate;
    }

    public Integer getIsDefault() {
        return isDefault;
    }

    public void setIsDefault(Integer isDefault) {
        this.isDefault = isDefault;
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickName) {
        this.nickName = nickName;
    }

    public BigDecimal getQuota() {
        return quota;
    }

    public void setQuota(BigDecimal quota) {
        this.quota = quota;
    }

    public BigDecimal getDeposit() {
        return deposit;
    }

    public void setDeposit(BigDecimal deposit) {
        this.deposit = deposit;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("loginName", getLoginName())
            .append("organizationCode", getOrganizationCode())
            .append("userType", getUserType())
            .append("integral", getIntegral())
            .append("effectiveDate", getEffectiveDate())
            .append("isDefault", getIsDefault())
                .append("deposit",getDeposit())
                .append("quota",getQuota())
            .toString();
    }
}
