Browse Source

费用审核
签证 消息推送 修改
机票 类型数据修改

leiy 1 year ago
parent
commit
317d196a8a
1 changed files with 16 additions and 3 deletions
  1. 16 3
      OASystem/OASystem.Api/Controllers/GroupsController.cs

+ 16 - 3
OASystem/OASystem.Api/Controllers/GroupsController.cs

@@ -79,7 +79,6 @@ namespace OASystem.API.Controllers
         private readonly TourClientListRepository _tourClientListRep;
         private readonly TeamRateRepository _teamRateRep;
 
-
         #region 成本相关
         private readonly CheckBoxsRepository _checkBoxs;
         private readonly GroupCostRepository _GroupCostRepository;
@@ -1341,6 +1340,10 @@ namespace OASystem.API.Controllers
                         PaymentCurrency_WaitPay = sdPaymentCurrency_WaitPay.Name;
                         hotelCurrncyCode = sdPaymentCurrency_WaitPay.Name;
                         hotelCurrncyName = sdPaymentCurrency_WaitPay.Remark;
+                        if (hotelCurrncyCode.Equals("CNY"))
+                        {
+                            entity.DayRate = 1.0000M;
+                        }
                     }
                     _detail.WaitPay = entity.PayMoney.ConvertToDecimal1() + " " + PaymentCurrency_WaitPay;
 
@@ -1731,7 +1734,17 @@ namespace OASystem.API.Controllers
 
                     decimal CNYPrice = (creditData.PayMoney * (creditData.PayPercentage / 100)) * creditData.DayRate;
                     string msgTitle = $"[{groupNameStr}({creditTypeStr})]的费用申请";
-                    string msgContent = $"[{groupNameStr}({creditTypeStr})]费用申请(金额:{CNYPrice.ToString("0.##")} CNY({creditData.PayMoney.ToString("0.##")} {creditCurrency})) {auditStr}!";
+                    string msgContent = "";
+                    if (creditCurrency.Equals("CNY"))
+                    {
+                        msgContent = $"[{groupNameStr}({creditTypeStr})]费用申请(金额:{CNYPrice.ToString("0.00")} CNY) {auditStr}!";
+                    }
+                    else
+                    {
+                        msgContent = $"[{groupNameStr}({creditTypeStr})]费用申请(金额:{CNYPrice.ToString("0.00")} CNY({creditData.PayMoney.ToString("0.00")} {creditCurrency})) {auditStr}!";
+                    }
+
+                     
                     msgDatas.Add(new {DiId = creditData.DIId, UserId = creditData.CreateUserId, MsgTitle = msgTitle, MsgContent = msgContent });
                 }
                 
@@ -1741,7 +1754,7 @@ namespace OASystem.API.Controllers
                 foreach (var item in msgDatas)
                 {
                     //发送消息
-                  await  GeneralMethod.MessageIssueAndNotification(MessageTypeEnum.GroupExpenseAudit, item.MsgTitle, item.msgContent, new List<int>() { item.UserId }, item.DiId);
+                    GeneralMethod.MessageIssueAndNotification(MessageTypeEnum.GroupExpenseAudit, item.MsgTitle, item.MsgContent, new List<int>() { item.UserId }, item.DiId);
                 }
 
                 _groupRepository.CommitTran();