using Newtonsoft.Json; using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace POSV.Entity.Pormotion { [Serializable] [JsonObject(MemberSerialization.OptIn)] public class ElectronCoupon { /// /// 租户编码 /// [JsonProperty(PropertyName = "tenantId")] public string TenantId { get; set; } /// /// 卡券主键id /// [JsonProperty(PropertyName = "couponId")] public string CouponId { get; set; } /// /// 微信一类卡券的唯一标识 /// [JsonProperty(PropertyName = "cardId")] public string CardId { get; set; } /// /// 卡券类别(折扣券:DISCOUNT;代金券:CASH;兑换券:GIFT) /// [JsonProperty(PropertyName = "cardType")] public MemberCouponType CardType { get; set; } /// /// 卡券标题 /// [JsonProperty(PropertyName = "title")] public string Title { get; set; } /// /// 卡券副标题 /// [JsonProperty(PropertyName = "subTitle")] public string SubTitle { get; set; } /// /// 卡券code码,唯一码 /// [JsonProperty(PropertyName = "code")] public string Code { get; set; } /// /// 卡券有效开始时间(yyyy-MM-dd HH:mm:ss) /// [JsonProperty(PropertyName = "beginTimestamp")] public string BeginTimestamp { get; set; } /// /// 卡券有效结束时间(yyyy-MM-dd HH:mm:ss) /// [JsonProperty(PropertyName = "endTimestamp")] public string EndTimestamp { get; set; } /// /// 卡券时段类型(0-表示不限制,1-表示限制) /// [JsonProperty(PropertyName = "limitType")] public int LimitType { get; set; } /// /// 卡券可用时段(周一:MONDAY,周二:TUESDAY,周三:WEDNESDAY,周四:THURSDAY,周五:FRIDAY,周六:SATURDAY,周日:SUNDAY) /// [JsonProperty(PropertyName = "timeLimit")] public string TimeLimit { get; set; } /// /// 起用金额(代金券专用,单位:分) /// [JsonProperty(PropertyName = "leastCost")] public int LeastCost { get; set; } /// /// 减免金额(代金券专用,单位:分) /// [JsonProperty(PropertyName = "reduceCost")] public int ReduceCost { get; set; } /// /// 打折额度(折扣券专用 1-9.9之间) /// [JsonProperty(PropertyName = "discount")] public decimal Discount { get; set; } /// /// 赠送类别(1-礼品 2-商品) /// [JsonProperty(PropertyName = "giftType")] public int GiftType { get; set; } /// /// 发放方式(1-pos核销 2-总部配送) /// [JsonProperty(PropertyName = "grantType")] public int GrantType { get; set; } /// /// 兑换物品信息 /// [JsonProperty(PropertyName = "gift")] public string Gift { get; set; } /// /// 领取会员ID /// [JsonProperty(PropertyName = "memberId")] public string MemberId { get; set; } /// /// 领取卡号 /// [JsonProperty(PropertyName = "cardNo")] public string CardNo { get; set; } /// /// 领取人手机号 /// [JsonProperty(PropertyName = "mobile")] public string Mobile { get; set; } /// /// 领取时间(yyyy-MM-dd HH:mm:ss) /// [JsonProperty(PropertyName = "receiveTime")] public string ReceiveTime { get; set; } /// /// 核销时间(yyyy-MM-dd HH:mm:ss) /// [JsonProperty(PropertyName = "consumeTime")] public string ConsumeTime { get; set; } /// /// 状态(0-当前门店不可用 1-当前门店可用) /// [JsonProperty(PropertyName = "useFlag")] public int UseFlag { get; set; } /// /// 状态(1-领取 2-已核销 3-已失效) /// [JsonProperty(PropertyName = "status")] public int Status { get; set; } /// /// 不可用类型 /// [JsonIgnore] public int ErrorType { get; set; } /// /// 不可用描述 /// [JsonIgnore] public string ErrorInfo { get; set; } /// /// 实际抵扣金额 /// [JsonProperty(PropertyName = "realMoney")] public decimal RealMoney { get; set; } } /// /// 礼品信息 /// [Serializable] [JsonObject(MemberSerialization.OptIn)] public class CouponGift { /// /// 物品兑换数量 /// [JsonProperty(PropertyName = "num")] public decimal Num { get; set; } /// /// 物品编码 /// [JsonProperty(PropertyName = "no")] public string No { get; set; } /// /// 物品名称 /// [JsonProperty(PropertyName = "name")] public string Name { get; set; } /// /// 物品条码 /// [JsonProperty(PropertyName = "barcode")] public string Barcode { get; set; } /// /// 物品规格 /// [JsonProperty(PropertyName = "spec")] public string Spec { get; set; } /// /// 物品单位 /// [JsonProperty(PropertyName = "unit")] public string Unit { get; set; } /// /// 物品价值 /// [JsonProperty(PropertyName = "worth")] public decimal Worth { get; set; } /// /// 物品成本 /// [JsonProperty(PropertyName = "cost")] public decimal Cost { get; set; } /// /// 备注 /// [JsonProperty(PropertyName = "memo")] public string Memo { get; set; } } /// /// 礼品信息 /// [Serializable] [JsonObject(MemberSerialization.OptIn)] public class CouponProductGift { /// /// 物品兑换数量 /// [JsonProperty(PropertyName = "num")] public decimal Num { get; set; } /// /// 物品编码 /// [JsonProperty(PropertyName = "specId")] public string SpecId { get; set; } /// /// 商品ID /// [JsonProperty(PropertyName = "productId")] public string ProductId { get; set; } /// /// 商品编号 /// [JsonProperty(PropertyName = "productNo")] public string ProductNo { get; set; } /// /// 商品名称 /// [JsonProperty(PropertyName = "productName")] public string ProductName { get; set; } /// /// 规格名称 /// [JsonProperty(PropertyName = "specName")] public string SpecName { get; set; } /// /// 商品单位 /// [JsonProperty(PropertyName = "unitName")] public string UnitName { get; set; } } /// /// 会员券类型 /// public enum MemberCouponType { //折扣券 DISCOUNT = 0, //代金券 CASH = 1, //兑换券 GIFT = 2, //单品券 PRODUCT = 3, } }