using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Newtonsoft.Json;
using NPoco;
using POSV.Entity;
namespace POSV.ShoppingCart
{
[Serializable]
[JsonObject(MemberSerialization.OptIn)]
[TableName("pos_order_delivery")]
[PrimaryKey(new string[] { "id" } , AutoIncrement = false)]
public class OrderDelivery : BaseEntity
{
///
/// 租户ID
///
[JsonProperty(PropertyName = "tenantId")]
[Column("tenantId")]
public string TenantId { get; set; }
///
/// 随机单号
///
[JsonProperty(PropertyName = "orderId")]
[Column("orderId")]
public string OrderId { get; set; }
///
/// 单据编号
///
[JsonProperty(PropertyName = "tradeNo")]
[Column("tradeNo")]
public string TradeNo { get; set; }
///
/// 班次编号
///
[JsonProperty(PropertyName = "shiftNo")]
[Column("shiftNo")]
public string ShiftNo { get; set; }
///
/// 班次名称
///
[JsonProperty(PropertyName = "shiftName")]
[Column("shiftName")]
public string ShiftName { get; set; }
///
/// 订餐人ID
///
[JsonProperty(PropertyName = "visitorId")]
[Column("visitorId")]
public string VisitorId { get; set; }
///
/// 订餐人姓名
///
[JsonProperty(PropertyName = "visitorName")]
[Column("visitorName")]
public string VisitorName { get; set; }
///
/// 订餐人电话
///
[JsonProperty(PropertyName = "visitorTelephone")]
[Column("visitorTelephone")]
public string VisitorTelephone { get; set; }
///
/// 就餐人数
///
[JsonProperty(PropertyName = "peoples")]
[Column("peoples")]
public int Peoples { get; set; }
///
/// 订餐人地址ID
///
[JsonProperty(PropertyName = "addressId")]
[Column("addressId")]
public string AddressId { get; set; }
///
/// 订餐人地址
///
[JsonProperty(PropertyName = "address")]
[Column("address")]
public string Address { get; set; }
///
/// 收货人
///
[JsonProperty(PropertyName = "customer")]
[Column("customer")]
public string Customer { get; set; }
///
/// 收货人电话
///
[JsonProperty(PropertyName = "telephone")]
[Column("telephone")]
public string Telephone { get; set; }
///
/// 期望送达时间
///
[JsonProperty(PropertyName = "expectDate")]
[Column("expectDate")]
public string ExpectDate { get; set; }
///
/// 送餐员ID
///
[JsonProperty(PropertyName = "workerId")]
[Column("workerId")]
public string WorkerId { get; set; }
///
/// 送餐员编号
///
[JsonProperty(PropertyName = "workerNo")]
[Column("workerNo")]
public string WorkerNo { get; set; }
///
/// 送餐员姓名
///
[JsonProperty(PropertyName = "workerName")]
[Column("workerName")]
public string WorkerName { get; set; }
///
/// 预支金额
///
[JsonProperty(PropertyName = "advanceAmount")]
[Column("advanceAmount")]
public decimal AdvanceAmount { get; set; } = 0;
///
/// 加收服务费
///
[JsonProperty(PropertyName = "distributionFee")]
[Column("distributionFee")]
public decimal DistributionFee { get; set; } = 0;
///
/// 送出时间
///
[JsonProperty(PropertyName = "sendDate")]
[Column("sendDate")]
public string SendDate { get; set; }
///
/// 交账结算时间
///
[JsonProperty(PropertyName = "settlementDate")]
[Column("settlementDate")]
public string SettlementDate { get; set; }
///
/// 备注说明
///
[JsonProperty(PropertyName = "description")]
[Column("description")]
public string Description { get; set; }
///
/// 外送单状态 0-新建未配送,1-已配送,2-已交单
///
[JsonProperty(PropertyName = "status")]
[Column("status")]
public int Status { get; set; } = 0;
///
/// 状态描述
///
[JsonIgnore]
[Ignore]
public string StatusStr { get; set; }
///
/// 订单完成时间(格式:yyyy-MM-dd HH:mm:ss)
///
[JsonProperty(PropertyName = "finishDate")]
[Column("finishDate")]
public string FinishDate { get; set; } = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
///
/// 金额合计
///
[JsonIgnore]
[Ignore]
public decimal Amount { get; set; }
///
/// 扩展字段1
///
[JsonProperty(PropertyName = "ext1")]
[Column("ext1")]
public string Ext1 { get; set; }
///
/// 扩展字段2
///
[JsonProperty(PropertyName = "ext2")]
[Column("ext2")]
public string Ext2 { get; set; }
///
/// 扩展字段3
///
[JsonProperty(PropertyName = "ext3")]
[Column("ext3")]
public string Ext3 { get; set; }
}
}