package com.red.circle.wallet.domain.wallet;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.red.circle.common.business.core.enums.OpUserType;
import com.red.circle.common.business.core.enums.ReceiptType;
import java.io.Serial;
import java.io.Serializable;
import java.sql.Timestamp;
import lombok.Data;
import lombok.experimental.Accessors;

/**
 * 钱包异常日志.
 *
 * @author pengliang on 2023/7/2
 */
@Data
@Accessors(chain = true)
public class WalletExceptionLogRecord implements Serializable {

  @Serial
  private static final long serialVersionUID = 1L;

  /**
   * 资产记录id.
   */
  private Long assetRecordId;

  /**
   * 单据类型(0收入，1支出).
   */
  private ReceiptType receiptType;

  /**
   * 用户id.
   */
  @JsonSerialize(using = ToStringSerializer.class)
  private Long userId;

  /**
   * 归属系统.
   */
  private String sysOrigin;

  /**
   * 事件类型.
   */
  private String eventType;

  /**
   * 事件描述.
   */
  private String eventDesc;

  /**
   * 事件id(订单，关联信息).
   */
  private String eventId;

  /**
   * 备注.
   */
  private String remark;

  /**
   * 操作用户类型(0.app用户， 1.后台管理用户).
   */
  private OpUserType opUserType;

  /**
   * 金币数量.
   */
  private Long pennyAmount;

  /**
   * 金币余额.
   */
  private Long pennyBalance;

  /**
   * 业务类型.
   */
  private WalletBizType bizType;

  /**
   * 创建时间.
   */
  private Timestamp createTime;

  /**
   * 原因.
   */
  private WalletErrorLogReason reason;

  /**
   * 0.等待处理，1.已处理.
   */
  private Integer status;
}
