浏览代码

保存盒子押金记录

lichunlei 1 年之前
父节点
当前提交
ba435e59da

+ 10 - 0
AppStart/Helper/SycnSpServer/SycnSpTradeService.cs

@@ -96,6 +96,16 @@ namespace MySystem
                                 if (pos != null)
                                 if (pos != null)
                                 {
                                 {
                                     pos.SeoKeyword = trade.TradeAmount.ToString("f2");
                                     pos.SeoKeyword = trade.TradeAmount.ToString("f2");
+                                    PxcModels.PosMerchantInfo merchant = db.PosMerchantInfo.FirstOrDefault(m => m.Id == pos.BindMerchantId) ?? new PxcModels.PosMerchantInfo();
+                                    db.MerchantDepositRecord.Add(new PxcModels.MerchantDepositRecord()
+                                    {
+                                        CreateDate = DateTime.Now,
+                                        SnNo = pos.PosSn,
+                                        MerNo = merchant.KqMerNo,
+                                        DepositAmount = trade.TradeAmount,
+                                        UserId = pos.BuyUserId,
+                                        OrderId = DateTime.Now.ToString("yyyyMMddHHmmssfff") + function.get_Random(8),
+                                    });
                                     db.SaveChanges();
                                     db.SaveChanges();
                                 }
                                 }
                                 TradeRecord edit = spdb.TradeRecord.FirstOrDefault(m => m.Id == trade.Id);
                                 TradeRecord edit = spdb.TradeRecord.FirstOrDefault(m => m.Id == trade.Id);

+ 1 - 0
PxcModels/MachineChangeDetail.cs

@@ -30,5 +30,6 @@ namespace MySystem.PxcModels
         public int BackProductType { get; set; }
         public int BackProductType { get; set; }
         public int ChangeId { get; set; }
         public int ChangeId { get; set; }
         public string ChangeNo { get; set; }
         public string ChangeNo { get; set; }
+        public ulong NoticeFlag { get; set; }
     }
     }
 }
 }

+ 1 - 0
PxcModels/MachineUnBind.cs

@@ -22,5 +22,6 @@ namespace MySystem.PxcModels
         public int BrandId { get; set; }
         public int BrandId { get; set; }
         public int UserId { get; set; }
         public int UserId { get; set; }
         public string ApplyNo { get; set; }
         public string ApplyNo { get; set; }
+        public ulong NoticeFlag { get; set; }
     }
     }
 }
 }

+ 27 - 0
PxcModels/MerchantDepositRecord.cs

@@ -0,0 +1,27 @@
+using System;
+using System.Collections.Generic;
+
+namespace MySystem.PxcModels
+{
+    public partial class MerchantDepositRecord
+    {
+        public int Id { get; set; }
+        public int Sort { get; set; }
+        public int QueryCount { get; set; }
+        public int Status { get; set; }
+        public int Version { get; set; }
+        public DateTime? CreateDate { get; set; }
+        public DateTime? UpdateDate { get; set; }
+        public string CreateMan { get; set; }
+        public string UpdateMan { get; set; }
+        public string SeoTitle { get; set; }
+        public string SeoKeyword { get; set; }
+        public string SeoDescription { get; set; }
+        public ulong NoticeFlag { get; set; }
+        public string OrderId { get; set; }
+        public int UserId { get; set; }
+        public decimal DepositAmount { get; set; }
+        public string MerNo { get; set; }
+        public string SnNo { get; set; }
+    }
+}

+ 1 - 0
PxcModels/ToChargeBackRecord.cs

@@ -22,5 +22,6 @@ namespace MySystem.PxcModels
         public decimal TotalAmount { get; set; }
         public decimal TotalAmount { get; set; }
         public int TimeNumber { get; set; }
         public int TimeNumber { get; set; }
         public DateTime? StartDate { get; set; }
         public DateTime? StartDate { get; set; }
+        public int Kind { get; set; }
     }
     }
 }
 }

+ 1 - 0
PxcModels/ToChargeBackRecordSub.cs

@@ -19,5 +19,6 @@ namespace MySystem.PxcModels
         public string Remark { get; set; }
         public string Remark { get; set; }
         public decimal ChargeAmount { get; set; }
         public decimal ChargeAmount { get; set; }
         public int ParentId { get; set; }
         public int ParentId { get; set; }
+        public int Kind { get; set; }
     }
     }
 }
 }

+ 1 - 0
PxcModels/ToChargeByStage.cs

@@ -20,5 +20,6 @@ namespace MySystem.PxcModels
         public string Remark { get; set; }
         public string Remark { get; set; }
         public decimal ChargeAmount { get; set; }
         public decimal ChargeAmount { get; set; }
         public int UserId { get; set; }
         public int UserId { get; set; }
+        public int Kind { get; set; }
     }
     }
 }
 }

+ 2 - 0
PxcModels/UserAccount.cs

@@ -46,5 +46,7 @@ namespace MySystem.PxcModels
         public decimal PreTempAmountForBalance { get; set; }
         public decimal PreTempAmountForBalance { get; set; }
         public decimal PreTempAmount { get; set; }
         public decimal PreTempAmount { get; set; }
         public decimal ToChargeAmount { get; set; }
         public decimal ToChargeAmount { get; set; }
+        public decimal LeaderToChargeAmount { get; set; }
+        public decimal OperateToChargeAmount { get; set; }
     }
     }
 }
 }

+ 123 - 0
PxcModels/WebCMSEntities.cs

@@ -101,6 +101,7 @@ namespace MySystem.PxcModels
         public virtual DbSet<MerchantClass> MerchantClass { get; set; }
         public virtual DbSet<MerchantClass> MerchantClass { get; set; }
         public virtual DbSet<MerchantCol> MerchantCol { get; set; }
         public virtual DbSet<MerchantCol> MerchantCol { get; set; }
         public virtual DbSet<MerchantComment> MerchantComment { get; set; }
         public virtual DbSet<MerchantComment> MerchantComment { get; set; }
+        public virtual DbSet<MerchantDepositRecord> MerchantDepositRecord { get; set; }
         public virtual DbSet<MerchantDepositReturns> MerchantDepositReturns { get; set; }
         public virtual DbSet<MerchantDepositReturns> MerchantDepositReturns { get; set; }
         public virtual DbSet<MerchantDepositSet> MerchantDepositSet { get; set; }
         public virtual DbSet<MerchantDepositSet> MerchantDepositSet { get; set; }
         public virtual DbSet<MerchantForCode> MerchantForCode { get; set; }
         public virtual DbSet<MerchantForCode> MerchantForCode { get; set; }
@@ -5635,6 +5636,11 @@ namespace MySystem.PxcModels
                     .HasCharSet("utf8")
                     .HasCharSet("utf8")
                     .HasCollation("utf8_general_ci");
                     .HasCollation("utf8_general_ci");
 
 
+                entity.Property(e => e.NoticeFlag)
+                    .HasColumnType("bit(1)")
+                    .HasDefaultValueSql("b'0'")
+                    .HasComment("推送标记");
+
                 entity.Property(e => e.OutProductName)
                 entity.Property(e => e.OutProductName)
                     .HasColumnType("varchar(32)")
                     .HasColumnType("varchar(32)")
                     .HasCharSet("utf8")
                     .HasCharSet("utf8")
@@ -5934,6 +5940,11 @@ namespace MySystem.PxcModels
 
 
                 entity.Property(e => e.MerchantId).HasColumnType("int(11)");
                 entity.Property(e => e.MerchantId).HasColumnType("int(11)");
 
 
+                entity.Property(e => e.NoticeFlag)
+                    .HasColumnType("bit(1)")
+                    .HasDefaultValueSql("b'0'")
+                    .HasComment("推送标记");
+
                 entity.Property(e => e.QueryCount).HasColumnType("int(11)");
                 entity.Property(e => e.QueryCount).HasColumnType("int(11)");
 
 
                 entity.Property(e => e.SeoDescription)
                 entity.Property(e => e.SeoDescription)
@@ -6766,6 +6777,98 @@ namespace MySystem.PxcModels
                 entity.Property(e => e.Version).HasColumnType("int(11)");
                 entity.Property(e => e.Version).HasColumnType("int(11)");
             });
             });
 
 
+            modelBuilder.Entity<MerchantDepositRecord>(entity =>
+            {
+                entity.HasComment("商户押金记录");
+
+                entity.Property(e => e.Id).HasColumnType("int(11)");
+
+                entity.Property(e => e.CreateDate)
+                    .HasColumnType("datetime")
+                    .HasComment("创建时间");
+
+                entity.Property(e => e.CreateMan)
+                    .HasColumnType("varchar(50)")
+                    .HasComment("创建人")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
+                entity.Property(e => e.DepositAmount)
+                    .HasColumnType("decimal(18,2)")
+                    .HasComment("押金金额");
+
+                entity.Property(e => e.MerNo)
+                    .IsRequired()
+                    .HasColumnType("varchar(50)")
+                    .HasComment("商户编号")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
+                entity.Property(e => e.NoticeFlag)
+                    .HasColumnType("bit(1)")
+                    .HasDefaultValueSql("b'0'")
+                    .HasComment("推送标记");
+
+                entity.Property(e => e.OrderId)
+                    .IsRequired()
+                    .HasColumnType("varchar(50)")
+                    .HasComment("订单流水号")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
+                entity.Property(e => e.QueryCount)
+                    .HasColumnType("int(11)")
+                    .HasComment("点击量");
+
+                entity.Property(e => e.SeoDescription)
+                    .HasColumnType("varchar(500)")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
+                entity.Property(e => e.SeoKeyword)
+                    .HasColumnType("varchar(200)")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
+                entity.Property(e => e.SeoTitle)
+                    .HasColumnType("varchar(100)")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
+                entity.Property(e => e.SnNo)
+                    .IsRequired()
+                    .HasColumnType("varchar(50)")
+                    .HasComment("机具SN")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
+                entity.Property(e => e.Sort)
+                    .HasColumnType("int(11)")
+                    .HasComment("排序序号");
+
+                entity.Property(e => e.Status)
+                    .HasColumnType("int(11)")
+                    .HasComment("状态");
+
+                entity.Property(e => e.UpdateDate)
+                    .HasColumnType("datetime")
+                    .HasComment("更新时间");
+
+                entity.Property(e => e.UpdateMan)
+                    .HasColumnType("varchar(50)")
+                    .HasComment("更新人")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
+                entity.Property(e => e.UserId)
+                    .HasColumnType("int(11)")
+                    .HasComment("创客");
+
+                entity.Property(e => e.Version)
+                    .HasColumnType("int(11)")
+                    .HasComment("版本号");
+            });
+
             modelBuilder.Entity<MerchantDepositReturns>(entity =>
             modelBuilder.Entity<MerchantDepositReturns>(entity =>
             {
             {
                 entity.Property(e => e.Id).HasColumnType("int(11)");
                 entity.Property(e => e.Id).HasColumnType("int(11)");
@@ -16058,6 +16161,10 @@ namespace MySystem.PxcModels
                     .HasCharSet("utf8")
                     .HasCharSet("utf8")
                     .HasCollation("utf8_general_ci");
                     .HasCollation("utf8_general_ci");
 
 
+                entity.Property(e => e.Kind)
+                    .HasColumnType("int(11)")
+                    .HasComment("待扣类别");
+
                 entity.Property(e => e.QueryCount).HasColumnType("int(11)");
                 entity.Property(e => e.QueryCount).HasColumnType("int(11)");
 
 
                 entity.Property(e => e.Remark)
                 entity.Property(e => e.Remark)
@@ -16103,6 +16210,10 @@ namespace MySystem.PxcModels
 
 
                 entity.Property(e => e.CreateDate).HasColumnType("datetime");
                 entity.Property(e => e.CreateDate).HasColumnType("datetime");
 
 
+                entity.Property(e => e.Kind)
+                    .HasColumnType("int(11)")
+                    .HasComment("待扣类别");
+
                 entity.Property(e => e.ParentId).HasColumnType("int(11)");
                 entity.Property(e => e.ParentId).HasColumnType("int(11)");
 
 
                 entity.Property(e => e.QueryCount).HasColumnType("int(11)");
                 entity.Property(e => e.QueryCount).HasColumnType("int(11)");
@@ -16146,6 +16257,10 @@ namespace MySystem.PxcModels
 
 
                 entity.Property(e => e.CreateDate).HasColumnType("datetime");
                 entity.Property(e => e.CreateDate).HasColumnType("datetime");
 
 
+                entity.Property(e => e.Kind)
+                    .HasColumnType("int(11)")
+                    .HasComment("待扣类别");
+
                 entity.Property(e => e.QueryCount).HasColumnType("int(11)");
                 entity.Property(e => e.QueryCount).HasColumnType("int(11)");
 
 
                 entity.Property(e => e.Remark)
                 entity.Property(e => e.Remark)
@@ -16895,8 +17010,16 @@ namespace MySystem.PxcModels
 
 
                 entity.Property(e => e.LeaderReserve).HasColumnType("decimal(18,2)");
                 entity.Property(e => e.LeaderReserve).HasColumnType("decimal(18,2)");
 
 
+                entity.Property(e => e.LeaderToChargeAmount)
+                    .HasColumnType("decimal(18,2)")
+                    .HasComment("盟主待扣金额");
+
                 entity.Property(e => e.LockStatus).HasColumnType("int(11)");
                 entity.Property(e => e.LockStatus).HasColumnType("int(11)");
 
 
+                entity.Property(e => e.OperateToChargeAmount)
+                    .HasColumnType("decimal(18,2)")
+                    .HasComment("运营中心待扣金额");
+
                 entity.Property(e => e.PreTempAmount).HasColumnType("decimal(18,2)");
                 entity.Property(e => e.PreTempAmount).HasColumnType("decimal(18,2)");
 
 
                 entity.Property(e => e.PreTempAmountForBalance).HasColumnType("decimal(18,2)");
                 entity.Property(e => e.PreTempAmountForBalance).HasColumnType("decimal(18,2)");