package com.brilliance.isc.common.invchk.vo;

import com.brilliance.isc.bo.Invuse;
import com.brilliance.isc.common.vo.AbstractCommonVo;
import com.brilliance.mda.runtime.mda.util.Decimals;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import lombok.Data;

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

import static com.brilliance.mda.runtime.mda.Constants.NULLSTR;

@Data
@JsonIgnoreProperties(ignoreUnknown = true)
public class InvchkVo extends AbstractCommonVo {

    //是否需要发票核验标志
    private  String chkflg = NULLSTR;
    //批次号
    private  String seqnum = NULLSTR;
    //当前业务编号
    private  String ownref = NULLSTR;
    //列表个数
    private  long invlstcount;
    //占用总金额
    private BigDecimal totalamountin = Decimals.ZERO_SCALE3;
    //业务金额
    private  BigDecimal docamt = Decimals.ZERO_SCALE3;
    //发票数据
    private List<InvlstVo> invdatstm;
    //接口开关
    private  String interfaceflg = NULLSTR;
    //核验列表中的发票代码和发票号码
    private  List<String> successstm;
    //监控到期时'
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date expdat;
    //价税合计总金额
    private  BigDecimal totalamounttax = Decimals.ZERO_SCALE3;
    //跳过核验
    private  String skipped = NULLSTR;
    //跳过理由
    private  String skpreason = NULLSTR;
    //发票来源
    private  String frmflg = NULLSTR;
    //XMLPanel invdetailp的内置block
    private  String invdetailpblk = NULLSTR;

    private List<Invuse> invlst;

    //发票列表索引
    private int index;

    private Invrep invrep;

    private InvcrlVo invcrl;

    @Override
    public void reset() {
        super.reset();
        if (invrep == null) {
            invrep = new Invrep();
        }
        invrep.reset();
        if (invcrl == null) {
            invcrl = new InvcrlVo();
        }
        invcrl.reset();
    }
}
