|
@@ -11447,18 +11447,81 @@ namespace OASystem.API.Controllers
|
|
|
{
|
|
|
_airTicketResRep.ChangeDataBase(DBEnum.OA2014DB);
|
|
|
|
|
|
- string sql = string.Format(@" Select * From Visa With(Nolock) ");
|
|
|
- List<OA2014_Visa> list_visa = _airTicketResRep._sqlSugar.SqlQueryable<OA2014_Visa>(sql).ToList();
|
|
|
+ string sql = string.Format(@" Select * From grouopExceed where id > 20 And id not in (26,27) ");
|
|
|
+ List<OA2014_grouopExceed> list_visa = _airTicketResRep._sqlSugar.SqlQueryable<OA2014_grouopExceed>(sql).ToList();
|
|
|
|
|
|
_airTicketResRep.ChangeDataBase(DBEnum.OA2023DB);
|
|
|
+
|
|
|
+ Dictionary<int, int> dicDetail = new Dictionary<int, int>();
|
|
|
+ dicDetail.Add(789, 1034);
|
|
|
+ dicDetail.Add(790, 1035);
|
|
|
+ dicDetail.Add(791, 1036);
|
|
|
+ dicDetail.Add(792, 1037);
|
|
|
+ dicDetail.Add(793, 1038);
|
|
|
+ dicDetail.Add(794, 1039);
|
|
|
+ dicDetail.Add(795, 1040);
|
|
|
+ dicDetail.Add(796, 1041);
|
|
|
+ dicDetail.Add(797, 1042);
|
|
|
+ dicDetail.Add(798, 1043);
|
|
|
+ dicDetail.Add(801, 1044);
|
|
|
+ dicDetail.Add(802, 1045);
|
|
|
+ dicDetail.Add(803, 1046);
|
|
|
+
|
|
|
+ Dictionary<int, int> dic = new Dictionary<int, int>();
|
|
|
+ dic.Add(806, 1027);
|
|
|
+ dic.Add(807, 1028);
|
|
|
+ dic.Add(808, 1029);
|
|
|
+ dic.Add(809, 1030);
|
|
|
+ dic.Add(810, 1031);
|
|
|
+ dic.Add(811, 1032);
|
|
|
+ dic.Add(812, 1033);
|
|
|
+
|
|
|
+
|
|
|
foreach (var item in list_visa)
|
|
|
{
|
|
|
- var result = await _grpScheduleRep._sqlSugar.Updateable<Grp_VisaInfo>()
|
|
|
- .SetColumns(it => it.CreateUserId == item.Operator)
|
|
|
- .Where(s => s.Id == item.Id)
|
|
|
+ Fin_GroupExtraCost temp = new Fin_GroupExtraCost();
|
|
|
+ temp.Coefficient = item.coefficient;
|
|
|
|
|
|
- //.UpdateColumns(s => new { s.Duty, s.ExpectBeginDt, s.ExpectEndDt, s.JobContent, s.Remark, s.StepStatus })
|
|
|
- .ExecuteCommandAsync();
|
|
|
+ DateTime dtCrt;
|
|
|
+ bool b1 = DateTime.TryParse(item.OperatorsDate, out dtCrt);
|
|
|
+ if (b1)
|
|
|
+ {
|
|
|
+ temp.CreateTime = dtCrt;
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ temp.CreateTime = DateTime.Now;
|
|
|
+ }
|
|
|
+
|
|
|
+ temp.CreateUserId = item.Operators;
|
|
|
+ temp.DeleteTime = "";
|
|
|
+ temp.DeleteUserId = 0;
|
|
|
+ temp.DiId = int.Parse(item.DIID);
|
|
|
+ temp.FilePath = item.FilePath;
|
|
|
+ temp.IsDel = item.IsDel;
|
|
|
+ temp.Price = item.Price;
|
|
|
+ temp.PriceCount = 1;
|
|
|
+ temp.PriceCurrency = item.Currency;
|
|
|
+
|
|
|
+ int detailId = 0;
|
|
|
+ if (dicDetail.ContainsKey(item.PriceTypeDetail)) {
|
|
|
+ detailId = dicDetail[item.PriceTypeDetail];
|
|
|
+ }
|
|
|
+ temp.PriceDetailType = detailId;
|
|
|
+
|
|
|
+ temp.PriceDt = DateTime.Now;
|
|
|
+ temp.PriceName = item.PriceName;
|
|
|
+ temp.PriceSum = item.Price;
|
|
|
+
|
|
|
+ int tid = 0;
|
|
|
+ if (dic.ContainsKey(item.PriceType))
|
|
|
+ {
|
|
|
+ tid = dic[item.PriceType];
|
|
|
+ }
|
|
|
+ temp.PriceType = tid;
|
|
|
+
|
|
|
+ temp.Remark = item.Remark;
|
|
|
+
|
|
|
+ await _airTicketResRep.AddAsync<Fin_GroupExtraCost>(temp);
|
|
|
}
|
|
|
|
|
|
return Ok(JsonView(true, "操作成功!"));
|