package com.pig4cloud.pigx.app.api.entity.as;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDateTime;

/**
 * 流媒体订阅账号
 *
 * @author amigo
 * @date 2023-08
 */
@Data
@TableName("as_sub_account")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "as流媒体订阅账号")
public class AsSubAccount extends Model<AsSubAccount> {
	private static final long serialVersionUID = 1L;

	/**
	 * 产品id
	 */
	@Schema(description = "product_id")
	private Long productId;

	@TableId(type = IdType.ASSIGN_ID)
	@Schema(description = "ID")
	private Long id;

	/**
	 * 订阅计划id
	 */
	@Schema(description = "sub_plan_id")
	private Integer subPlanId;

	/**
	 * main user
	 */
	@Schema(description = "user_id")
	private Integer userId;

	/**
	 * 付费计划id
	 */
	@Schema(description = "sub_payroll_id")
	private Integer subPayrollId;

	/**
	 * 地区
	 */
	@Schema(description = "region")
	private String region;

	/**
	 * 分享类型
	 */
	@Schema(description = "share_type")
	private Integer shareType;

	/**
	 * 账号类型
	 */
	@Schema(description = "account_type")
	private Integer accountType;

	/**
	 * 续费日期
	 */
	@Schema(description = "renew_date")
	private LocalDateTime renewDate;

	/**
	 * 平台id
	 */
	@Schema(description = "platform_id")
	private Integer platformId;

	/**
	 * 用户名
	 */
	@Schema(description = "account_name")
	private String accountName;

	/**
	 * 用户密码
	 */
	@Schema(description = "account_passwd")
	private String accountPasswd;

	/**
	 * 密码salt
	 */
	@Schema(description = "passwd_salt")
	private Integer passwdSalt;
}
