package com.yuchen.saas.park.api.vo.property;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.thinkunion.park.service.common.utils.AmtUtil;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 预存款账单抵扣列表
 */
@Data
public class PropertyPrepaymentDetailListVo {

    private Long id;
    @JsonIgnore
    private Long houseId;
    /**
     * 房间代码
     */
    private String resourceCode;
    @JsonIgnore
    private Long feeItemId;
    /**
     * 收费项目
     */
    private String feeItemName;

    private long needPayAmtFen;
    /**
     * 核销前应收金额: 单位 元
     */
    private BigDecimal needPayAmt;
    private BigDecimal getNeedPayAmt() {
        return AmtUtil.fenToYuan(this.needPayAmtFen);
    }
    /**
     * 核销金额
     */
    private long deductAmtFen;
    private BigDecimal getDeductAmt() {
        return AmtUtil.fenToYuan(this.deductAmtFen);
    }
    /**
     * 核销日期
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private Date recordTime;
    /**
     * 计费开始日期
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    private Date startDate;
    /**
     * 计费结束日期
     */
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    private Date endDate;


}
