浏览代码

添加父级商户ID

lcl 4 月之前
父节点
当前提交
2c0b5baa6e

+ 3 - 0
Areas/Api/Controllers/Main/MerchantAddInfoController.cs

@@ -258,12 +258,15 @@ namespace MySystem.Areas.Api.Controllers.v1
                 {
                     Dictionary<string, object> Fiel = new Dictionary<string, object>();
                     Fiel.Add("CertMerchantName", CertMerchantName);
+                    int ParentId = MerchantAddInfoId;
                     Fiel.Add("OutMchtNo", MerchantAddInfoService.Query(MerchantAddInfoId).OutMchtNo); //费率
+                    Fiel.Add("ParentId", ParentId);
                     MerchantAddInfoId = (int)MerchantAddInfoService.Add(Fiel, false).Data;
 
                     Fiel = new Dictionary<string, object>();
                     Fiel.Add("Id", MerchantAddInfoId);
                     Fiel.Add("UserId", UserId);
+                    Fiel.Add("ParentId", ParentId);
                     Fiel.Add("Name", CertMerchantName);
                     MerchantInfoService.Add(Fiel, false);
                 }

+ 2 - 0
Areas/Api/Controllers/Main/MerchantInfoController.cs

@@ -145,6 +145,7 @@ namespace MySystem.Areas.Api.Controllers.v1
             Obj.Add("Status", addInfo.Status);
             Obj.Add("AuditResult", AuditResult); //审核结果
             Obj.Add("SubjectType", addInfo.SubjectType);
+            Obj.Add("ParentId", addInfo.ParentId); //父级商户ID
             return Obj;
         }
         #endregion
@@ -404,6 +405,7 @@ namespace MySystem.Areas.Api.Controllers.v1
             Obj.Add("ActivationStatus", merchant.ActivationStatus); //达标状态
             Obj.Add("IsAct", merchant.IsAct); //是否激活(0 否 1 是)
             Obj.Add("SettleFee", addinfo.FeeRate);
+            Obj.Add("ParentId", addinfo.ParentId); //父级商户ID
             if (merchant.IsAct == 1)
             {
                 var orderInfo = MerchantDepositOrderService.Query(" 1=1 and Status>0 and MerchantId=" + Id + "");

+ 2 - 0
Models/Main/MerchantAddInfo.cs

@@ -152,5 +152,7 @@ namespace MySystem.Models.Main
         public int BrandId { get; set; }
         public string CybMakerCode { get; set; }
         public string FeeRate { get; set; }
+        public int ParentId { get; set; }
+        public string AgentName { get; set; }
     }
 }

+ 1 - 0
Models/Main/MerchantInfo.cs

@@ -57,5 +57,6 @@ namespace MySystem.Models.Main
         public decimal Longitude { get; set; }
         public int BrandId { get; set; }
         public string CybMakerCode { get; set; }
+        public int ParentId { get; set; }
     }
 }

+ 14 - 0
Models/Main/WebCMSEntities.cs

@@ -5540,6 +5540,12 @@ namespace MySystem.Models.Main
                     .HasCharSet("utf8")
                     .HasCollation("utf8_general_ci");
 
+                entity.Property(e => e.AgentName)
+                    .HasColumnType("varchar(50)")
+                    .HasComment("好哒机构")
+                    .HasCharSet("utf8")
+                    .HasCollation("utf8_general_ci");
+
                 entity.Property(e => e.AgentProtocol)
                     .HasColumnName("agentProtocol")
                     .HasColumnType("varchar(200)")
@@ -5989,6 +5995,10 @@ namespace MySystem.Models.Main
                     .HasColumnType("bit(1)")
                     .HasDefaultValueSql("b'0'");
 
+                entity.Property(e => e.ParentId)
+                    .HasColumnType("int(11)")
+                    .HasComment("父级ID");
+
                 entity.Property(e => e.PeriodBegin).HasColumnType("datetime");
 
                 entity.Property(e => e.PeriodEnd).HasColumnType("datetime");
@@ -7367,6 +7377,10 @@ namespace MySystem.Models.Main
                     .HasCharSet("utf8")
                     .HasCollation("utf8_general_ci");
 
+                entity.Property(e => e.ParentId)
+                    .HasColumnType("int(11)")
+                    .HasComment("父级ID");
+
                 entity.Property(e => e.ParentUserNav)
                     .HasColumnType("varchar(500)")
                     .HasCharSet("utf8")