Browse Source

Merge branch 'develop' of http://132.232.92.186:3000/XinXiBu/OA2023 into develop

jiangjc 10 months ago
parent
commit
ba7067b0f1

+ 2 - 2
OASystem/OASystem.Api/Controllers/FinancialController.cs

@@ -338,9 +338,9 @@ namespace OASystem.API.Controllers
             try
             {
                 //迁移数据更新团组汇率
-                Result teamRateData1 = await _teamRateRep.GetGroupRateChangeData();
+                //Result teamRateData1 = await _teamRateRep.GetGroupRateChangeData();
 
-                var data = await _teamRateRep.PostGroupTeamRateHot();
+                //var data = await _teamRateRep.PostGroupTeamRateHot();
 
 
                 Stopwatch stopwatch = Stopwatch.StartNew();

+ 119 - 36
OASystem/OASystem.Api/Controllers/GroupsController.cs

@@ -3719,6 +3719,8 @@ namespace OASystem.API.Controllers
                 var rateDatas = await _EnterExitCosts.CurrencyRemark.SplitExchangeRate();
 
 
+                _DelegationInfo.VisitCountry = _DelegationInfo.VisitCountry.Replace("|", "、");
+
                 if (dto.ExportType == 1) //明细表
                 {
                     if (dto.SubTypeId == 1005) //1005(默认明细表)
@@ -4011,8 +4013,8 @@ namespace OASystem.API.Controllers
                         dic.Add("VisitCountry", _DelegationInfo.VisitCountry);
                         dic.Add("ClientUnit", _DelegationInfo.ClientUnit);
 
-                        var Names = string.Join("、", DeleClientList.Select(it => it.Name).ToList()).TrimEnd('、');
-                        dic.Add("Names", Names);
+                        //var Names = string.Join("、", DeleClientList.Select(it => it.Name).ToList()).TrimEnd('、');
+                        //dic.Add("Names", Names);
 
 
                         NodeCollection allTables = doc.GetChildNodes(NodeType.Table, true);
@@ -4034,7 +4036,7 @@ namespace OASystem.API.Controllers
                             builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));
                             builder.MoveToCell(0, accommodationStartIndex, 2, 0);
 
-                            string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknown";
+                            string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Remark ?? "Unknown";
                             builder.Write(currency);//币种
                             builder.MoveToCell(0, accommodationStartIndex, 3, 0);
                             builder.Write(dac.Cost.ToString("#0.00"));//标准
@@ -4047,7 +4049,7 @@ namespace OASystem.API.Controllers
                             builder.MoveToCell(0, accommodationStartIndex, 7, 0);
 
                             decimal rate = 0.00M;
-                            rate = rateDatas.Find(it => it.CurrencyCode.Equals(currency))?.Rate ?? 0.00M;
+                            rate = rateDatas.Find(it => it.CurrencyName.Equals(currency))?.Rate ?? 0.00M;
 
                             builder.Write(rate.ToString("#0.0000"));//汇率
                             builder.MoveToCell(0, accommodationStartIndex, 8, 0);
@@ -4088,7 +4090,7 @@ namespace OASystem.API.Controllers
 
                             builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));
                             builder.MoveToCell(0, foodandotherStartIndex, 2, 0);
-                            string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknown";
+                            string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Remark ?? "Unknown";
                             builder.Write(currency);//币种
                             builder.MoveToCell(0, foodandotherStartIndex, 3, 0);
                             builder.Write(dac.Cost.ToString("#0.00"));//标准
@@ -4101,7 +4103,7 @@ namespace OASystem.API.Controllers
                             builder.MoveToCell(0, foodandotherStartIndex, 7, 0);
 
                             decimal rate = 0.00M;
-                            rate = rateDatas.Find(it => it.CurrencyCode.Equals(currency))?.Rate ?? 0.00M;
+                            rate = rateDatas.Find(it => it.CurrencyName.Equals(currency))?.Rate ?? 0.00M;
 
                             builder.Write(rate.ToString("#0.0000"));//汇率
 
@@ -4119,10 +4121,26 @@ namespace OASystem.API.Controllers
                             table1.Rows.RemoveAt(i - 1);
                         }
 
+
                         dic.Add("CityTranffic", _EnterExitCosts.CityTranffic.ToString("#0.00"));
-                        dic.Add("VisaPay", _EnterExitCosts.Visa.ToString("#0.00"));
-                        dic.Add("SafePay", _EnterExitCosts.Safe.ToString("#0.00"));
-                        dic.Add("YiMiao", _EnterExitCosts.YiMiao.ToString("#0.00"));
+
+                        string otherFeeStr = "";
+                        if (_EnterExitCosts.Visa > 0) otherFeeStr += $"签证费: {_EnterExitCosts.Visa.ToString("#0.00")} 元,";
+                        if (_EnterExitCosts.Safe > 0) otherFeeStr += $"保险费: {_EnterExitCosts.Safe.ToString("#0.00")} 元,";
+                        if (_EnterExitCosts.Ticket > 0) otherFeeStr += $"参展门票费: {_EnterExitCosts.Ticket.ToString("#0.00")} 元,";
+
+                        if (otherFeeStr.Length > 0)
+                        {
+                            otherFeeStr = otherFeeStr.Substring(0, otherFeeStr.Length - 1);
+                            otherFeeStr = $"({otherFeeStr})";
+
+                            dic.Add("OtherFeeStr", otherFeeStr);
+                        }
+
+
+                        //dic.Add("VisaPay", _EnterExitCosts.Visa.ToString("#0.00"));
+                        //dic.Add("SafePay", _EnterExitCosts.Safe.ToString("#0.00"));
+                        //dic.Add("YiMiao", _EnterExitCosts.YiMiao.ToString("#0.00"));
 
                         foreach (var key in dic.Keys)
                         {
@@ -4221,9 +4239,9 @@ namespace OASystem.API.Controllers
                             new DataColumn(){ ColumnName = "criterion"},
                             new DataColumn(){ ColumnName = "number",DataType = typeof(int)},
                             new DataColumn(){ ColumnName = "day",DataType = typeof(int)},
-                            new DataColumn(){ ColumnName = "cost",  DataType = typeof(float)},
+                            new DataColumn(){ ColumnName = "cost",  DataType = typeof(decimal)},
                             new DataColumn(){ ColumnName = "rate",  DataType = typeof(decimal) },
-                            new DataColumn(){ ColumnName = "costRMB"},
+                            new DataColumn(){ ColumnName = "costRMB",  DataType = typeof(decimal) },
                         });
                         DataTable dtdac2 = new DataTable();
                         dtdac2.Columns.AddRange(new DataColumn[] {
@@ -4232,9 +4250,9 @@ namespace OASystem.API.Controllers
                             new DataColumn(){ ColumnName = "criterion"},
                             new DataColumn(){ ColumnName = "number",DataType = typeof(int)},
                             new DataColumn(){ ColumnName = "day",DataType = typeof(int)},
-                            new DataColumn(){ ColumnName = "cost",  DataType = typeof(float)},
+                            new DataColumn(){ ColumnName = "cost",  DataType = typeof(decimal)},
                             new DataColumn(){ ColumnName = "rate",  DataType = typeof(decimal) },
-                            new DataColumn(){ ColumnName = "costRMB"},
+                            new DataColumn(){ ColumnName = "costRMB",DataType = typeof(decimal)},
                         });
                         dtdac1.TableName = "tb1";
                         dtdac2.TableName = "tb2";
@@ -4250,8 +4268,8 @@ namespace OASystem.API.Controllers
 
                             row["city"] =item.Place;
 
-                            string currency = _CurrDatas.Find(it => it.Id == item.Currency)?.Name ?? "Unknwon";
-                            decimal rate = rateDatas.Find(it => it.CurrencyCode == currency)?.Rate ?? 0.00M;
+                            string currency = _CurrDatas.Find(it => it.Id == item.Currency)?.Remark ?? "Unknwon";
+                            decimal rate = rateDatas.Find(it => it.CurrencyName == currency)?.Rate ?? 0.00M;
                             row["curr"] = currency;
                             row["rate"] = rate;
                             row["criterion"] = item.Cost;
@@ -4274,8 +4292,8 @@ namespace OASystem.API.Controllers
                             }
                             DataRow row = dtdac2.NewRow();
                             row["city"] = item.Place;
-                            string currency = _CurrDatas.Find(it => it.Id == item.Currency)?.Name ?? "Unknwon";
-                            decimal rate = rateDatas.Find(it => it.CurrencyCode == currency)?.Rate ?? 0.00M;
+                            string currency = _CurrDatas.Find(it => it.Id == item.Currency)?.Remark ?? "Unknwon";
+                            decimal rate = rateDatas.Find(it => it.CurrencyName == currency)?.Rate ?? 0.00M;
                             row["curr"] = currency;
                             row["rate"] = rate;
                             row["criterion"] = item.Cost;
@@ -4297,8 +4315,19 @@ namespace OASystem.API.Controllers
                         designer.SetDataSource("dac2totalPrice", dac2totalPrice);
                         string cell4Str = $"  4.国际旅费:经济舱:{_EnterExitCosts.OutsideJJPay.ToString("#0.00")}元,公务舱:{_EnterExitCosts.OutsaideGWPay.ToString("#0.00")}元";
                         string cellStr = $"  5.其他费用(签证费:{_EnterExitCosts.Visa.ToString("#0.00")}元,保险费 :{_EnterExitCosts.Safe.ToString("#0.00")}元)";
-                        decimal s = dac1totalPrice + dac2totalPrice + _EnterExitCosts.OutsideJJPay + _EnterExitCosts.OutsaideGWPay + _EnterExitCosts.Visa + _EnterExitCosts.Safe;
-                        string celllastStr = $"    经审核,住宿费 {dac1totalPrice.ToString("#0.00")} 元,伙食费和公杂费 {dac2totalPrice.ToString(".00")} 元,培训费   元,国际旅费 {(_EnterExitCosts.OutsideJJPay + _EnterExitCosts.OutsaideGWPay).ToString("#0.00")} 元,其他费用 {(_EnterExitCosts.Visa + _EnterExitCosts.Safe).ToString("#0.00")} 元,本次出国经费预算合计为 {s.ToString("#0.00")} 元。其中:市本级安排      。";
+                        decimal s = dac1totalPrice + dac2totalPrice + _EnterExitCosts.OutsideJJPay + _EnterExitCosts.OutsaideGWPay + _EnterExitCosts.Visa + _EnterExitCosts.Safe + _EnterExitCosts.Ticket;
+
+                        decimal pxFee = dac4.Sum(it => it.Cost);
+                        decimal glvFee = _EnterExitCosts.OutsideJJPay + _EnterExitCosts.OutsaideGWPay;
+                        decimal otherFee = _EnterExitCosts.Visa + _EnterExitCosts.Safe + _EnterExitCosts.Ticket;
+                        string celllastStr1 = "";
+                        if (dac1totalPrice > 0) celllastStr1 += $"住宿费 {dac1totalPrice.ToString("#0.00")} 元";
+                        if (dac2totalPrice > 0) celllastStr1 += $",伙食费和公杂费 {dac2totalPrice.ToString("#0.00")} 元";
+                        if (pxFee > 0) celllastStr1 += $",培训费 {pxFee.ToString("#0.00")} 元";
+                        if (glvFee > 0) celllastStr1 += $",国际旅费 {glvFee.ToString("#0.00")} 元";
+                        if (otherFee > 0) celllastStr1 += $",其他费用 {otherFee.ToString("#0.00")} 元";
+
+                        string celllastStr = $"    经审核,{celllastStr1},本次出国经费预算合计为 {s.ToString("#0.00")} 元。其中:市本级安排      。";
 
                         designer.SetDataSource("cell4Str", cell4Str);
                         designer.SetDataSource("cellStr", cellStr);
@@ -4369,7 +4398,13 @@ namespace OASystem.API.Controllers
 
                         dic.Add("TeamName", _DelegationInfo.TeamName);
                         dic.Add("ClientUnit", _DelegationInfo.ClientUnit);
-                        dic.Add("TellPhone", _DelegationInfo.TellPhone);
+                        //dic.Add("TellPhone", _DelegationInfo.TellPhone);
+
+                        string missionLeaderName = DeleClientList[0].Name,
+                               missionLeaderJob = DeleClientList[0].Job;
+                        dic.Add("MissionLeaderName", missionLeaderName);
+                        dic.Add("MissionLeaderJob", missionLeaderJob);
+
                         dic.Add("VisitPNumber", _DelegationInfo.VisitPNumber.ToString());
                         dic.Add("VisitPurpose", _DelegationInfo.VisitPurpose);
 
@@ -4423,11 +4458,11 @@ namespace OASystem.API.Controllers
                         Document doc = new Document(tempPath);
                         DocumentBuilder builder = new DocumentBuilder(doc);
 
+                        dic.Add("GroupClient", _DelegationInfo.ClientUnit);
+
                         var Names = string.Join("、", DeleClientList.Select(x => x.Name)).TrimEnd('、');
                         dic.Add("Names", Names);
 
-                        int accommodationStartIndex = 6;
-                        int foodandotherStartIndex = 19;//
                         int accommodationRows = 12, foodandotherRows = 12;
                         var Dac1currCn = dac1.GroupBy(x => x.Currency).Select(x => x.Key).ToList();
                         var Dac2currCn = dac2.GroupBy(x => x.Currency).Select(x => x.Key).ToList();
@@ -4435,6 +4470,8 @@ namespace OASystem.API.Controllers
                         NodeCollection allTables = doc.GetChildNodes(NodeType.Table, true);
                         Aspose.Words.Tables.Table table1 = allTables[0] as Aspose.Words.Tables.Table;
 
+
+                        int accommodationStartIndex = 6;
                         decimal dac1totalPrice = 0.00M;
                         foreach (var dac in dac1)
                         {
@@ -4449,7 +4486,7 @@ namespace OASystem.API.Controllers
                             builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));//城市
                             builder.MoveToCell(0, accommodationStartIndex, 2, 0);
 
-                            string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknwon";
+                            string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Remark ?? "Unknwon";
                             builder.Write(currency);//币种
                             builder.MoveToCell(0, accommodationStartIndex, 3, 0);
                             builder.Write(dac.Cost.ToString("#0.00"));//标准
@@ -4461,7 +4498,7 @@ namespace OASystem.API.Controllers
                             builder.Write(dac.SubTotal.ToString("#0.00"));//小计
                             builder.MoveToCell(0, accommodationStartIndex, 7, 0);
 
-                            decimal rate = rateDatas.Find(it => it.CurrencyCode == currency)?.Rate ?? 0.00M;
+                            decimal rate = rateDatas.Find(it => it.CurrencyName == currency)?.Rate ?? 0.00M;
                             builder.Write(rate.ToString("#0.0000"));//汇率
                             builder.MoveToCell(0, accommodationStartIndex, 8, 0);
 
@@ -4471,7 +4508,32 @@ namespace OASystem.API.Controllers
                             dac1totalPrice += rbmPrice;
                         }
 
-                        dic.Add("dac1totalPrice", dac1totalPrice.ToString());
+                        
+
+
+                        dic.Add("dac1totalPrice", dac1totalPrice.ToString("#0.00"));
+
+
+                        builder.MoveToCell(0, accommodationStartIndex, 1, 0);
+                        builder.Write("小计");
+                        builder.MoveToCell(0, accommodationStartIndex, 8, 0);
+                        builder.Write(dac1totalPrice.ToString("#0.00"));
+
+                        accommodationStartIndex++;
+
+
+                        int nullRow = accommodationRows - dac1.Count;
+                        //删除空行
+                        //if (nullRow > 0)
+                        //{
+                        //    int rowIndex = accommodationStartIndex;
+                        //    for (int i = 0; i < nullRow; i++)
+                        //    {
+                        //        Row row = table1.Rows[rowIndex];
+                        //        row.Remove();        
+                        //        rowIndex++;
+                        //    }
+                        //}
 
                         if (dac2.Count == dac3.Count)//国家 币种 金额
                         {
@@ -4482,6 +4544,7 @@ namespace OASystem.API.Controllers
                             }
                         }
 
+                        int foodandotherStartIndex = 19;//
                         decimal dac2totalPrice = 0.00M;
                         foreach (var dac in dac2)
                         {
@@ -4489,12 +4552,12 @@ namespace OASystem.API.Controllers
                             {
                                 continue;
                             }
-
+                            //foodandotherStartIndex = 12;
                             builder.MoveToCell(0, foodandotherStartIndex, 1, 0);
                             builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));//城市
                             builder.MoveToCell(0, foodandotherStartIndex, 2, 0);
 
-                            string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknwon";
+                            string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Remark ?? "Unknwon";
                             builder.Write(currency);//币种
                             builder.MoveToCell(0, foodandotherStartIndex, 3, 0);
                             builder.Write(dac.Cost.ToString("#0.00"));//标准
@@ -4506,8 +4569,8 @@ namespace OASystem.API.Controllers
                             builder.Write(dac.SubTotal.ToString("#0.00"));//小计
                             builder.MoveToCell(0, foodandotherStartIndex, 7, 0);
 
-                            decimal rate = rateDatas.Find(it => it.CurrencyCode == currency)?.Rate ?? 0.00M;
-                            builder.Write(rate.ToString());//汇率
+                            decimal rate = rateDatas.Find(it => it.CurrencyName == currency)?.Rate ?? 0.00M;
+                            builder.Write(rate.ToString("#0.0000"));//汇率
                             builder.MoveToCell(0, foodandotherStartIndex, 8, 0);
 
                             decimal rbmPrice = rate * dac.SubTotal;
@@ -4516,12 +4579,30 @@ namespace OASystem.API.Controllers
                             dac2totalPrice += rbmPrice;
                         }
 
-                        dic.Add("dac2totalPrice", dac2totalPrice.ToString());
-
+                        dic.Add("dac2totalPrice", dac2totalPrice.ToString("#0.00"));
                         //删除空行
-                        if (dac1.Count < accommodationRows)
+                        if (dac2.Count < foodandotherRows)
                         {
-                            int nullRow = accommodationRows - dac1.Count;
+                            //int nullRow = accommodationRows - dac2.Count;
+                            //while (table2.Rows.Count > dac2.Count)
+                            //{
+                            //    table2.Rows.RemoveAt(dac2.Count);
+                            //}
+                        }
+
+                        dic.Add("CityTranffic", _EnterExitCosts.CityTranffic.ToString("#0.00"));
+
+                        string otherFeeStr = "";
+                        if (_EnterExitCosts.Visa > 0) otherFeeStr += $"签证费: {_EnterExitCosts.Visa.ToString("#0.00")} 元,";
+                        if (_EnterExitCosts.Safe > 0) otherFeeStr += $"保险费: {_EnterExitCosts.Safe.ToString("#0.00")} 元,";
+                        if (_EnterExitCosts.Ticket > 0) otherFeeStr += $"参展门票费: {_EnterExitCosts.Ticket.ToString("#0.00")} 元,";
+
+                        if (otherFeeStr.Length > 0)
+                        {
+                            otherFeeStr = otherFeeStr.Substring(0, otherFeeStr.Length - 1);
+                            otherFeeStr = $"({otherFeeStr})";
+
+                            dic.Add("OtherFeeStr", otherFeeStr);
                         }
 
                         foreach (var key in dic.Keys)
@@ -4586,8 +4667,10 @@ namespace OASystem.API.Controllers
                         }
 
                         string strFileName = $"{_DelegationInfo.TeamName}组团人员名单({DateTime.Now.ToString("yyyyMMddHHmmss")}).doc";
-
+                        //C:/Server/File/OA2023/Office/Word/EnterExitCost/File/
+                        //C:\Server\File\OA2023\Office\Word\EnterExitCost\File\
                         doc.Save(AppSettingsHelper.Get("WordBasePath") + "EnterExitCost/File/" + strFileName);
+
                         string url = AppSettingsHelper.Get("WordBaseUrl") + "Office/Word/EnterExitCost/File/" + strFileName;
                         return Ok(JsonView(true, "成功", new { Url = url }));
                     }
@@ -10343,9 +10426,9 @@ namespace OASystem.API.Controllers
 
             string fileName = "组团人员名单(" + DateTime.Now.ToString("yyyyhhddHHmmss") + ").doc";
 
-            var fileDir = AppSettingsHelper.Get("WordBasePath") + fileName;
+            var fileDir = AppSettingsHelper.Get("WordBasePath")+ "TourClientList/" + fileName;
             doc.Save(fileDir);
-            string Url = AppSettingsHelper.Get("WordBaseUrl") + "Office/Word/" + fileName;
+            string Url = AppSettingsHelper.Get("WordBaseUrl") + "Office/Word/TourClientList/" + fileName;
             return Ok(JsonView(true, "操作成功!", Url));
         }
 

+ 28 - 27
OASystem/OASystem.Infrastructure/Repositories/Groups/EnterExitCostRepository.cs

@@ -85,7 +85,7 @@ namespace OASystem.Infrastructure.Repositories.Groups
                     var dayAndCostSql = string.Format(@"Select ntf.Country,ntf.City,ssd.Name CurremcyCode,ssd.Remark CurrencyName,gdac.* From Grp_DayAndCost gdac
                                                         Left Join Grp_NationalTravelFee ntf On ntf.Id = gdac.NationalTravelFeeId
                                                         Left Join Sys_SetData ssd On ssd.STid = 66 And gdac.Currency = ssd.Id
-                                                        Where gdac.Isdel = 0 And gdac.DiId = {0} Order By [Type] ASC,[Days] ASC", dto.DiId);
+                                                        Where gdac.Isdel = 0 And ntf.IsDel = 0 And gdac.DiId = {0} Order By [Type] ASC,[Days] ASC", dto.DiId);
                     var dayAndCostData = await _sqlSugar.SqlQueryable<DayAndCostInfoView>(dayAndCostSql).ToListAsync();
 
 
@@ -101,22 +101,22 @@ namespace OASystem.Infrastructure.Repositories.Groups
                 }
                 else
                 {
-                    List<DayAndCostInfoView> views = new List<DayAndCostInfoView>()
-                    {
-                            new DayAndCostInfoView {},
-                            new DayAndCostInfoView {},
-                            new DayAndCostInfoView {},
-                            new DayAndCostInfoView {},
-                            new DayAndCostInfoView {},
-                            new DayAndCostInfoView {},
-                            new DayAndCostInfoView {},
-                            new DayAndCostInfoView {}
-                    };
-
-                    enterExitCostInfoView.QuarterageData = views;
-                    enterExitCostInfoView.BoardWagesData = views;
-                    enterExitCostInfoView.MiscellaneousFeeData = views;
-                    enterExitCostInfoView.TrainingExpenseData = views;
+                //    List<DayAndCostInfoView> views = new List<DayAndCostInfoView>()
+                //    {
+                //            new DayAndCostInfoView {Days=1},
+                //            new DayAndCostInfoView {Days=2},
+                //            new DayAndCostInfoView {Days=3},
+                //            new DayAndCostInfoView {Days=4},
+                //            new DayAndCostInfoView {Days=5},
+                //            new DayAndCostInfoView {Days=6},
+                //            new DayAndCostInfoView {Days=7},
+                //            new DayAndCostInfoView {Days=8},
+                //    };
+                //    enterExitCostInfoView.QuarterageData = views;
+                //    enterExitCostInfoView.BoardWagesData = views;
+                //    enterExitCostInfoView.MiscellaneousFeeData = views;
+                //    enterExitCostInfoView.TrainingExpenseData = views;
+                //    result.Code = 0;
                     result.Msg = "未查询出数据!!!";
                 }
 
@@ -164,24 +164,25 @@ namespace OASystem.Infrastructure.Repositories.Groups
                 try
                 {
                     var enterExit = _sqlSugar.Storageable<Grp_EnterExitCost>(enterExitCost).ToStorage();
-                    enterExit.AsInsertable.ExecuteCommand();   //不存在插入
-                    enterExit.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
+                    
+                    var enterExitadd = enterExit.AsInsertable.ExecuteCommand();   //不存在插入
+                    var enterExitedit = enterExit.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
 
                     var quarterage = _sqlSugar.Storageable<Grp_DayAndCost>(quarterageData).ToStorage();  //住宿费 1
-                    quarterage.AsInsertable.ExecuteCommand();   //不存在插入                             
-                    quarterage.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.Type, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
+                    var quarterageadd  =quarterage.AsInsertable.ExecuteCommand();   //不存在插入                             
+                    var quarterageedit = quarterage.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.Type, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
 
                     var boardWages = _sqlSugar.Storageable<Grp_DayAndCost>(boardWagesData).ToStorage();  //伙食费 2
-                    boardWages.AsInsertable.ExecuteCommand();   //不存在插入
-                    boardWages.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.Type, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
+                    var boardWagesadd  =boardWages.AsInsertable.ExecuteCommand();   //不存在插入
+                    var boardWagesedit = boardWages.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.Type, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
 
                     var miscellaneousFee = _sqlSugar.Storageable<Grp_DayAndCost>(miscellaneousFeeData).ToStorage(); //公杂费 3
-                    miscellaneousFee.AsInsertable.ExecuteCommand();   //不存在插入
-                    miscellaneousFee.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.Type, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
+                    var miscellaneousFeeedd  =miscellaneousFee.AsInsertable.ExecuteCommand();   //不存在插入
+                    var miscellaneousFeeedit = miscellaneousFee.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.Type, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
 
                     var trainingExpense = _sqlSugar.Storageable<Grp_DayAndCost>(trainingExpenseData).ToStorage();    //培训费 4
-                    trainingExpense.AsInsertable.ExecuteCommand();   //不存在插入
-                    trainingExpense.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.Type, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
+                    var trainingExpenseadd  =trainingExpense.AsInsertable.ExecuteCommand();   //不存在插入
+                    var trainingExpenseedit = trainingExpense.AsUpdateable.IgnoreColumns(it => new { it.DiId, it.Type, it.CreateUserId, it.CreateTime, it.IsDel }).ExecuteCommand();   //存在更新
 
                     _sqlSugar.CommitTran();
                     result.Code = 0;