package com.yonge.cooleshow.biz.dal.dto;

import com.yonge.cooleshow.biz.dal.entity.UserAccountRecord;
import com.yonge.cooleshow.biz.dal.enums.AccountBizTypeEnum;
import com.yonge.cooleshow.biz.dal.enums.FrozenTypeEnum;
import com.yonge.cooleshow.biz.dal.enums.InOrOutEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.math.BigDecimal;

/**
 * 账户变更传输对象
 *
 * @Author: liweifan
 * @Data: 2022/4/7 15:46
 */
@ApiModel(value = "UserAccountRecordDto对象", description = "账户变更传输对象")
public class UserAccountRecordDto extends UserAccountRecord {

    @ApiModelProperty(value = "用户id", required = true)
    private Long userId;
    @ApiModelProperty(value = "变更冻结类型 NONE 无 FROZEN 冻结 UNFROZEN 解冻")
    private FrozenTypeEnum frozenType;

    private Boolean saveRecord = true;

    public UserAccountRecordDto() {
    }

    public UserAccountRecordDto(Long userId, BigDecimal transAmount, InOrOutEnum inOrOut, AccountBizTypeEnum bizType) {
        this.userId = userId;
        this.setTransAmount(transAmount);
        this.setInOrOut(inOrOut);
        this.setBizType(bizType);
    }

    public UserAccountRecordDto(Long userId, BigDecimal transAmount, InOrOutEnum inOrOut, AccountBizTypeEnum bizType,
                                Long bizId, String bizName, String orderNo) {
        this.userId = userId;
        this.setTransAmount(transAmount);
        this.setInOrOut(inOrOut);
        this.setBizType(bizType);
        this.setBizId(bizId);
        this.setBizName(bizName);
        this.setOrderNo(orderNo);
    }

    public Boolean getSaveRecord() {
        return saveRecord;
    }

    public void setSaveRecord(Boolean saveRecord) {
        this.saveRecord = saveRecord;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public FrozenTypeEnum getFrozenType() {
        return frozenType;
    }

    public void setFrozenType(FrozenTypeEnum frozenType) {
        this.frozenType = frozenType;
    }
}
