package com.zfire.mall.manager.bean.k3.bill;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.List;

@EqualsAndHashCode(callSuper = true)
@ApiModel
@Data
@JsonIgnoreProperties(value = { "isPushUpdate" })
public class SalesOutStockBean extends CommonOrderBean {

    /**
     * id
     */
    @JsonProperty("FID")
    @ApiModelProperty(value = "下游单据内码id")
    private String id;

    /**
     * 日期
     */
    @JsonProperty("FDate")
    @ApiModelProperty(value = "日期")
    private String date;

    /**
     * 备注
     */
    @JsonProperty("F_abcd_Remarks")
    private String remarks;

    /**
     * 出库明细
     */
    @JsonProperty("FEntity")
    @ApiModelProperty(value = "明细")
    private List<SalesOutStockItemBean> entry;

    @ApiModelProperty(value = "是否下推更新")
    private boolean isPushUpdate = true;

    @Override
    public boolean isPushUpdate() {
        return isPushUpdate;
    }

    @Override
    public String[] pushUpdateFields() {
        return new String[]{"FDATE", "FBillNo", "F_abcd_Remarks", "FEntity", "FUnitID", "FMustqty", "FRealQty", "FStockId","F_kls_Text1","F_kls_Text2","F_kls_Base"};
    }
}
