package com.yuchen.saas.manage.system.api.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.nest.springwrap.core.tenant.mp.TenantEntity;

import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * <p>
 * 服务开通管理
 * </p>
 *
 * @author linyb
 * @since 2023-09-19
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("nest_business_open_manage")
@ApiModel(value="NestBusinessOpenManage对象", description="服务开通管理")
public class NestBusinessOpenManage extends TenantEntity {

    /**
     * 业务id
     */
    @NotNull(message = "业务id不能为空")
    @ApiModelProperty(name = "businessId", value = "业务id",required = true)
    private Long businessId;
    /**
     * 客户id
     */
    @NotNull(message = "客户id不能为空")
    @ApiModelProperty(name = "customerId", value = "客户id",required = true)
    private Long customerId;
    /**
     * 服务期限(年)
     */
    @ApiModelProperty(name = "businessPeriod", value = "服务期限(年)")
    private Integer businessPeriod;

    /**
     * 启动日期
     */
    @ApiModelProperty(name = "startDate", value = "启动日期")
    private Date startDate;
    /**
     * 有限日期
     */
    @ApiModelProperty(name = "expireDate", value = "有限日期")
    private Date expireDate;
    @ApiModelProperty(name = "status", value = "状态（1：未启用，2：正常，3：已暂停，4：已关闭）")
    private Integer status;
    @ApiModelProperty(name = "pausedDate", value = "暂停日期")
    private Date pausedDate;
    @ApiModelProperty(name = "residueSecond", value = "暂停后剩余过期时间的秒值")
    private Long residueSecond;
    @ApiModelProperty(value = "开通人名")
    @TableField(exist = false)
    private String createName;

    @ApiModelProperty(value = "客户名称")
    @TableField(exist = false)
    private String customerName;

    @ApiModelProperty(value = "业务名称")
    @TableField(exist = false)
    private String businessName;
}
