Просмотр исходного кода

添加广电卡类型三元判断

DuGuYang 2 лет назад
Родитель
Сommit
abac4b9aa9
1 измененных файлов с 2 добавлено и 0 удалено
  1. 2 0
      AppStart/ExcelHelper.cs

+ 2 - 0
AppStart/ExcelHelper.cs

@@ -73,6 +73,7 @@ namespace MySystem
                                     if (machinefor == null)
                                     if (machinefor == null)
                                     {
                                     {
                                         int BrandId = int.Parse(function.CheckInt(BrandIdString));
                                         int BrandId = int.Parse(function.CheckInt(BrandIdString));
+                                        int CardType = BrandId == 14 ? 2 : 0;
                                         KqProducts kqProduct = db.KqProducts.FirstOrDefault(m => m.Id == BrandId) ?? new KqProducts();
                                         KqProducts kqProduct = db.KqProducts.FirstOrDefault(m => m.Id == BrandId) ?? new KqProducts();
                                         if (kqProduct.Id > 0)
                                         if (kqProduct.Id > 0)
                                         {
                                         {
@@ -89,6 +90,7 @@ namespace MySystem
                                                 DeviceName = DeviceName,
                                                 DeviceName = DeviceName,
                                                 DeviceKind = DeviceKind,
                                                 DeviceKind = DeviceKind,
                                                 SourceStoreId = storefor.StoreId, //源仓库
                                                 SourceStoreId = storefor.StoreId, //源仓库
+                                                CardType = CardType,
                                             }).Entity;
                                             }).Entity;
                                             store.ProductName = kqProduct.Name;
                                             store.ProductName = kqProduct.Name;
                                             store.BrandId = BrandId.ToString();
                                             store.BrandId = BrandId.ToString();