package com.uas.platform.b2b.mobile.model;

import java.util.Date;

import com.uas.platform.b2b.model.PurchaseNotice;

/**
 * 移动端接口，平台里面，以供应商的角度来查看客户送货提醒
 * 
 * @author suntg
 *
 */
public class Notice{

	private Long id;

	/**
	 * 录入日期
	 */
	private Date date;

	/**
	 * 数量
	 */
	private Double qty;

	/**
	 * 已发货数
	 */
	private Double endQty;

	/**
	 * 交货日期
	 */
	private Date delivery;

	/**
	 * 备注
	 */
	private String remark;

	/**
	 * 处理状态（已回复、未回复），全部发货后改为已回复
	 */
	private Short status;

	/**
	 * 单位
	 */
	private String unit;

	/**
	 * 物料编号
	 */
	private String productCode;

	/**
	 * 物料名称
	 */
	private String productTitle;

	/**
	 * 物料规格
	 */
	private String productSpec;

	/**
	 * 单据数量
	 */
	private Double orderQty;

	/**
	 * 单据编号
	 */
	private String orderCode;

	/**
	 * 单据行号
	 */
	private Short orderNumber;

	/**
	 * 客户名称
	 */
	private String customerName;

	/**
	 * 采购员名字
	 */
	private String buyerName;

	/**
	 * 采购员电话号码
	 */
	private String buyerTel;

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Date getDate() {
		return date;
	}

	public void setDate(Date date) {
		this.date = date;
	}

	public Double getQty() {
		return qty;
	}

	public void setQty(Double qty) {
		this.qty = qty;
	}

	public Double getEndQty() {
		return endQty;
	}

	public void setEndQty(Double endQty) {
		this.endQty = endQty;
	}

	public Date getDelivery() {
		return delivery;
	}

	public void setDelivery(Date delivery) {
		this.delivery = delivery;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public Short getStatus() {
		return status;
	}

	public void setStatus(Short status) {
		this.status = status;
	}

	public String getUnit() {
		return unit;
	}

	public void setUnit(String unit) {
		this.unit = unit;
	}

	public String getProductCode() {
		return productCode;
	}

	public void setProductCode(String productCode) {
		this.productCode = productCode;
	}

	public String getProductTitle() {
		return productTitle;
	}

	public void setProductTitle(String productTitle) {
		this.productTitle = productTitle;
	}

	public String getProductSpec() {
		return productSpec;
	}

	public void setProductSpec(String productSpec) {
		this.productSpec = productSpec;
	}

	public Double getOrderQty() {
		return orderQty;
	}

	public void setOrderQty(Double orderQty) {
		this.orderQty = orderQty;
	}

	public String getOrderCode() {
		return orderCode;
	}

	public void setOrderCode(String orderCode) {
		this.orderCode = orderCode;
	}

	public Short getOrderNumber() {
		return orderNumber;
	}

	public void setOrderNumber(Short orderNumber) {
		this.orderNumber = orderNumber;
	}

	public String getCustomerName() {
		return customerName;
	}

	public void setCustomerName(String customerName) {
		this.customerName = customerName;
	}

	public String getBuyerName() {
		return buyerName;
	}

	public void setBuyerName(String buyerName) {
		this.buyerName = buyerName;
	}

	public String getBuyerTel() {
		return buyerTel;
	}

	public void setBuyerTel(String buyerTel) {
		this.buyerTel = buyerTel;
	}

	public Notice(PurchaseNotice notice){
		this.id = notice.getId();
		this.buyerName = notice.getOrderItem().getOrder().getUser().getUserName();
		this.buyerTel = notice.getOrderItem().getOrder().getUser().getUserTel();
		this.customerName = notice.getOrderItem().getOrder().getEnterprise().getEnName();
		this.date = notice.getDate();
		this.delivery = notice.getDelivery();
		this.endQty = notice.getEndQty();
		this.orderCode = notice.getOrderItem().getOrder().getCode();
		this.orderNumber = notice.getOrderItem().getNumber();
		this.orderQty = notice.getOrderItem().getQty();
		this.productCode = notice.getOrderItem().getProduct().getCode();
		this.productSpec = notice.getOrderItem().getProduct().getSpec();
		this.productTitle = notice.getOrderItem().getProduct().getTitle();
		this.qty = notice.getQty();
		this.remark = notice.getRemark();
		this.status = notice.getStatus();
		this.unit = notice.getOrderItem().getProduct().getUnit();
	}
	

}