|
@@ -460,6 +460,7 @@ namespace MySystem.Areas.Admin.Controllers
|
|
|
string SnNo = itemJson.Contains("\"A\"") ? dr["A"].ToString() : "";
|
|
string SnNo = itemJson.Contains("\"A\"") ? dr["A"].ToString() : "";
|
|
|
string Brand = itemJson.Contains("\"B\"") ? dr["B"].ToString() : "";
|
|
string Brand = itemJson.Contains("\"B\"") ? dr["B"].ToString() : "";
|
|
|
BrandId = Convert.ToInt32(Brand);
|
|
BrandId = Convert.ToInt32(Brand);
|
|
|
|
|
+
|
|
|
if (BrandId == 1) FromStoreId = 7;
|
|
if (BrandId == 1) FromStoreId = 7;
|
|
|
if (BrandId == 2) FromStoreId = 721;
|
|
if (BrandId == 2) FromStoreId = 721;
|
|
|
if (BrandId == 3) FromStoreId = 697;
|
|
if (BrandId == 3) FromStoreId = 697;
|
|
@@ -467,6 +468,8 @@ namespace MySystem.Areas.Admin.Controllers
|
|
|
if (BrandId == 5) FromStoreId = 775;
|
|
if (BrandId == 5) FromStoreId = 775;
|
|
|
if (BrandId == 6) FromStoreId = 871;
|
|
if (BrandId == 6) FromStoreId = 871;
|
|
|
if (BrandId == 7) FromStoreId = 1047;
|
|
if (BrandId == 7) FromStoreId = 1047;
|
|
|
|
|
+ if (BrandId == 8) FromStoreId = 4831;
|
|
|
|
|
+ if (BrandId == 9) FromStoreId = 4832;
|
|
|
PosMachinesTwo posMachinesTwo = db.PosMachinesTwo.FirstOrDefault(m => m.PosSn == SnNo && m.StoreId == FromStoreId);
|
|
PosMachinesTwo posMachinesTwo = db.PosMachinesTwo.FirstOrDefault(m => m.PosSn == SnNo && m.StoreId == FromStoreId);
|
|
|
if (posMachinesTwo == null)
|
|
if (posMachinesTwo == null)
|
|
|
{
|
|
{
|
|
@@ -497,6 +500,8 @@ namespace MySystem.Areas.Admin.Controllers
|
|
|
if (BrandId == 5) FromStoreId = 775;
|
|
if (BrandId == 5) FromStoreId = 775;
|
|
|
if (BrandId == 6) FromStoreId = 871;
|
|
if (BrandId == 6) FromStoreId = 871;
|
|
|
if (BrandId == 7) FromStoreId = 1047;
|
|
if (BrandId == 7) FromStoreId = 1047;
|
|
|
|
|
+ if (BrandId == 8) FromStoreId = 4831;
|
|
|
|
|
+ if (BrandId == 9) FromStoreId = 4832;
|
|
|
tostore = db.StoreHouse.FirstOrDefault(m => m.UserId == apply.UserId && m.BrandId == BrandId.ToString());
|
|
tostore = db.StoreHouse.FirstOrDefault(m => m.UserId == apply.UserId && m.BrandId == BrandId.ToString());
|
|
|
SendInfo item = sendInfos.FirstOrDefault(m => m.FromStoreId == FromStoreId && m.ToStoreId == tostore.Id && m.BrandId == BrandId);
|
|
SendInfo item = sendInfos.FirstOrDefault(m => m.FromStoreId == FromStoreId && m.ToStoreId == tostore.Id && m.BrandId == BrandId);
|
|
|
if (item == null)
|
|
if (item == null)
|
|
@@ -625,7 +630,8 @@ namespace MySystem.Areas.Admin.Controllers
|
|
|
UserAccount userAccount = db.UserAccount.FirstOrDefault(m => m.UserId == apply.UserId);
|
|
UserAccount userAccount = db.UserAccount.FirstOrDefault(m => m.UserId == apply.UserId);
|
|
|
var Amounts = Convert.ToUInt32(item.Num) * 300;
|
|
var Amounts = Convert.ToUInt32(item.Num) * 300;
|
|
|
var Amount = (num - Convert.ToUInt32(item.Num)) * 300;
|
|
var Amount = (num - Convert.ToUInt32(item.Num)) * 300;
|
|
|
- userAccount.FixedAmount += Amount;
|
|
|
|
|
|
|
+ // userAccount.FixedAmount += Amount;
|
|
|
|
|
+ userAccount.ValidAmount += Amount;//可用额度操作
|
|
|
apply.UseAmount += Amounts;
|
|
apply.UseAmount += Amounts;
|
|
|
}
|
|
}
|
|
|
if (kqProducts.Name.Contains("电签"))
|
|
if (kqProducts.Name.Contains("电签"))
|
|
@@ -633,7 +639,8 @@ namespace MySystem.Areas.Admin.Controllers
|
|
|
UserAccount userAccount = db.UserAccount.FirstOrDefault(m => m.UserId == apply.UserId);
|
|
UserAccount userAccount = db.UserAccount.FirstOrDefault(m => m.UserId == apply.UserId);
|
|
|
var Amounts = Convert.ToUInt32(item.Num) * 200;
|
|
var Amounts = Convert.ToUInt32(item.Num) * 200;
|
|
|
var Amount = (num - Convert.ToUInt32(item.Num)) * 200;
|
|
var Amount = (num - Convert.ToUInt32(item.Num)) * 200;
|
|
|
- userAccount.FixedAmount += Amount;
|
|
|
|
|
|
|
+ // userAccount.FixedAmount += Amount;
|
|
|
|
|
+ userAccount.ValidAmount += Amount;//可用额度操作
|
|
|
apply.UseAmount += Amounts;
|
|
apply.UseAmount += Amounts;
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -701,6 +708,8 @@ namespace MySystem.Areas.Admin.Controllers
|
|
|
storeSH.LaveNum += item.Num;
|
|
storeSH.LaveNum += item.Num;
|
|
|
storeSH.TotalNum += item.Num;
|
|
storeSH.TotalNum += item.Num;
|
|
|
}
|
|
}
|
|
|
|
|
+ apply.SeoTitle = SysUserName +'-'+ SysRealName;//添加操作人信息
|
|
|
|
|
+
|
|
|
db.SaveChanges();
|
|
db.SaveChanges();
|
|
|
new AdminContentOther(_accessor.HttpContext, PublicFunction.MainTables).Edit("StoreMachineApply", Fields, data.Id);
|
|
new AdminContentOther(_accessor.HttpContext, PublicFunction.MainTables).Edit("StoreMachineApply", Fields, data.Id);
|
|
|
|
|
|