|
@@ -270,12 +270,12 @@ namespace OASystem.Infrastructure.Repositories.Groups
|
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
|
- /// 三公费用签证费用提示
|
|
|
+ /// 出入境费用签证费用提示
|
|
|
/// </summary>
|
|
|
/// <param name="portType"></param>
|
|
|
/// <param name="diId"></param>
|
|
|
/// <returns></returns>
|
|
|
- public async Task<Result> EntryAndExitTips(int diId)
|
|
|
+ public async Task<Result> EnterExitCostVisaTips(int diId)
|
|
|
{
|
|
|
if (diId < 1) return _result = new Result() { Code = -1, Msg = "请传入有效的DiId参数" };
|
|
|
|
|
@@ -289,12 +289,14 @@ namespace OASystem.Infrastructure.Repositories.Groups
|
|
|
|
|
|
visaData = visaData.Where(it => it.IsChecked == 1).ToList();
|
|
|
var visaData1 = visaData.GroupBy(it => it.CountryVisaFeeId);
|
|
|
-
|
|
|
+
|
|
|
+ //费用报价系数
|
|
|
+ decimal priceCoeff = 1.20M;
|
|
|
foreach (var kvp in visaData1)
|
|
|
{
|
|
|
var countryData = visaCountryDatas.Find(it => it.Id == kvp.Key);
|
|
|
- decimal _otherFee = kvp.FirstOrDefault()?.OtherFee ?? 0;
|
|
|
- decimal _visaFee = Convert.ToDecimal(countryData?.VisaPrice ?? 0.00M);
|
|
|
+ decimal _otherFee = kvp.FirstOrDefault()?.OtherFee * priceCoeff ?? 0;
|
|
|
+ decimal _visaFee = Convert.ToDecimal(countryData?.VisaPrice ?? 0.00M) * priceCoeff;
|
|
|
decimal visaFeeTotal = _visaFee + _otherFee;
|
|
|
decimal _agencyFee = 0;
|
|
|
decimal _GrandBusinessAgencyFee = 0;
|
|
@@ -309,7 +311,7 @@ namespace OASystem.Infrastructure.Repositories.Groups
|
|
|
{
|
|
|
remark1 += $@"大公务代办费:{item.AgencyFee.ToString("#0.00")}元、";
|
|
|
_agencyFee += item.AgencyFee;
|
|
|
- _GrandBusinessAgencyFee = item.AgencyFee;
|
|
|
+ _GrandBusinessAgencyFee = item.AgencyFee * priceCoeff;
|
|
|
}
|
|
|
}
|
|
|
else if (item.OBType == 1)
|
|
@@ -318,7 +320,7 @@ namespace OASystem.Infrastructure.Repositories.Groups
|
|
|
{
|
|
|
remark1 += $@"小公务代办费:{item.AgencyFee.ToString("#0.00")}元、";
|
|
|
_agencyFee += item.AgencyFee;
|
|
|
- _PettyBusinessAgencyFee = item.AgencyFee;
|
|
|
+ _PettyBusinessAgencyFee = item.AgencyFee * priceCoeff;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -351,5 +353,60 @@ namespace OASystem.Infrastructure.Repositories.Groups
|
|
|
|
|
|
return _result;
|
|
|
}
|
|
|
+ /// <summary>
|
|
|
+ /// 出入境费用草稿签证费用提示
|
|
|
+ /// </summary>
|
|
|
+ /// <param name="portType"></param>
|
|
|
+ /// <param name="diId"></param>
|
|
|
+ /// <returns></returns>
|
|
|
+ public async Task<(decimal,string)> EnterExitCostDraftVisaTips(string[] countrys)
|
|
|
+ {
|
|
|
+ var visaCountryDatas = await _sqlSugar.Queryable<Res_CountryFeeCost>().Where(it => countrys.Contains(it.VisaCountry)).ToListAsync();
|
|
|
+
|
|
|
+ string remark = "";
|
|
|
+ decimal feeTotal = 0.00M;
|
|
|
+
|
|
|
+ //费用报价系数
|
|
|
+ decimal priceCoeff = 1.20M;
|
|
|
+ foreach (var kvp in visaCountryDatas)
|
|
|
+ {
|
|
|
+ var countryName = kvp?.VisaCountry ?? "";
|
|
|
+ //免签
|
|
|
+ if (kvp.IsVisaExemption == 0)
|
|
|
+ {
|
|
|
+ remark += $@"{countryName}:免签;";
|
|
|
+ continue;
|
|
|
+ }
|
|
|
+
|
|
|
+ decimal visaFee = Convert.ToDecimal(kvp?.VisaPrice ?? 0.00M) * priceCoeff;
|
|
|
+
|
|
|
+
|
|
|
+ decimal gbAgencyFee = kvp.GrandBusinessAgencyFee;
|
|
|
+ decimal pbAgencyFee = kvp.PettyBusinessAgencyFee;
|
|
|
+
|
|
|
+ string remark1 = $"签证费:{visaFee.ToString("#0.00")}元、";
|
|
|
+ if (gbAgencyFee > 0.00M)
|
|
|
+ {
|
|
|
+ remark1 += $@"大公务代办费:{gbAgencyFee.ToString("#0.00")}元、";
|
|
|
+ gbAgencyFee *= priceCoeff;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (pbAgencyFee > 0.00M)
|
|
|
+ {
|
|
|
+ remark1 += $@"小公务代办费:{pbAgencyFee.ToString("#0.00")}元、";
|
|
|
+ pbAgencyFee *= priceCoeff;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (remark1.Length > 0) remark1 = remark1.Substring(0, remark1.Length - 1);
|
|
|
+ decimal visaFeeTotal = visaFee + gbAgencyFee + pbAgencyFee;
|
|
|
+
|
|
|
+ remark += $@"{countryName}:签证总费用:{visaFeeTotal}元/人 其中({remark1});";
|
|
|
+
|
|
|
+ feeTotal += visaFeeTotal;
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ return (feeTotal,remark);
|
|
|
+ }
|
|
|
}
|
|
|
}
|