Subversion Repositories SmartDukaan

Rev

Blame | Last modification | View Log | RSS feed

package com.spice.profitmandi.dao.model;

/**
 * Transfer price for a billed order, taken from the vendor catalog pricing of the external supplier the billed
 * stock was most recently purchased from.
 */
public class BillingPriceModel {

    /** Price of the stock's external supplier. */
    public static final String SOURCE_EXTERNAL_ORIGIN = "EXTERNAL_ORIGIN";
    /**
     * No external supplier could be traced for the billed stock (or it has no pricing for the catalog), so the
     * latest externally approved price for the catalog is used. Inferred - never recorded as the vendor.
     */
    public static final String SOURCE_CATALOG_FALLBACK = "CATALOG_FALLBACK";

    private int orderId;
    /** External supplier of the billed stock, or 0 when it could not be traced. */
    private int originVendorId;
    private float transferPrice;
    private String source;

    public int getOrderId() {
        return orderId;
    }

    public void setOrderId(int orderId) {
        this.orderId = orderId;
    }

    public int getOriginVendorId() {
        return originVendorId;
    }

    public void setOriginVendorId(int originVendorId) {
        this.originVendorId = originVendorId;
    }

    public float getTransferPrice() {
        return transferPrice;
    }

    public void setTransferPrice(float transferPrice) {
        this.transferPrice = transferPrice;
    }

    public String getSource() {
        return source;
    }

    public void setSource(String source) {
        this.source = source;
    }

    @Override
    public String toString() {
        return "BillingPriceModel{" +
                "orderId=" + orderId +
                ", originVendorId=" + originVendorId +
                ", transferPrice=" + transferPrice +
                ", source='" + source + '\'' +
                '}';
    }
}