package com.brilliance.isc.bo;

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

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

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

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

    //INR of BR Contract
    private String inr = NULLSTR;

    //Own Reference BR Number
    private String ownref = NULLSTR;

    //Name of Bill Contract
    private String nam = NULLSTR;

    //Resp. User
    private String ownusr = NULLSTR;

    //Date of Creation
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date credat = NULLDATE;

    //Date of Opening
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date opndat = NULLDATE;

    //Date Closed
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date clsdat = NULLDATE;

    //Parent Contract Type
    private String pnttyp = NULLSTR;

    //Parent Contract INR
    private String pntinr = NULLSTR;

    //Presentation Date
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date predat = NULLDATE;

    //Date of Shipment
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date shpdat = NULLDATE;

    //Start Past-due Date
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date spddat = NULLDATE;

    //Date to be Paid
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date totdat = NULLDATE;

    //Date of Advice of Payment
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date advdat = NULLDATE;

    //Maturity Date
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date matdat = NULLDATE;

    //Date of Receipt of Documents
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date rcvdat = NULLDATE;

    //Date of Discrepancy Advice
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date disdat = NULLDATE;

    //Usance, Sight or Mixed
    private String docflg = NULLSTR;

    //Reject Flag
    private String rejflg = NULLSTR;

    //Documents on Approval Basis
    private String approvcod = NULLSTR;

    //Release of Goods
    private String relgodflg = NULLSTR;

    //Request Date for Release of Goods
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date relgoddat = NULLDATE;

    //Transport Document Number
    private String trpdocnum = NULLSTR;

    //Free of Payment Flag
    private String frepayflg = NULLSTR;

    //Version
    private String ver = NULLSTR;

    //Type of Advice Received
    private String advtyp = NULLSTR;

    //Release Type
    private String reltyp = NULLSTR;

    //Expiry Date of Shipping Guarantee
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date expdat = NULLDATE;

    //Release Goods to Applicant ?
    private String rtoaplflg = NULLSTR;

    //Transport Document Type
    private String trpdoctyp = NULLSTR;

    //Date of Transport Document
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date tradat = NULLDATE;

    //Mode of Transport
    private String tramod = NULLSTR;

    //Multiple Tenor Flag
    private String mattxtflg = NULLSTR;

    //Enter Docs, Discrep. and Instructions
    private String dscinsflg = NULLSTR;

    //Presented by
    private String docprbrol = NULLSTR;

    //Document Set Status
    private String docsta = NULLSTR;

    //Ignore Discrepancies
    private String igndisflg = NULLSTR;

    //Currency of Total Amount to be Paid
    private String totcur = NULLSTR;

    //Total Amount to be Paid
    private BigDecimal totamt  = Decimals.ZERO_SCALE3;

    //Payer
    private String payrol = NULLSTR;

    //Accept Documents now
    private String acpnowflg = NULLSTR;

    //Order Date
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date orddat = NULLDATE;

    //Return of Documents
    private String advdocflg = NULLSTR;

    //Entity holding Contract
    private String etyextkey = NULLSTR;

    //BRANCH CODE KEYINR
    private String bchkeyinr = NULLSTR;

    //BRANCHINR
    private String branchinr = NULLSTR;

    //Goods code
    private String ngrcod = NULLSTR;

    //Shipping Guarrantte INR Only used by Data migration
    private String sgdinr = NULLSTR;

    //B/L Number
    private String blnum = NULLSTR;

    //Shipping Guarantee Reference
    private String shgref = NULLSTR;

    //Mortgage Flag
    private String guaflg = NULLSTR;

    //Tenor day
    private  int tenmaxday ;

    //Start Date
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date stadat = NULLDATE;

    //合同号
    private String rptref = NULLSTR;

    //发票号
    private String invref = NULLSTR;

    //预计核验日期
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date prechkdat = NULLDATE;

    //是否需要核验
    private String ischktyp = NULLSTR;

    //发票类型
    private String invtyp = NULLSTR;

    //快递单号
    private String expmno = NULLSTR;

    //议付标志
    private String negflg = NULLSTR;

    //追�'�权
    private String rcssta = NULLSTR;

    //付款类型
    private String paytyp = NULLSTR;

    //清算方式
    private String clrmtd = NULLSTR;

    //单据处理类型
    private String bilpro = NULLSTR;

    //寄单�'�款编号
    private String sndref = NULLSTR;

    //交单批注行行号
    private String anobnkcod = NULLSTR;

    //交单批注日期
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date anodat = NULLDATE;

    //交单批注描述
    private String anodsp = NULLSTR;

    //收款银行�'�号
    private String skzh = NULLSTR;

    //收款银行�'�户名称
    private String skmc = NULLSTR;

    //收款银行开户行行号
    private String skhhh = NULLSTR;

    //收款银行开户行名称
    private String skhmc = NULLSTR;

    //付款账号
    private String fkzh = NULLSTR;

    //付款人名称
    private String fkmc = NULLSTR;

    //付款行开户行行号
    private String fkhhh = NULLSTR;

    //付款银行开户行名称
    private String fkhmc = NULLSTR;

    //原始单据金额，用于录入原始发票的合计金额
    private  BigDecimal invamt  = Decimals.ZERO_SCALE2;
}
