jiangjc 2 years ago
parent
commit
08001d723c
21 changed files with 1700 additions and 43 deletions
  1. 3 1
      OASystem/EntitySync/Program.cs
  2. 82 1
      OASystem/OASystem.Api/Controllers/FinancialController.cs
  3. 56 1
      OASystem/OASystem.Api/Controllers/GroupsController.cs
  4. 13 3
      OASystem/OASystem.Api/Controllers/MarketCustomerResourcesController.cs
  5. 127 1
      OASystem/OASystem.Api/Controllers/ResourceController.cs
  6. 36 14
      OASystem/OASystem.Api/Controllers/SmallFunController.cs
  7. 48 3
      OASystem/OASystem.Api/OAMethodLib/File/AsposeHelper.cs
  8. 5 0
      OASystem/OASystem.Domain/AutoMappers/_baseMappingProfile.cs
  9. 18 0
      OASystem/OASystem.Domain/Dtos/Groups/AirTicketResDto.cs
  10. 43 0
      OASystem/OASystem.Domain/Dtos/Resource/OpAirTicketAgentDto.cs
  11. 130 0
      OASystem/OASystem.Domain/Entities/Groups/Grp_AirTicketReservations.cs
  12. 257 0
      OASystem/OASystem.Domain/Entities/Groups/Grp_GroupCostParameter.cs
  13. 37 0
      OASystem/OASystem.Domain/ViewModels/Financial/Fin_DailyFeePaymentView.cs
  14. 53 0
      OASystem/OASystem.Domain/ViewModels/Groups/AirTicketReservationsView.cs
  15. 3 3
      OASystem/OASystem.Infrastructure/Repositories/CRM/NewClientDataRepository.cs
  16. 10 0
      OASystem/OASystem.Infrastructure/Repositories/CRM/VisaDeleClientRepository.cs
  17. 30 8
      OASystem/OASystem.Infrastructure/Repositories/Financial/DailyFeePaymentRepository.cs
  18. 73 0
      OASystem/OASystem.Infrastructure/Repositories/Resource/AirTicketAgentRepository.cs
  19. 226 0
      OASystem/OASystem.Infrastructure/Repositories/Resource/AirTicketResRepository.cs
  20. 3 1
      OASystem/OASystem.Infrastructure/Tools/CommonFun.cs
  21. 447 7
      OASystem/_Doc/OA2023数据字典.docx

+ 3 - 1
OASystem/EntitySync/Program.cs

@@ -92,6 +92,8 @@ db.CodeFirst.SetStringDefaultLength(50).BackupTable().InitTables(new Type[]
     //typeof(Res_MemoInfo),
     //typeof(Res_MemoInfo),
     //typeof(Fin_DailyFeePayment), // 财务 - 日付申请
     //typeof(Fin_DailyFeePayment), // 财务 - 日付申请
     //typeof(Fin_DailyFeePaymentContent)  // 财务 - 日付申请详细类
     //typeof(Fin_DailyFeePaymentContent)  // 财务 - 日付申请详细类
-    typeof(Grp_GroupsTaskAssignment)
+    //typeof(Grp_GroupsTaskAssignment)
+    //typeof(Grp_AirTicketReservations)
+    typeof(Grp_GroupCostParameter)
 });
 });
 Console.WriteLine("数据库结构同步完成!");
 Console.WriteLine("数据库结构同步完成!");

+ 82 - 1
OASystem/OASystem.Api/Controllers/FinancialController.cs

@@ -1,10 +1,13 @@
 using Microsoft.AspNetCore.Http;
 using Microsoft.AspNetCore.Http;
 using Microsoft.AspNetCore.Mvc;
 using Microsoft.AspNetCore.Mvc;
+using OASystem.API.OAMethodLib.File;
 using OASystem.Domain;
 using OASystem.Domain;
 using OASystem.Domain.Dtos.Financial;
 using OASystem.Domain.Dtos.Financial;
 using OASystem.Domain.Entities.Groups;
 using OASystem.Domain.Entities.Groups;
+using OASystem.Domain.ViewModels.Financial;
 using OASystem.Domain.ViewModels.Groups;
 using OASystem.Domain.ViewModels.Groups;
 using OASystem.Infrastructure.Repositories.Financial;
 using OASystem.Infrastructure.Repositories.Financial;
+using System.Data;
 
 
 namespace OASystem.API.Controllers
 namespace OASystem.API.Controllers
 {
 {
@@ -18,15 +21,19 @@ namespace OASystem.API.Controllers
         private readonly IMapper _mapper;
         private readonly IMapper _mapper;
         private readonly IConfiguration _config;
         private readonly IConfiguration _config;
         private readonly DailyFeePaymentRepository _daiRep;
         private readonly DailyFeePaymentRepository _daiRep;
+        private readonly SqlSugarClient _sqlSugar;
+        private readonly SetDataTypeRepository _setDataTypeRep;
 
 
         /// <summary>
         /// <summary>
         /// 初始化
         /// 初始化
         /// </summary>
         /// </summary>
-        public FinancialController(IMapper mapper, IConfiguration configuration, DailyFeePaymentRepository daiRep) 
+        public FinancialController(IMapper mapper, IConfiguration configuration, DailyFeePaymentRepository daiRep, SqlSugarClient sqlSugar, SetDataTypeRepository setDataTypeRep) 
         {
         {
             this._mapper = mapper;
             this._mapper = mapper;
             this._config = configuration;
             this._config = configuration;
             this._daiRep = daiRep;
             this._daiRep = daiRep;
+            this._sqlSugar = sqlSugar;
+            this._setDataTypeRep = setDataTypeRep;
         }
         }
 
 
         #region 日付申请
         #region 日付申请
@@ -163,6 +170,80 @@ namespace OASystem.API.Controllers
             return Ok(JsonView(true));
             return Ok(JsonView(true));
         }
         }
 
 
+        /// <summary>
+        /// 日付申请 Single Excel Download
+        /// </summary>
+        /// <param name="dto"> dto </param>
+        /// <returns></returns>
+        [HttpPost]
+        [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
+        public async Task<IActionResult> PostExcelDailyPaymentDownload(SearchDailyFeePaymentDto dto)
+        {
+            if (dto.PortType == 1 || dto.PortType == 2)
+            {
+                Fin_DailyFeePaymentInfolView feeData = new Fin_DailyFeePaymentInfolView();
+
+                string feeSql = string.Format(@"Select * From Fin_DailyFeePayment 
+                                                Where IsDel=0 And Id = {0} ", dto.Id);
+                feeData = await _sqlSugar.SqlQueryable<Fin_DailyFeePaymentInfolView>(feeSql).FirstAsync();
+                if (feeData == null)
+                {
+                    return Ok(JsonView(false, "暂无数据!"));
+                }
+
+                string feeContentSql = string.Format(@"Select * From Fin_DailyFeePaymentContent 
+                                                        Where IsDel=0 And DFPId = {0} ", dto.Id);
+                feeData.FeeContents = await _sqlSugar.SqlQueryable<Fin_DailyFeePaymentContentInfolView>(feeContentSql).ToListAsync();
+
+                if (feeData != null)
+                {
+
+                    string userName = string.Empty;
+                    string userSql = string.Format("Select * From  Sys_Users Where Id={0} And Isdel = {1}", feeData.CreateUserId, 0);
+                    Sys_Users user = await _sqlSugar.SqlQueryable<Sys_Users>(userSql).FirstAsync();
+                    if (user != null) { userName = user.CnName; }
+
+                    var setData = _setDataTypeRep.QueryDto<Sys_SetData, Fin_DailyFeePaymentPagePriceSubTypeView>().ToList();
+                    //48人员费用  49办公费用 50 销售费用 51 其他费用 55 大运会
+                    var priceSubTypeData = setData.Where(s => s.STid == 55).ToList();
+
+                    Dictionary<string, object> pairs = new Dictionary<string, object>();
+                    List<DataTable> datas = new List<DataTable>();
+
+                    //if (priceSubTypeData.Where(s => s.Id == feeData.PriceTypeId).ToList().Count() > 0)//大运会专属模板
+                    //{
+                        
+                    //    //AsposeHelper.ExpertExcelToModel("日常费用付款申请模板-大运会数据.xls", "DailyPayment", "大运会所有日常费用付款申请.xls",
+                    //    //    pairs, datas);
+                    //}
+                    //else  //日付常规模板
+                    //{
+                        pairs.Clear();
+                        pairs.Add("Opertor", userName);
+                        pairs.Add("DateTime", feeData.CreateTime.ToString("yyyy-MM-dd HH:mm:ss")); 
+                        pairs.Add("FAuditStatus", feeData.FAuditDesc); 
+                        pairs.Add("MAuditStatus", feeData.MAuditDesc);
+                        pairs.Add("SumPrice", feeData.SumPrice);
+
+                        DataTable data = AsposeHelper.ListToDataTable("DailyFeePayment", feeData.FeeContents);
+                        datas.Clear();
+                        datas.Add(data);
+                        string fileName = string.Format("{0}-日常费用付款申请.xlsx", feeData.Instructions);
+                        string msg = AsposeHelper.ExpertExcelToModel("日常费用付款申请模板.xlsx", "DailyPayment", fileName, pairs, datas);
+
+                        return Ok(JsonView(true, msg));
+                    //}
+                   
+                }
+                else
+                {
+                    return Ok(JsonView(false, "暂无数据!"));
+                }
+            }
+
+           
+            return Ok(JsonView(true));
+        }
         #endregion
         #endregion
     }
     }
 }
 }

+ 56 - 1
OASystem/OASystem.Api/Controllers/GroupsController.cs

@@ -5,6 +5,7 @@ using OASystem.Domain.Dtos.Groups;
 using OASystem.Domain.Entities.Groups;
 using OASystem.Domain.Entities.Groups;
 using OASystem.Domain.ViewModels.Groups;
 using OASystem.Domain.ViewModels.Groups;
 using OASystem.Infrastructure.Repositories.Groups;
 using OASystem.Infrastructure.Repositories.Groups;
+using static OpenAI.GPT3.ObjectModels.SharedModels.IOpenAiModels;
 
 
 namespace OASystem.API.Controllers
 namespace OASystem.API.Controllers
 {
 {
@@ -19,13 +20,15 @@ namespace OASystem.API.Controllers
         private readonly IMapper _mapper;
         private readonly IMapper _mapper;
         private readonly DelegationInfoRepository _groupRepository;
         private readonly DelegationInfoRepository _groupRepository;
         private readonly TaskAssignmentRepository _taskAssignmentRep;
         private readonly TaskAssignmentRepository _taskAssignmentRep;
+        private readonly AirTicketResRepository _airTicketResRep;
 
 
-        public GroupsController(IMapper mapper, GrpScheduleRepository grpScheduleRep, DelegationInfoRepository groupRepository, TaskAssignmentRepository taskAssignmentRep)
+        public GroupsController(IMapper mapper, GrpScheduleRepository grpScheduleRep, DelegationInfoRepository groupRepository, TaskAssignmentRepository taskAssignmentRep, AirTicketResRepository airTicketResRep)
         {
         {
             _mapper = mapper;
             _mapper = mapper;
             _grpScheduleRep = grpScheduleRep;
             _grpScheduleRep = grpScheduleRep;
             _groupRepository = groupRepository;
             _groupRepository = groupRepository;
             _taskAssignmentRep = taskAssignmentRep;
             _taskAssignmentRep = taskAssignmentRep;
+            _airTicketResRep = airTicketResRep;
         }
         }
 
 
         #region 流程管控
         #region 流程管控
@@ -505,5 +508,57 @@ namespace OASystem.API.Controllers
         }
         }
 
 
         #endregion
         #endregion
+
+        #region 机票费用录入
+        /// <summary>
+        /// 机票录入当前登录人可操作团组
+        /// </summary>
+        /// <param name="dto"></param>
+        /// <returns></returns>
+        [HttpPost]
+        [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
+        public async Task<IActionResult> AirTicketResSelect(AirTicketResDto dto)
+        {
+            try
+            {
+                Result groupData = await _airTicketResRep.AirTicketResSelect(dto);
+                if (groupData.Code != 0)
+                {
+                    return Ok(JsonView(false, groupData.Msg));
+                }
+                return Ok(JsonView(true, groupData.Msg, groupData.Data));
+            }
+            catch (Exception ex)
+            {
+                return Ok(JsonView(false, "程序错误!"));
+                throw;
+            }
+        }
+        /// <summary>
+        /// 机票费用录入列表
+        /// </summary>
+        /// <param name="dto"></param>
+        /// <returns></returns>
+        [HttpPost]
+        [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
+        public async Task<IActionResult> AirTicketResList(AirTicketResListDto dto)
+        {
+            try
+            {
+                Result groupData = await _airTicketResRep.AirTicketResList(dto);
+                if (groupData.Code != 0)
+                {
+                    return Ok(JsonView(false, groupData.Msg));
+                }
+                return Ok(JsonView(true, groupData.Msg, groupData.Data));
+            }
+            catch (Exception ex)
+            {
+                return Ok(JsonView(false, "程序错误!"));
+                throw;
+            }
+        }
+
+        #endregion
     }
     }
 }
 }

+ 13 - 3
OASystem/OASystem.Api/Controllers/MarketCustomerResourcesController.cs

@@ -25,15 +25,25 @@ namespace OASystem.API.Controllers
         [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
         [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
         public async Task<IActionResult> QueryNewClientData(NewClientDataQueryDto dto)
         public async Task<IActionResult> QueryNewClientData(NewClientDataQueryDto dto)
         {
         {
+            JsonView jw = new JsonView();
             try
             try
             {
             {
-                Result resTable = await _clientDataRepository.QueryNewClientData(dto);
-                return Ok(JsonView(true, resTable.Msg, resTable.Data));
+                Result resultData = await _clientDataRepository.QueryNewClientData(dto);
+                if (resultData.Code == 0)
+                {
+                    jw = JsonView(true, resultData.Msg, resultData.Data);
+                }
+                else
+                {
+                    jw = JsonView(false, resultData.Msg, resultData.Data);
+                }
             }
             }
             catch (Exception)
             catch (Exception)
             {
             {
-                return Ok(JsonView(false, "程序错误!"));
+                jw = JsonView(false, "程序错误!");
             }
             }
+
+            return Ok(jw);
         }
         }
         /// <summary>
         /// <summary>
         /// 客户资料操作(Status:1.新增,2.修改)
         /// 客户资料操作(Status:1.新增,2.修改)

+ 127 - 1
OASystem/OASystem.Api/Controllers/ResourceController.cs

@@ -21,11 +21,12 @@ namespace OASystem.API.Controllers
         private readonly SetDataRepository _setDataRepository;
         private readonly SetDataRepository _setDataRepository;
         private readonly CountryFeeRepository _countryFeeRep;
         private readonly CountryFeeRepository _countryFeeRep;
         private readonly SetDataTypeRepository _setDataTypeRep;
         private readonly SetDataTypeRepository _setDataTypeRep;
+        private readonly AirTicketAgentRepository _airTicketAgentRep;
 
 
         public ResourceController(IMapper mapper, IConfiguration config, CarDataRepository carDataRep,
         public ResourceController(IMapper mapper, IConfiguration config, CarDataRepository carDataRep,
             LocalGuideDataRepository localGuideDataRep, ThreeCodeRepository threeCodeRep,
             LocalGuideDataRepository localGuideDataRep, ThreeCodeRepository threeCodeRep,
             HotelDataRepository hotelDataRep, ResItemInfoRepository resItemInfoRep, SetDataRepository setDataRepository,
             HotelDataRepository hotelDataRep, ResItemInfoRepository resItemInfoRep, SetDataRepository setDataRepository,
-            CountryFeeRepository countryFeeRep, SetDataTypeRepository setDataTypeRep)
+            CountryFeeRepository countryFeeRep, SetDataTypeRepository setDataTypeRep, AirTicketAgentRepository airTicketAgentRep)
         {
         {
             _mapper = mapper;
             _mapper = mapper;
             _config = config;
             _config = config;
@@ -37,6 +38,7 @@ namespace OASystem.API.Controllers
             _setDataRepository = setDataRepository;
             _setDataRepository = setDataRepository;
             _countryFeeRep = countryFeeRep;
             _countryFeeRep = countryFeeRep;
             _setDataTypeRep = setDataTypeRep;
             _setDataTypeRep = setDataTypeRep;
+            _airTicketAgentRep = airTicketAgentRep;
         }
         }
 
 
 
 
@@ -498,6 +500,127 @@ namespace OASystem.API.Controllers
         }
         }
         #endregion
         #endregion
 
 
+        #region 代理出票合作方资料
+        /// <summary>
+        /// 代理出票合作方资料
+        /// </summary>
+        /// <param name="dto"></param>
+        /// <returns></returns>
+        [HttpPost]
+        [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
+        public async Task<IActionResult> QueryAirTicketAgent(DtoBase dto)
+        {
+
+            try
+            {
+                List<Res_AirTicketAgent> res_AirTicketAgents = _airTicketAgentRep.Query<Res_AirTicketAgent>(a => a.IsDel == 0).ToList();
+                if (res_AirTicketAgents.Count != 0)
+                {
+                    res_AirTicketAgents = res_AirTicketAgents.OrderByDescending(a => a.CreateTime).ToList();
+                    if (dto.PageSize == 0 && dto.PageIndex == 0)
+                    {
+                        return Ok(JsonView(true, "查询成功!", res_AirTicketAgents));
+                    }
+                    else
+                    {
+                        int count = res_AirTicketAgents.Count;
+                        float totalPage = (float)count / dto.PageSize;//总页数
+                        if (totalPage == 0) totalPage = 1;
+                        else totalPage = (int)Math.Ceiling((double)totalPage);
+
+                        List<Res_AirTicketAgent> _AirTicketAgent = new List<Res_AirTicketAgent>();
+                        for (int i = 0; i < dto.PageSize; i++)
+                        {
+                            var RowIndex = i + (dto.PageIndex - 1) * dto.PageSize;
+                            if (RowIndex < res_AirTicketAgents.Count)
+                            {
+                                _AirTicketAgent.Add(res_AirTicketAgents[RowIndex]);
+                            }
+                            else
+                            {
+                                break;
+                            }
+                        }
+                        return Ok(JsonView(true, "查询成功!",new { pageCount = count, totalPage = (int)totalPage, pageIndex = dto.PageIndex, pageSize = dto.PageSize, pageSource = _AirTicketAgent }));
+                       
+                    }
+                }
+                else
+                {
+                    return Ok(JsonView(false, "暂无数据!"));
+                }
+                
+            }
+            catch (Exception ex)
+            {
+                return Ok(JsonView(false, "程序错误!"));
+                throw;
+            }
+        }
+        /// <summary>
+        /// 代理出票合作方资料操作(Status:1.新增,2.修改)
+        /// </summary>
+        /// <param name="dto"></param>
+        /// <returns></returns>
+        [HttpPost]
+        [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
+        public async Task<IActionResult> OpAirTicketAgent(OpAirTicketAgentDto dto)
+        {
+            try
+            {
+                
+                if (dto.Account == "")
+                {
+                    return Ok(JsonView(false, "请检查代理商账户是否填写!"));
+                }
+                if (dto.Bank == "")
+                {
+                    return Ok(JsonView(false, "请检查代理商银行是否填写!"));
+                }
+                if (dto.Name == "")
+                {
+                    return Ok(JsonView(false, "请检查代理商名称是否填写正确!"));
+                }
+                Result result = await _airTicketAgentRep.OpAirTicketAgent(dto);
+                if (result.Code != 0)
+                {
+                    return Ok(JsonView(false, result.Msg));
+                }
+                return Ok(JsonView(true, result.Msg));
+            }
+            catch (Exception ex)
+            {
+                return Ok(JsonView(false, "程序错误!"));
+                throw;
+            }
+        }
+
+        /// <summary>
+        /// 代理出票合作方资料操作(删除)
+        /// </summary>
+        /// <returns></returns>
+        [HttpPost]
+        [ProducesResponseType(typeof(JsonView), StatusCodes.Status200OK)]
+        public async Task<IActionResult> DelAirTicketAgent(DelBaseDto dto)
+        {
+            try
+            {
+                var res = await _airTicketAgentRep.SoftDeleteByIdAsync<Res_AirTicketAgent>(dto.Id.ToString(), dto.DeleteUserId);
+                if (!res)
+                {
+                    return Ok(JsonView(false, "删除失败"));
+                }
+                return Ok(JsonView(true, "删除成功!"));
+            }
+            catch (Exception ex)
+            {
+                return Ok(JsonView(false, "程序错误!"));
+                throw;
+            }
+        }
+
+        #endregion
+
         #region 酒店资料数据
         #region 酒店资料数据
         /// <summary>
         /// <summary>
         /// 酒店信息查询
         /// 酒店信息查询
@@ -510,6 +633,7 @@ namespace OASystem.API.Controllers
         {
         {
             try
             try
             {
             {
+
                 Result hotelData = await _hotelDataRep.QueryHotelData(dto);
                 Result hotelData = await _hotelDataRep.QueryHotelData(dto);
                 if (hotelData.Code == 0)
                 if (hotelData.Code == 0)
                 {
                 {
@@ -1222,6 +1346,8 @@ Inner Join Sys_Department as d With(Nolock) On u.DepId=d.Id Where m.Id={0} ", _m
         }
         }
 
 
         #endregion
         #endregion
+
+       
     }
     }
 
 
 
 

+ 36 - 14
OASystem/OASystem.Api/Controllers/SmallFunController.cs

@@ -190,20 +190,42 @@ namespace OASystem.API.Controllers
                 return Ok(JsonView(false,"待自动补全的文本为空!"));
                 return Ok(JsonView(false,"待自动补全的文本为空!"));
             }
             }
 
 
-            Stopwatch sw = new Stopwatch();
-            sw.Start();
-            Thread.Sleep(999);
-            Console.WriteLine($"程序耗时:{sw.ElapsedMilliseconds}ms.");
-
-            var data = await ChatGPTTools.Completions(dto.Prompt);
-
-            sw.Stop();
-            if (data == null || data.Code != 0)
-            {
-                return Ok(JsonView(false, data.Msg+"【耗时:"+ sw.ElapsedMilliseconds/1000+ "ms】"));
-            }
-
-            return Ok(JsonView(200,  "【耗时:"+ sw.ElapsedMilliseconds/1000 + "s】", data.Data));
+            //Stopwatch sw = new Stopwatch();
+            //sw.Start();
+            //Thread.Sleep(999);
+            //Console.WriteLine($"程序耗时:{sw.ElapsedMilliseconds}ms.");
+
+           // var data = await ChatGPTTools.Completions(dto.Prompt);
+
+            //sw.Stop();
+            //if (data == null || data.Code != 0)
+            //{
+                 // return Ok(JsonView(false, data.Msg+"【耗时:"+ sw.ElapsedMilliseconds/1000+ "ms】"));
+                 //return Ok(JsonView(false, data.Msg ));
+            //}
+            string msg = @"前言
+人工智能领域的发展历程已经为我们带来了很多尖端技术,例如深度学习、自然语言处理等等。其中,GPT(Generative Pre-training Transformer)是一种基于Transformer架构的预训练语言模型,已经在语音识别、机器翻译、语言生成等领域得到广泛应用。本文将从GPT的基本原理、GPT的优缺点、GPT的应用等多个方面来展开探讨。
+GPT的基本原理
+GPT是语言模型的一种形式,它是由OpenAI实验室在2018年提出的。它是基于Transformer架构的预训练语言模型,并且通过处理大量的非标记语料来进行训练。GPT采用了单向的、基于自回归的方式来预测生成下一个单词的概率,也就是说,当输入前面的句子时,GPT可以预测下一个最有可能出现的单词是什么。
+GPT模型的主要组成部分是一个由多个层级堆叠而成的Transformer编码器,与其他基于Transformer的模型一样,它将输入序列转换为隐藏表示,再将其用于下游任务。每个GPT模型都有多个不同的版本,这些版本使用不同数量的层、不同数量的参数来进行训练。
+GPT的优缺点
+1、优点
+首先, GPT模型可以利用大量的非标记语料来进行预训练,这种预训练可以使得模型更好地理解自然语言,并且提高模型在语言生成等任务中的性能。
+其次,GPT模型使用了基于自回归的方式来进行预测,这使得模型在生成文本时具有一定的连贯性和可读性,从而提高了生成文本的质量。
+最后,GPT模型采用了Transformer架构来进行编码,这种编码方式不仅可以很好地处理长文本,而且还可以自适应地调节文本中不同单词之间的重要性,从而提高了模型的性能。
+2、缺点
+虽然GPT模型有很多优点,但是它也存在一些缺点。最明显的一个问题是GPT模型依赖于大量的训练数据,这使得它无法处理那些对数据需求比较大的应用场景。此外,由于GPT是一个生成式模型,因此在生成文本时,它也可能会出现重复、无意义的情况,这也是需要改进的地方。
+GPT的应用
+GPT的应用领域是很广泛的,下面我们将从自然语言处理、机器翻译、问答系统、语音识别等方面来进行介绍。
+1、自然语言处理
+GPT的应用最为广泛的领域之一就是自然语言处理。例如,它可以用于语言模型、文本分类、情感分析等等。其中,语言模型是GPT最基本的应用之一,它可以对一段文本中的下一个单词进行预测。
+2、机器翻译
+机器翻译是另一个GPT的应用领域,它可以将一种语言的文本转换为另一种语言的文本。使用GPT进行机器翻译的一个好处是可以在源语言和目标语言之间进行平滑的转换,从而提高翻译的质量。
+3、问答系统
+GPT可以用于构建问答系统,其基本原理是通过学习训练数据中的问题和答案,将问题转换为特定领域的答案。当输入一个问题时,GPT可以预测出最有可能的答案,从而提高问答系统的质量。
+4、语音识别
+GPT也可以用于语音识别,其原理与文本生成类似。使用GPT进行语音识别的一个好处是可以进行语音到文本的转化,从而将语音转化为可观看的文本内容。";
+            return Ok(JsonView(200,  " ", msg));
         }
         }
 
 
 
 

+ 48 - 3
OASystem/OASystem.Api/OAMethodLib/File/AsposeHelper.cs

@@ -119,7 +119,8 @@ namespace OASystem.API.OAMethodLib.File
                     {
                     {
                         if (item.Rows.Count > 0)
                         if (item.Rows.Count > 0)
                         {
                         {
-                            designer.SetDataSource(item.TableName, item);
+                            //designer.SetDataSource(item.TableName, item);
+                            designer.SetDataSource(item);
                         }
                         }
                     }
                     }
                 }
                 }
@@ -141,11 +142,12 @@ namespace OASystem.API.OAMethodLib.File
                 {
                 {
                     System.IO.Directory.CreateDirectory(path);//不存在就创建文件夹
                     System.IO.Directory.CreateDirectory(path);//不存在就创建文件夹
                 }
                 }
-                string saveFilePath = string.Format("{0}{1}", path, saveFilName);
+                string saveFilePath = string.Format("{0}/{1}", path, saveFilName);
 
 
                 //保存合并后的文档
                 //保存合并后的文档
                 wbook.Save(saveFilePath);
                 wbook.Save(saveFilePath);
-                saveFilePath = saveFilePath.Replace("C:", AppSettingsHelper.Get("OfficeBaseUrl")); //返回下载地址
+                //saveFilePath = saveFilePath.Replace("C:/Server/File/0A2023/", AppSettingsHelper.Get("OfficeBaseUrl")); //返回下载地址
+                saveFilePath = AppSettingsHelper.Get("OfficeBaseUrl") + "/Office/Excel/" + saveFolderName + "/" + saveFilName;
                 return saveFilePath; //返回下载地址
                 return saveFilePath; //返回下载地址
             }
             }
             catch (Exception ex)
             catch (Exception ex)
@@ -156,5 +158,48 @@ namespace OASystem.API.OAMethodLib.File
 
 
         #endregion
         #endregion
 
 
+        #region List<T> 转 Datatbale
+
+        /// <summary>
+        /// 将List转换为DataTable
+        /// </summary>
+        /// <param name="newTableName">newTableName</param>
+        /// <param name="list">请求数据</param>
+        /// <returns></returns>
+        public static DataTable ListToDataTable<T>(string newTableName, List<T> list)
+        {
+            //创建一个名为"tableName"的空表
+            DataTable dt = new DataTable(newTableName);
+
+            //创建传入对象名称的列
+            foreach (var item in list.FirstOrDefault().GetType().GetProperties())
+            {
+                dt.Columns.Add(item.Name);
+            }
+            //循环存储
+            foreach (var item in list)
+            {
+                //新加行
+                DataRow value = dt.NewRow();
+                //根据DataTable中的值,进行对应的赋值
+                foreach (DataColumn dtColumn in dt.Columns)
+                {
+                    int i = dt.Columns.IndexOf(dtColumn);
+                    //基元元素,直接复制,对象类型等,进行序列化
+                    if (value.GetType().IsPrimitive)
+                    {
+                        value[i] = item.GetType().GetProperty(dtColumn.ColumnName).GetValue(item);
+                    }
+                    else
+                    {
+                        value[i] = JsonConvert.SerializeObject(item.GetType().GetProperty(dtColumn.ColumnName).GetValue(item));
+                    }
+                }
+                dt.Rows.Add(value);
+            }
+            return dt;
+        }
+
+        #endregion
     }
     }
 }
 }

+ 5 - 0
OASystem/OASystem.Domain/AutoMappers/_baseMappingProfile.cs

@@ -16,6 +16,7 @@ using OASystem.Domain.ViewModels.System;
 using OASystem.Domain.Dtos.Financial;
 using OASystem.Domain.Dtos.Financial;
 using OASystem.Domain.Entities.Financial;
 using OASystem.Domain.Entities.Financial;
 using static OASystem.Domain.Dtos.CRM.NewClientDataQueryDto;
 using static OASystem.Domain.Dtos.CRM.NewClientDataQueryDto;
+using OASystem.Domain.ViewModels.Groups;
 
 
 namespace OASystem.Domain.AutoMappers
 namespace OASystem.Domain.AutoMappers
 {
 {
@@ -75,6 +76,7 @@ namespace OASystem.Domain.AutoMappers
             CreateMap<Grp_ScheduleDetailUpdDto, Grp_ScheduleDetailInfo>();
             CreateMap<Grp_ScheduleDetailUpdDto, Grp_ScheduleDetailInfo>();
             CreateMap<Grp_ScheduleDetailInsertDto, Grp_ScheduleDetailInfo>();
             CreateMap<Grp_ScheduleDetailInsertDto, Grp_ScheduleDetailInfo>();
             CreateMap<TaskAssignmenDto, Grp_GroupsTaskAssignment>();
             CreateMap<TaskAssignmenDto, Grp_GroupsTaskAssignment>();
+            CreateMap<Grp_GroupCostParameter,AirGroupCostParameterView>();
             #endregion
             #endregion
 
 
             #region Resource
             #region Resource
@@ -92,6 +94,9 @@ namespace OASystem.Domain.AutoMappers
             CreateMap<Res_ThreeCode, ThreeCodeView>();
             CreateMap<Res_ThreeCode, ThreeCodeView>();
             CreateMap<ThreeCodeOperationDto, Res_ThreeCode>();
             CreateMap<ThreeCodeOperationDto, Res_ThreeCode>();
             #endregion
             #endregion
+            #region 代理商合作资料
+            CreateMap<OpAirTicketAgentDto, Res_AirTicketAgent>();
+            #endregion
             #region 酒店资料数据
             #region 酒店资料数据
             CreateMap<Res_HotelData, HotelDataView>();
             CreateMap<Res_HotelData, HotelDataView>();
             CreateMap<Res_HotelData, QueryHotelDataSelect>();
             CreateMap<Res_HotelData, QueryHotelDataSelect>();

+ 18 - 0
OASystem/OASystem.Domain/Dtos/Groups/AirTicketResDto.cs

@@ -0,0 +1,18 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace OASystem.Domain.Dtos.Groups
+{
+    public class AirTicketResDto
+    {
+        public int UserId { get; set; }
+    }
+
+    public class AirTicketResListDto
+    {
+        public int DiId { get; set; }
+    }
+}

+ 43 - 0
OASystem/OASystem.Domain/Dtos/Resource/OpAirTicketAgentDto.cs

@@ -0,0 +1,43 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace OASystem.Domain.Dtos.Resource
+{
+    public class OpAirTicketAgentDto
+    {
+        /// <summary>
+        /// 操作状态
+        /// 1 添加 
+        /// 2 修改 
+        /// </summary>
+        public int Status { get; set; }
+        /// <summary>
+        /// 编号
+        /// </summary>
+        public int Id { get; set; }
+
+        /// <summary>
+        /// 代理商名称
+        /// </summary>
+        public string Name { get; set; }
+        /// <summary>
+        /// 代理商账户
+        /// </summary>
+        public string Account { get; set; }
+        /// <summary>
+        /// 代理商银行
+        /// </summary>
+        public string Bank { get; set; }
+        /// <summary>
+        /// 创建者Id
+        /// </summary>
+        public int CreateUserId { get; set; }
+        /// <summary>
+        /// 备注
+        /// </summary>
+        public string Remark { get; set; }
+    }
+}

+ 130 - 0
OASystem/OASystem.Domain/Entities/Groups/Grp_AirTicketReservations.cs

@@ -0,0 +1,130 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace OASystem.Domain.Entities.Groups
+{
+
+    /// <summary>
+    /// 机票费用录入
+    /// </summary>
+    [SugarTable("Grp_AirTicketReservations")]
+    public class Grp_AirTicketReservations : EntityBase
+    {
+        /// <summary>
+        /// 团组外键编号
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int DIId { get; set; }
+        /// <summary>
+        /// 航班号
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "varchar(100)")]
+        public string FlightsCode { get; set; }
+
+        /// <summary>
+        /// 航班日期
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "varchar(22)")]
+        public string FlightsDate { get; set; }
+
+        /// <summary>
+        /// 航班时间
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "varchar(22)")]
+        public string FlightsTime { get; set; }
+        /// <summary>
+        /// 抵达时间
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "varchar(22)")]
+        public string ArrivedTime { get; set; }
+        /// <summary>
+        /// 是否值机
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int IsCheckIn { get; set; }
+        /// <summary>
+        /// 是否选座
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int IsSetSeat { get; set; }
+
+        /// <summary>
+        /// 是否购买行李服务
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int IsPackage { get; set; }
+        /// <summary>
+        /// 是否行李直挂
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int IsBagHandle { get; set; }
+        /// <summary>
+        /// 是否火车票出票选座
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int IsTrain { get; set; }
+        /// <summary>
+        /// 城市A-B
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "varchar(100)")]
+        public string FlightsCity { get; set; }
+        /// <summary>
+        /// 去程航班描述代码
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "text")]
+        public string LeaveDescription { get; set; }
+        /// /// <summary>
+        /// 内陆段航班描述
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "text")]
+        public string FlightsDescription { get; set; }
+        /// <summary>
+        /// 返程航班描述代码
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "text")]
+        public string ReturnDescription { get; set; }
+        /// <summary>
+        /// 客户人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int ClientNum { get; set; }
+        /// <summary>
+        /// 客人名称
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "text")]
+        public string ClientName { get; set; }
+        /// <summary>
+        /// 出票前报价
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal PrePrice { get; set; }
+        /// <summary>
+        /// 出票前报价币种
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int PreCurrency { get; set; }
+        /// <summary>
+        /// 机票全价
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal Price { get; set; }
+        /// <summary>
+        /// 币种
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int Currency { get; set; }
+        /// <summary>
+        /// 报价说明
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "text")]
+        public string PriceDescription { get; set; }
+        /// <summary>
+        /// 舱类型
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int CType { get; set; }
+    }
+}

+ 257 - 0
OASystem/OASystem.Domain/Entities/Groups/Grp_GroupCostParameter.cs

@@ -0,0 +1,257 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace OASystem.Domain.Entities.Groups
+{
+    /// <summary>
+    /// 团组成本预算表
+    /// </summary>
+    [SugarTable("Grp_GroupCostParameter")]
+    public class Grp_GroupCostParameter:EntityBase
+    {
+        /// <summary>
+        /// 团组ID
+        /// </summary>
+        [SugarColumn(IsNullable =true,ColumnDataType ="int")]
+        public int DiId { get; set; }
+        /// <summary>
+        /// 币种
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "varchar(50)")]
+        public string Currency { get; set; }
+        /// <summary>
+        /// 汇率
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal Rate { get; set; }
+        /// <summary>
+        /// 税率
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal Tax { get; set; }
+        /// <summary>
+        /// 房费预算
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal FFYS { get; set; }
+        /// <summary>
+        /// 酒店系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal HotelXS { get; set; }
+        /// <summary>
+        /// 经济舱成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal JJCCB { get; set; }
+        /// <summary>
+        /// 经济舱系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal JJCXS { get; set; }
+        /// <summary>
+        /// 经济舱人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int JJCRS { get; set; }
+        /// <summary>
+        /// 公务舱成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal GWCCB { get; set; }
+        /// <summary>
+        /// 公务舱系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal GWCXS { get; set; }
+        /// <summary>
+        /// 公务舱人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int GWCRS { get; set; }
+        /// <summary>
+        /// 火车票成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal HCPCB { get; set; }
+        /// <summary>
+        /// 火车票系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal HCPXS { get; set; }
+        /// <summary>
+        /// 火车票人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int HCPRS { get; set; }
+        /// <summary>
+        /// 船票成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal CPCB { get; set; }
+        /// <summary>
+        /// 船票系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal CPXS { get; set; }
+        /// <summary>
+        /// 船票人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int CPRS { get; set; }
+        /// <summary>
+        /// 保险成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal BXCB { get; set; }
+        /// <summary>
+        /// 保险系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal BXXS { get; set; }
+        /// <summary>
+        /// 保险人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int BXRS { get; set; }
+        /// <summary>
+        /// 核酸检测成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal HSCB { get; set; }
+        /// <summary>
+        /// 核酸检测系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal HSXS { get; set; }
+        /// <summary>
+        /// 核酸检测人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int HSRS { get; set; }
+        /// <summary>
+        /// 签证成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal VisaCB { get; set; }
+        /// <summary>
+        /// 签证系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal VisaXS { get; set; }
+        /// <summary>
+        /// 签证人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int VisaRS { get; set; }
+        /// <summary>
+        /// 公务成本 : 公杂费
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal GWCB { get; set; }
+        /// <summary>
+        /// 公务系数: 公杂费
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal GWXS { get; set; }
+        /// <summary>
+        /// 公务人数 : 公杂费
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int GWRS { get; set; }
+        /// <summary>
+        /// 地接成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal DJCB { get; set; }
+        /// <summary>
+        /// 地接系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal DJXS { get; set; }
+        /// <summary>
+        /// 单间 单人成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal SGRCB { get; set; }
+        /// <summary>
+        /// 单间数量(人数)
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int SGRNumber { get; set; }
+        /// <summary>
+        /// 单间 系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal SGRXS { get; set; }
+        /// <summary>
+        /// 1/2标间 单人成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal TBRCB { get; set; }
+        /// <summary>
+        /// 1/2标间数量(人数)
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int TBRNumber { get; set; }
+        /// <summary>
+        /// 1/2标间  系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal TBRXS { get; set; }
+        /// <summary>
+        /// 小套房/豪华套房 单人成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal JSESCB { get; set; }
+        /// <summary>
+        /// 小套房/豪华套房数量(人数)
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int JSESNumber { get; set; }
+        /// <summary>
+        /// 小套房/豪华套房 系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal JSESXS { get; set; }
+        /// <summary>
+        /// 套房  单人成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal SUITECB { get; set; }
+        /// <summary>
+        /// 套房数量(人数)
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int SUITENumber { get; set; }
+        /// <summary>
+        /// 套房  单人成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal SUITEXS { get; set; }
+        /// <summary>
+        /// 零用金成本
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal LYJCB { get; set; }
+        /// <summary>
+        /// 零用金系数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "decimal(10,2)")]
+        public decimal LYJXS { get; set; }
+        /// <summary>
+        /// 零用金人数
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int LYJRS { get; set; }
+        /// <summary>
+        /// 成本完成标识  0:未完成 1:完成
+        /// </summary>
+        [SugarColumn(IsNullable = true, ColumnDataType = "int")]
+        public int IsShare { get; set; }
+        
+    }
+}

+ 37 - 0
OASystem/OASystem.Domain/ViewModels/Financial/Fin_DailyFeePaymentView.cs

@@ -165,6 +165,43 @@ namespace OASystem.Domain.ViewModels.Financial
         public string Instructions { get; set; }
         public string Instructions { get; set; }
         public decimal SumPrice { get; set; }
         public decimal SumPrice { get; set; }
 
 
+        public int CreateUserId { get; set; }
+
+        /// <summary>
+        /// 财务审核
+        /// </summary>
+        public int FAudit { get; set; }
+
+        public string FAuditDesc
+        {
+            get
+            {
+                string str = "未审核";
+                if (FAudit == 0) str = "未审核";
+                else if (FAudit == 1) str = "已通过";
+                else if (FAudit == 2) str = "未通过";
+                return str;
+            }
+        }
+
+        /// <summary>
+        /// 总经理审核
+        /// </summary>
+        public int MAudit { get; set; }
+
+        public string MAuditDesc
+        {
+            get
+            {
+                string str = "未审核";
+                if (MAudit == 0) str = "未审核";
+                else if (MAudit == 1) str = "已通过";
+                else if (MAudit == 2) str = "未通过";
+                return str;
+            }
+        }
+
+        public DateTime CreateTime { get; set; }
         public List<Fin_DailyFeePaymentContentInfolView> FeeContents { get; set; }
         public List<Fin_DailyFeePaymentContentInfolView> FeeContents { get; set; }
     }
     }
 
 

+ 53 - 0
OASystem/OASystem.Domain/ViewModels/Groups/AirTicketReservationsView.cs

@@ -0,0 +1,53 @@
+using OASystem.Domain.Entities.Groups;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace OASystem.Domain.ViewModels.Groups
+{
+    public class AirTicketReservationsView:Grp_AirTicketReservations
+    {
+        /// <summary>
+        /// 总经理是否审核
+        /// </summary>
+        public int IsAuditGM { get; set; }
+        /// <summary>
+        /// 舱类型
+        /// </summary>
+        public string CTypeName { get; set; }
+        public string PreCurrencyStr { get; set; }
+        public string CurrencyStr { get; set; }
+
+        public string FlightDescription { get; set; }
+    }
+
+    public class AirGroupCostParameterView
+    {
+        /// <summary>
+        /// 经济舱成本
+        /// </summary>
+        public decimal JJCCB { get; set; }
+        /// <summary>
+        /// 经济舱系数
+        /// </summary>
+        public decimal JJCXS { get; set; }
+        /// <summary>
+        /// 经济舱人数
+        /// </summary>
+        public int JJCRS { get; set; }
+        /// <summary>
+        /// 公务舱成本
+        /// </summary>
+        public decimal GWCCB { get; set; }
+        /// <summary>
+        /// 公务舱系数
+        /// </summary>
+        public decimal GWCXS { get; set; }
+        /// <summary>
+        /// 公务舱人数
+        /// </summary>
+        public int GWCRS { get; set; }
+    }
+}

+ 3 - 3
OASystem/OASystem.Infrastructure/Repositories/CRM/NewClientDataRepository.cs

@@ -47,7 +47,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                 #region 负责人
                 #region 负责人
                 if (!string.IsNullOrWhiteSpace(dto.Userid))
                 if (!string.IsNullOrWhiteSpace(dto.Userid))
                 {
                 {
-                    string sql = string.Format(@"select u1.UsersId,u2.CnName,u1.NewClientDataId from Crm_ClientDataAndUser u1,Sys_Users u2 where u1.UsersId=u2.Id and u1.UsersId in ({0})", dto.Userid);
+                    string sql = string.Format(@"select u1.UsersId,u2.CnName,u1.NewClientDataId from Crm_ClientDataAndUser u1,Sys_Users u2 where u1.UsersId=u2.Id and u1.UsersId in ({0})  and u1.IsDel = 0", dto.Userid);
                     List<AscribedUser> ascribedUsers = await _sqlSugar.SqlQueryable<AscribedUser>(sql).ToListAsync();
                     List<AscribedUser> ascribedUsers = await _sqlSugar.SqlQueryable<AscribedUser>(sql).ToListAsync();
                     if (ascribedUsers.Count != 0)
                     if (ascribedUsers.Count != 0)
                     {
                     {
@@ -70,7 +70,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                 #region 业务归属
                 #region 业务归属
                 if (!string.IsNullOrWhiteSpace(dto.Business))
                 if (!string.IsNullOrWhiteSpace(dto.Business))
                 {
                 {
-                    string sql = string.Format(@"select d1.*,d2.Name from Crm_ClientDataAndBusiness d1,Sys_SetData d2 where d1.SetDataId=d2.Id and d1.SetDataId in ({0})", dto.Business);
+                    string sql = string.Format(@"select d1.*,d2.Name from Crm_ClientDataAndBusiness d1,Sys_SetData d2 where d1.SetDataId=d2.Id and d1.SetDataId in ({0}) and d1.isdel = 0", dto.Business);
                     List<AscribedDepartment> AscribedDepartment = await _sqlSugar.SqlQueryable<AscribedDepartment>(sql).ToListAsync();
                     List<AscribedDepartment> AscribedDepartment = await _sqlSugar.SqlQueryable<AscribedDepartment>(sql).ToListAsync();
                     if (AscribedDepartment.Count != 0)
                     if (AscribedDepartment.Count != 0)
                     {
                     {
@@ -294,7 +294,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                         List<dynamic> _ServiceClass = new List<dynamic>();
                         List<dynamic> _ServiceClass = new List<dynamic>();
                         List<Sys_SetData> ServiceClass = _sqlSugar.Queryable<Sys_SetData>()
                         List<Sys_SetData> ServiceClass = _sqlSugar.Queryable<Sys_SetData>()
                         .Where(u => u.STid == 36 && u.IsDel == 0).ToList();
                         .Where(u => u.STid == 36 && u.IsDel == 0).ToList();
-                        foreach (Sys_SetData item in province)
+                        foreach (Sys_SetData item in ServiceClass)
                         {
                         {
                             var data = new
                             var data = new
                             {
                             {

+ 10 - 0
OASystem/OASystem.Infrastructure/Repositories/CRM/VisaDeleClientRepository.cs

@@ -154,6 +154,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
            Result result = new Result() { Code = -2, Msg = "未知错误" };
            Result result = new Result() { Code = -2, Msg = "未知错误" };
             try
             try
             {
             {
+                BeginTran();
                 int deleId = 0;
                 int deleId = 0;
                 if (dto.Status==1)//添加
                 if (dto.Status==1)//添加
                 {
                 {
@@ -312,6 +313,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                             if (res==0)
                             if (res==0)
                             {
                             {
                                 result = new Result() { Code = -1, Msg = "家庭成员信息保存失败!" };
                                 result = new Result() { Code = -1, Msg = "家庭成员信息保存失败!" };
+                                RollbackTran();
                             }
                             }
                         }
                         }
                         else if (item.Id == 0)//添加
                         else if (item.Id == 0)//添加
@@ -320,6 +322,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                             if (sss == 0)
                             if (sss == 0)
                             {
                             {
                                 result = new Result() { Code = -1, Msg = "家庭成员信息保存失败!" };
                                 result = new Result() { Code = -1, Msg = "家庭成员信息保存失败!" };
+                                RollbackTran();
                             }
                             }
                         }
                         }
                     }
                     }
@@ -348,6 +351,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                             if (res == 0)
                             if (res == 0)
                             {
                             {
                                 result = new Result() { Code = -1, Msg = "证件信息保存失败!" };
                                 result = new Result() { Code = -1, Msg = "证件信息保存失败!" };
+                                RollbackTran();
                             }
                             }
                         }
                         }
                         else if (item.Id == 0)//添加
                         else if (item.Id == 0)//添加
@@ -356,6 +360,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                             if (sss == 0)
                             if (sss == 0)
                             {
                             {
                                 result = new Result() { Code = -1, Msg = "证件信息保存失败!" };
                                 result = new Result() { Code = -1, Msg = "证件信息保存失败!" };
+                                RollbackTran();
                             }
                             }
                         }
                         }
                     }
                     }
@@ -383,6 +388,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                             if (res == 0)
                             if (res == 0)
                             {
                             {
                                 result = new Result() { Code = -1, Msg = "客户工作经历保存失败!" };
                                 result = new Result() { Code = -1, Msg = "客户工作经历保存失败!" };
+                                RollbackTran();
                             }
                             }
                         }
                         }
                         else if (item.Id == 0)//添加
                         else if (item.Id == 0)//添加
@@ -391,6 +397,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                             if (sss == 0)
                             if (sss == 0)
                             {
                             {
                                 result = new Result() { Code = -1, Msg = "客户工作经历保存失败!" };
                                 result = new Result() { Code = -1, Msg = "客户工作经历保存失败!" };
+                                RollbackTran();
                             }
                             }
                         }
                         }
                     }
                     }
@@ -417,6 +424,7 @@ namespace OASystem.Infrastructure.Repositories.CRM
                             if (res == 0)
                             if (res == 0)
                             {
                             {
                                 result = new Result() { Code = -1, Msg = "客户学历信息保存失败!" };
                                 result = new Result() { Code = -1, Msg = "客户学历信息保存失败!" };
+                                RollbackTran();
                             }
                             }
                         }
                         }
                         else if (item.Id == 0)//添加
                         else if (item.Id == 0)//添加
@@ -425,9 +433,11 @@ namespace OASystem.Infrastructure.Repositories.CRM
                             if (sss == 0)
                             if (sss == 0)
                             {
                             {
                                 result = new Result() { Code = -1, Msg = "客户学历信息保存失败!" };
                                 result = new Result() { Code = -1, Msg = "客户学历信息保存失败!" };
+                                RollbackTran();
                             }
                             }
                         }
                         }
                     }
                     }
+                    CommitTran();
                 }
                 }
             }
             }
             catch (Exception ex)
             catch (Exception ex)

+ 30 - 8
OASystem/OASystem.Infrastructure/Repositories/Financial/DailyFeePaymentRepository.cs

@@ -2,12 +2,9 @@
 using OASystem.Domain;
 using OASystem.Domain;
 using OASystem.Domain.Dtos;
 using OASystem.Domain.Dtos;
 using OASystem.Domain.Dtos.Financial;
 using OASystem.Domain.Dtos.Financial;
-using OASystem.Domain.Dtos.UserDto;
 using OASystem.Domain.Entities.Financial;
 using OASystem.Domain.Entities.Financial;
-using OASystem.Domain.ViewModels;
 using OASystem.Domain.ViewModels.Financial;
 using OASystem.Domain.ViewModels.Financial;
 using OASystem.Infrastructure.Repositories.System;
 using OASystem.Infrastructure.Repositories.System;
-using Org.BouncyCastle.Asn1.Cms;
 using System;
 using System;
 using System.Collections.Generic;
 using System.Collections.Generic;
 using System.ComponentModel.Design;
 using System.ComponentModel.Design;
@@ -256,8 +253,6 @@ namespace OASystem.Infrastructure.Repositories.Financial
                 result.Msg = ex.Message;
                 result.Msg = ex.Message;
             }
             }
 
 
-
-
             return result;
             return result;
 
 
         }
         }
@@ -288,9 +283,34 @@ namespace OASystem.Infrastructure.Repositories.Financial
 
 
                 List<Fin_DailyFeePaymentContent> _feeContents = _mapper.Map<List<Fin_DailyFeePaymentContent>>(dto.FeeContents);
                 List<Fin_DailyFeePaymentContent> _feeContents = _mapper.Map<List<Fin_DailyFeePaymentContent>>(dto.FeeContents);
 
 
-                int? editFeeContsStatus = await _sqlSugar.Updateable(_feeContents)
-                    .UpdateColumns(a => new { a.PriceName, a.Price, a.Quantity, a.ItemTotal, a.Remark })
-                    .ExecuteCommandAsync();
+
+                await _sqlSugar.Updateable<Fin_DailyFeePaymentContent>()
+                                  .Where(a => a.DFPId == _fee.Id)
+                                  .SetColumns(a => new Fin_DailyFeePaymentContent
+                                  {
+                                      IsDel = 1,
+                                      DeleteUserId = _fee.CreateUserId,
+                                      DeleteTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"),
+                                  }).ExecuteCommandAsync();
+
+
+                if (_feeContents.Count > 0)
+                {
+                    foreach (var item in _feeContents)
+                    {
+
+                        item.DFPId = _fee.Id;
+                        item.CreateUserId = dto.UserId;
+
+                    }
+
+                    if (_feeContents.Count > 0)
+                    {
+                        await _sqlSugar.Insertable(_feeContents).ExecuteCommandAsync();
+
+                    }
+                }
+
                 _sqlSugar.CommitTran();
                 _sqlSugar.CommitTran();
                 result.Code = 0;
                 result.Code = 0;
             }
             }
@@ -365,5 +385,7 @@ namespace OASystem.Infrastructure.Repositories.Financial
             }
             }
             return result;
             return result;
         }
         }
+
+        
     }
     }
 }
 }

+ 73 - 0
OASystem/OASystem.Infrastructure/Repositories/Resource/AirTicketAgentRepository.cs

@@ -0,0 +1,73 @@
+using AutoMapper;
+using OASystem.Domain;
+using OASystem.Domain.Dtos.Resource;
+using OASystem.Domain.Entities.Resource;
+using OASystem.Domain.ViewModels.Resource;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace OASystem.Infrastructure.Repositories.Resource
+{
+    public class AirTicketAgentRepository : BaseRepository<Res_AirTicketAgent, Res_AirTicketAgent>
+    {
+        private readonly IMapper _mapper;
+        public AirTicketAgentRepository(SqlSugarClient sqlSugar, IMapper mapper) : base(sqlSugar)
+        {
+            _mapper = mapper;
+        }
+
+        public async Task<Result> OpAirTicketAgent(OpAirTicketAgentDto dto)
+        {
+            Result result = new Result() { Code = -2, Msg = "未知错误" };
+            try
+            {
+                if (dto.Status == 1)//添加
+                {
+                   Res_AirTicketAgent res_AirTicket=await Query<Res_AirTicketAgent>(a=>a.IsDel==0 && a.Account==dto.Account && a.Name==dto.Name && a.Bank==dto.Bank).FirstAsync();
+                    if (res_AirTicket!=null)
+                    {
+                        return result = new Result() { Code = -1, Msg = "该代理商已存在,请勿重复添加!" };
+                    }
+                    else
+                    {
+                        Res_AirTicketAgent _AirTicketAgent = _mapper.Map<Res_AirTicketAgent>(dto);
+                        int id = await AddAsyncReturnId(_AirTicketAgent);
+                        if (id == 0)
+                        {
+                            return result = new Result() { Code = -1, Msg = "添加失败!" };
+
+                        }
+                        return result = new Result() { Code = 0, Msg = "添加成功!", Data = new { Id = id } };
+                    }
+                }
+                else if (dto.Status == 2)//修改
+                {
+                    bool res = await UpdateAsync(a => a.Id == dto.Id, a => new Res_AirTicketAgent
+                    {
+                        Name = dto.Name,
+                        Bank = dto.Bank,
+                        Account = dto.Account,
+                        CreateUserId = dto.CreateUserId,
+                        Remark = dto.Remark,
+                    });
+                    if (!res)
+                    {
+                        return result = new Result() { Code = -1, Msg = "修改失败!" };
+                    }
+                    return result = new Result() { Code = 0, Msg = "修改成功!" };
+                }
+                else
+                {
+                    return result = new Result() { Code = -1, Msg = "请传入Status参数,1添加 2修改!" };
+                }
+            }
+            catch (Exception ex)
+            {
+                return result = new Result() { Code = -2, Msg = "程序错误!" };
+            }
+        }
+    }
+}

+ 226 - 0
OASystem/OASystem.Infrastructure/Repositories/Resource/AirTicketResRepository.cs

@@ -0,0 +1,226 @@
+using AutoMapper;
+using OASystem.Domain;
+using OASystem.Domain.Dtos.Groups;
+using OASystem.Domain.Entities.Groups;
+using OASystem.Domain.Entities.Resource;
+using OASystem.Domain.ViewModels.Groups;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Xml.Linq;
+
+namespace OASystem.Infrastructure.Repositories.Resource
+{
+    public class AirTicketResRepository : BaseRepository<Grp_AirTicketReservations, Grp_AirTicketReservations>
+    {
+        private readonly IMapper _mapper;
+        public AirTicketResRepository(SqlSugarClient sqlSugar, IMapper mapper) : base(sqlSugar)
+        {
+            _mapper = mapper;
+        }
+
+        public async Task<Result> AirTicketResList(AirTicketResListDto dto)
+        {
+            Result result = new Result() { Code = -2, Msg = "未知错误" };
+
+            Grp_DelegationInfo _DelegationInfo = _sqlSugar.Queryable<Grp_DelegationInfo>().First(it => it.Id == dto.DiId);
+            if (_DelegationInfo != null)
+            {
+                string sql = string.Format(@"select a.*,c.IsAuditGM,(select Name from Sys_SetData where Id=a.cType) as 'CTypeName',(select Name from 
+                                                Sys_SetData where Id=a.PreCurrency) as 'PreCurrencyStr',(select Name from Sys_SetData where Id=a.Currency)
+                                                as 'CurrencyStr' from Grp_AirTicketReservations a,Grp_CreditCardPayment c where  a.id=c.CId  and a.isdel={1}
+                                                and a.DIId={0} Order By a.CreateTime desc", dto.DiId, 0);
+                List<AirTicketReservationsView> _AirTicketReservations = _sqlSugar.SqlQueryable<AirTicketReservationsView>(sql).ToList();
+
+                foreach (var item in _AirTicketReservations)
+                {
+                    if (item.FlightsDescription.Contains("\r\n"))
+                    {
+                        var spilitArr = Regex.Split(item.FlightsDescription, "\r\n");
+                        int rowindex = 1;
+                        foreach (var spilitItem in spilitArr)
+                        {
+                            try
+                            {
+                                var spDotandEmpty = spilitItem.Split('.')[1].Split(' ').Where(x => !string.IsNullOrEmpty(x)).ToList();
+                                var depCode = spDotandEmpty[3].Substring(0, 3);
+                                var arrCode = spDotandEmpty[3].Substring(3, 3);
+                                Res_ThreeCode depData = _sqlSugar.Queryable<Res_ThreeCode>().First(it => it.IsDel == 0 && it.Three == depCode);
+                                Res_ThreeCode arrData = _sqlSugar.Queryable<Res_ThreeCode>().First(it => it.IsDel == 0 && it.Three == arrCode);
+
+                                string day = spDotandEmpty[2].Substring(2, 2);//日
+                                string monthAbbreviations = spDotandEmpty[1].Substring(4, 3).ToUpper();//月份
+                                switch (monthAbbreviations)
+                                {
+                                    case "JAN":
+                                        monthAbbreviations = "1";
+                                        break;
+                                    case "FEB":
+                                        monthAbbreviations = "2";
+                                        break;
+                                    case "MAR":
+                                        monthAbbreviations = "3";
+                                        break;
+                                    case "APR":
+                                        monthAbbreviations = "4";
+                                        break;
+                                    case "MAY":
+                                        monthAbbreviations = "5";
+                                        break;
+                                    case "JUN":
+                                        monthAbbreviations = "6";
+                                        break;
+                                    case "JUL":
+                                        monthAbbreviations = "7";
+                                        break;
+                                    case "AUG":
+                                        monthAbbreviations = "8";
+                                        break;
+                                    case "SEP":
+                                        monthAbbreviations = "9";
+                                        break;
+                                    case "OCT":
+                                        monthAbbreviations = "10";
+                                        break;
+                                    case "NOV":
+                                        monthAbbreviations = "11";
+                                        break;
+                                    case "DEC":
+                                        monthAbbreviations = "12";
+                                        break;
+                                }
+                                string tate = $"{monthAbbreviations}月{day}日";
+                                item.FlightDescription += rowindex + ". " + depData.AirPort + " " + arrData.AirPort + "  (" + tate + ")\r\n";
+                            }
+                            catch (Exception)
+                            {
+                                item.FlightDescription = "录入数据不规范!请检查";
+                                break;
+                            }
+                            rowindex++;
+                        }
+                    }
+                    else
+                    {
+                        try
+                        {
+                            var spDotandEmpty = item.FlightsDescription.Split('.')[1].Split(' ').Where(x => !string.IsNullOrEmpty(x)).ToList();
+                            var depCode = spDotandEmpty[3].Substring(0, 3);
+                            var arrCode = spDotandEmpty[3].Substring(3, 3);
+                            Res_ThreeCode depData = _sqlSugar.Queryable<Res_ThreeCode>().First(it => it.IsDel == 0 && it.Three == depCode);
+                            Res_ThreeCode arrData = _sqlSugar.Queryable<Res_ThreeCode>().First(it => it.IsDel == 0 && it.Three == arrCode);
+                            string day = spDotandEmpty[2].Substring(2, 2);//日
+                            string monthAbbreviations = spDotandEmpty[2].Substring(4, 3).ToUpper();//月份
+                            switch (monthAbbreviations)
+                            {
+                                case "JAN":
+                                    monthAbbreviations = "1";
+                                    break;
+                                case "FEB":
+                                    monthAbbreviations = "2";
+                                    break;
+                                case "MAR":
+                                    monthAbbreviations = "3";
+                                    break;
+                                case "APR":
+                                    monthAbbreviations = "4";
+                                    break;
+                                case "MAY":
+                                    monthAbbreviations = "5";
+                                    break;
+                                case "JUN":
+                                    monthAbbreviations = "6";
+                                    break;
+                                case "JUL":
+                                    monthAbbreviations = "7";
+                                    break;
+                                case "AUG":
+                                    monthAbbreviations = "8";
+                                    break;
+                                case "SEP":
+                                    monthAbbreviations = "9";
+                                    break;
+                                case "OCT":
+                                    monthAbbreviations = "10";
+                                    break;
+                                case "NOV":
+                                    monthAbbreviations = "11";
+                                    break;
+                                case "DEC":
+                                    monthAbbreviations = "12";
+                                    break;
+                            }
+                            string tate = $"{monthAbbreviations}月{day}日";
+                            item.FlightDescription +=depData.AirPort + " " + arrData.AirPort + "  (" + tate + ")\r\n";
+                        }
+                        catch (Exception)
+                        {
+                            item.FlightDescription = "录入数据不规范!请检查";
+                        }
+                    }
+                }
+                //团组成本预算表查询
+                Grp_GroupCostParameter _GroupCostParameter = _sqlSugar.Queryable<Grp_GroupCostParameter>().First(a=>a.DiId==dto.DiId);
+
+                AirGroupCostParameterView _AirgroupCostParameter = _mapper.Map<AirGroupCostParameterView>(_GroupCostParameter);
+               
+                var data = new
+                {
+                    DelegationInfo = _DelegationInfo,
+                    AirTicketReservations = _AirTicketReservations,
+                    AirGroupCostParameter= _AirgroupCostParameter
+                };
+                return result = new Result() { Code = 0, Msg = "查询成功!", Data = data };
+            }
+            else
+            {
+                return result = new Result() { Code = -1, Msg = "暂无团组数据!" };
+            }
+
+        }
+
+        public async Task<Result> AirTicketResSelect(AirTicketResDto dto)
+        {
+            Result result = new Result() { Code = -2, Msg = "未知错误" };
+            try
+            {
+                List<Grp_GroupsTaskAssignment> grp_GroupsTaskAssignment = Query<Grp_GroupsTaskAssignment>(a => a.IsDel == 0 && a.UId == dto.UserId && a.CTId == 85).ToList();
+                if (grp_GroupsTaskAssignment.Count != 0)
+                {
+                    string DiId = "";
+                    foreach (var item in grp_GroupsTaskAssignment)
+                    {
+                        DiId += item.DIId + ",";
+                    }
+                    DiId = DiId.Substring(0, DiId.Length - 1);
+                    string sql = string.Format(@"select * from Grp_DelegationInfo where Id in({0}) and IsDel={1}", DiId, 0);
+                    List<Grp_DelegationInfo> grp_Delegations = _sqlSugar.SqlQueryable<Grp_DelegationInfo>(sql).ToList();
+                    if (grp_Delegations.Count == 0)
+                    {
+                        return result = new Result() { Code = -1, Msg = "查询失败!" };
+                    }
+                    List<GroupNameView> grp_NameView = new List<GroupNameView>();
+                    foreach (var item in grp_Delegations)
+                    {
+                        GroupNameView groupNameView = new GroupNameView();
+                        groupNameView.Id = item.Id;
+                        groupNameView.GroupName = item.TeamName;
+                        grp_NameView.Add(groupNameView);
+                    }
+                    return result = new Result() { Code = 0, Msg = "查询成功!", Data = grp_NameView };
+                }
+                else
+                {
+                    return result = new Result() { Code = -1, Msg = "暂无可操作团组" };
+                }
+            }
+            catch (Exception ex)
+            {
+                return result = new Result() { Code = -2, Msg = "程序错误" };
+                throw;
+            }
+        }
+    }
+}

+ 3 - 1
OASystem/OASystem.Infrastructure/Tools/CommonFun.cs

@@ -1,4 +1,6 @@
-namespace OASystem.Infrastructure.Tools;
+using System.Reflection.Metadata;
+
+namespace OASystem.Infrastructure.Tools;
 
 
 /// <summary>
 /// <summary>
 /// 工具类
 /// 工具类

+ 447 - 7
OASystem/_Doc/OA2023数据字典.docx

@@ -2244,7 +2244,7 @@ Null
 业务人员查询时间
 业务人员查询时间
 
 
 
 
-8) 机票费用表:Grp_AirPrice(费用录入页面)
+8) 暂时没用--机票费用表:Grp_AirPrice(费用录入页面)
                                    字段名
                                    字段名
                                  类型长度
                                  类型长度
                                  字段属性
                                  字段属性
@@ -2329,8 +2329,147 @@ Null
 
 
 报价说明
 报价说明
 
 
+9) 机票费用录入表:Grp_AirTicketReservations(挪用)
+                                   字段名
+                                 类型长度
+                                 字段属性
+                                 字段约束
+                                 字段描述
+                                    备注
+DIId
+int
+Null
+
+团组外键编号
+Grp_DelegationInfo.Id
+FlightsCode
+varchar(100)
+Null
+
+航班号
+
+FlightsDate
+varchar(22)
+Null
+
+航班日期
+
+FlightsTime
+varchar(22)
+Null
+
+航班时间
+
+ArrivedTime
+varchar(22)
+Null
+
+抵达时间
+
+IsCheckIn
+int
+Null
+
+是否值机
+
+IsSetSeat
+int
+Null
+
+是否选座
+
+IsPackage
+int
+Null
+
+是否购买行李服务
+
+IsBagHandle
+int
+Null
+
+是否行李直挂
+
+IsTrain
+int
+Null
+
+是否火车票出票选座
+
+FlightsCity
+varchar(100)
+Null
 
 
-9) 酒店表:Grp_HotelReservations(挪用)
+城市A-B
+
+LeaveDescription
+text
+Null
+
+去程航班描述代码
+
+FlightsDescription
+text
+Null
+
+内陆段航班描述
+
+ReturnDescription
+text
+Null
+
+返程航班描述代码
+
+ClientNum
+int
+Null
+
+客户人数
+
+ClientName
+text
+Null
+
+客人名称
+
+PrePrice
+decimal(10,2)
+Null
+
+出票前报价
+
+PreCurrency
+int
+Null
+
+出票前报价币种
+SetData.id
+Price
+decimal(10,2)
+Null
+
+机票全价
+
+Currency
+int
+Null
+
+币种
+SetData.id
+PriceDescription
+text
+Null
+
+报价说明
+
+CType
+int
+Null
+
+舱类型
+
+
+10) 酒店表:Grp_HotelReservations(挪用)
                                    字段名
                                    字段名
                                  类型长度
                                  类型长度
                                  字段属性
                                  字段属性
@@ -2560,7 +2699,7 @@ Null
 是否住了其他房型
 是否住了其他房型
 0否1是
 0否1是
 
 
-10) 付款信息表:Grp_CreditCardPayment(挪用)
+11) 付款信息表:Grp_CreditCardPayment(挪用)
                                    字段名
                                    字段名
                                  类型长度
                                  类型长度
                                  字段属性
                                  字段属性
@@ -2789,7 +2928,7 @@ Null
 
 
 超出预算比例
 超出预算比例
 
 
-11) 团组流程管控表:Grp_Schedule
+12) 团组流程管控表:Grp_Schedule
                                    字段名
                                    字段名
                                  类型长度
                                  类型长度
                                  字段属性
                                  字段属性
@@ -2850,7 +2989,7 @@ Null
 
 
 异常标识
 异常标识
 
 
-12) 团组流程管控详细进度表:Grp_ScheduleDetail
+13) 团组流程管控详细进度表:Grp_ScheduleDetail
                                    字段名
                                    字段名
                                  类型长度
                                  类型长度
                                  字段属性
                                  字段属性
@@ -2912,7 +3051,7 @@ Null
 异常标识
 异常标识
 
 
 
 
-13) 团组流程管控人员配置表:Grp_SchedulePerson
+14) 团组流程管控人员配置表:Grp_SchedulePerson
                                    字段名
                                    字段名
                                  类型长度
                                  类型长度
                                  字段属性
                                  字段属性
@@ -2944,7 +3083,7 @@ Null
 负责工作
 负责工作
 
 
 
 
-14) 团组任务分配:Grp_GroupsTaskAssignment
+15) 团组任务分配:Grp_GroupsTaskAssignment
                                    字段名
                                    字段名
                                  类型长度
                                  类型长度
                                  字段属性
                                  字段属性
@@ -3226,4 +3365,305 @@ Null
 
 
 签证地址
 签证地址
 
 
+1. 机票板块
+
+2. 财务板块
+1) 团组成本表:Grp_GroupCostParameter(挪用)
+                                   字段名
+                                 类型长度
+                                 字段属性
+                                 字段约束
+                                 字段描述
+                                    备注
+                                     DiId
+                                      int
+                                     Null
+                                       
+                                   团组id
+                                       
+                                   Currency
+                                    string
+                                     Null
+                                       
+                                    币种
+                                       
+                                     Rate
+                                 decimal(10,2)
+                                     Null
+                                       
+                                    汇率
+                                       
+                                      Tax
+                                 decimal(10,2)
+                                     Null
+                                       
+                                    税率
+                                       
+                                     FFYS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 房费预算
+                                       
+                                    HotelXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 酒店系数
+                                       
+                                     JJCCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                                经济舱成本
+                                       
+                                     JJCXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                经济舱系数
+                                       
+                                     JJCRS
+                                      int
+                                     Null
+                                       
+                                经济舱人数
+                                       
+                                     GWCCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                                公务舱成本
+                                       
+                                     GWCXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                公务舱系数
+                                       
+                                     GWCRS
+                                      int
+                                     Null
+                                       
+                                公务舱人数
+                                       
+                                     HCPCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                                火车票成本
+                                       
+                                     HCPXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                火车票系数
+                                       
+                                     HCPRS
+                                      int
+                                     Null
+                                       
+                                火车票人数
+                                       
+                                     CPCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 船票成本
+                                       
+                                     CPXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 船票系数
+                                       
+                                     CPRS
+                                      int
+                                     Null
+                                       
+                                 船票人数
+                                       
+                                     BXCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 保险成本
+                                       
+                                     BXXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 保险系数
+                                       
+                                     BXRS
+                                      int
+                                     Null
+                                       
+                                 保险人数
+                                       
+                                     HSCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                              核酸检测成本
+                                       
+                                     HSXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                              核酸检测系数
+                                       
+                                     HSRS
+                                      int
+                                     Null
+                                       
+                              核酸检测人数
+                                       
+                                    VisaCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 签证成本
+                                       
+                                    VisaXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 签证系数
+                                       
+                                    VisaRS
+                                      int
+                                     Null
+                                       
+                                 签证人数
+                                       
+                                     GWCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                           公务成本 : 公杂费
+                                       
+                                     GWXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                            公务系数: 公杂费
+                                       
+                                     GWRS
+                                      Int
+                                     Null
+                                       
+                           公务人数 : 公杂费
+                                       
+                                     DJCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 地接成本
+                                       
+                                     DJXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 地接系数
+                                       
+                                     SGRCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                              单间 单人成本
+                                       
+                                   SGRNumber
+                                      int
+                                     Null
+                                       
+                             单间数量(人数)
+                                       
+                                     SGRXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                 单间 系数
+                                       
+                                     TBRCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                            1/2标间 单人成本
+                                       
+                                   TBRNumber
+                                      int
+                                     Null
+                                       
+                            1/2标间数量(人数)
+                                       
+                                     TBRXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                               1/2标间  系数
+                                       
+                                    JSESCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                      小套房/豪华套房 单人成本
+                                       
+                                  JSESNumber
+                                      int
+                                     Null
+                                       
+                     小套房/豪华套房数量(人数)
+                                       
+                                    JSESXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                         小套房/豪华套房 系数
+                                       
+                                    SUITECB
+                                 decimal(10,2)
+                                     Null
+                                       
+                             套房  单人成本
+                                       
+                                  SUITENumber
+                                      int
+                                     Null
+                                       
+                             套房数量(人数)
+                                       
+                                    SUITEXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                             套房  单人成本
+                                       
+                                     LYJCB
+                                 decimal(10,2)
+                                     Null
+                                       
+                                零用金成本
+                                       
+                                     LYJXS
+                                 decimal(10,2)
+                                     Null
+                                       
+                                零用金系数
+                                       
+                                     LYJRS
+                                      int
+                                     Null
+                                       
+                                零用金人数
+                                       
+                                    IsShare
+                                      int
+                                     Null
+                                       
+                              成本完成标识
+                            0:未完成 1:完成
+
+
+