|
@@ -320,6 +320,7 @@ namespace OASystem.API.Controllers
|
|
#region 页面操作权限验证
|
|
#region 页面操作权限验证
|
|
pageFunAuthView = await GeneralMethod.PostUserPageFuncDatas(dto.UserId, dto.PageId);
|
|
pageFunAuthView = await GeneralMethod.PostUserPageFuncDatas(dto.UserId, dto.PageId);
|
|
|
|
|
|
|
|
+
|
|
if (pageFunAuthView.CheckAuth == 0) return Ok(JsonView(false, "您没有查看权限"));
|
|
if (pageFunAuthView.CheckAuth == 0) return Ok(JsonView(false, "您没有查看权限"));
|
|
#endregion
|
|
#endregion
|
|
|
|
|
|
@@ -1916,7 +1917,7 @@ namespace OASystem.API.Controllers
|
|
}
|
|
}
|
|
catch (Exception ex)
|
|
catch (Exception ex)
|
|
{
|
|
{
|
|
- return Ok(JsonView(false, "程序错误!"));
|
|
|
|
|
|
+ return Ok(JsonView(false, ex.Message));
|
|
throw;
|
|
throw;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -3820,8 +3821,10 @@ namespace OASystem.API.Controllers
|
|
builder.Write("第" + dac.Days.ToString() + "晚:");
|
|
builder.Write("第" + dac.Days.ToString() + "晚:");
|
|
|
|
|
|
builder.MoveToCell(0, i, 1, 0);
|
|
builder.MoveToCell(0, i, 1, 0);
|
|
- builder.Write(placeData.Find(it => it.Id == dac.NationalTravelFeeId)?.Country ?? "Unknown");
|
|
|
|
- builder.Write(dac.Place == null ? "" : dac.Place);
|
|
|
|
|
|
+ //builder.Write(placeData.Find(it => it.Id == dac.NationalTravelFeeId)?.Country ?? "Unknown");
|
|
|
|
+ //builder.Write(dac.Place == null ? "" : dac.Place);
|
|
|
|
+ builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));
|
|
|
|
+
|
|
|
|
|
|
builder.MoveToCell(0, i, 2, 0);
|
|
builder.MoveToCell(0, i, 2, 0);
|
|
builder.Write("费用标准:");
|
|
builder.Write("费用标准:");
|
|
@@ -3859,7 +3862,7 @@ namespace OASystem.API.Controllers
|
|
builder.Write("第" + dac.Days.ToString() + "天:");
|
|
builder.Write("第" + dac.Days.ToString() + "天:");
|
|
|
|
|
|
builder.MoveToCell(1, i, 1, 0);
|
|
builder.MoveToCell(1, i, 1, 0);
|
|
- builder.Write(placeData.Find(it => it.Id == dac.NationalTravelFeeId)?.Country ?? "Unknown");
|
|
|
|
|
|
+ builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));
|
|
|
|
|
|
builder.MoveToCell(1, i, 2, 0);
|
|
builder.MoveToCell(1, i, 2, 0);
|
|
builder.Write("费用标准:");
|
|
builder.Write("费用标准:");
|
|
@@ -3898,7 +3901,8 @@ namespace OASystem.API.Controllers
|
|
builder.Write("第" + dac.Days.ToString() + "天:");
|
|
builder.Write("第" + dac.Days.ToString() + "天:");
|
|
|
|
|
|
builder.MoveToCell(2, i, 1, 0);
|
|
builder.MoveToCell(2, i, 1, 0);
|
|
- builder.Write(placeData.Find(it => it.Id == dac.NationalTravelFeeId)?.Country ?? "Unknown");
|
|
|
|
|
|
+
|
|
|
|
+ builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));
|
|
|
|
|
|
builder.MoveToCell(2, i, 2, 0);
|
|
builder.MoveToCell(2, i, 2, 0);
|
|
builder.Write("费用标准:");
|
|
builder.Write("费用标准:");
|
|
@@ -4017,7 +4021,8 @@ namespace OASystem.API.Controllers
|
|
//builder.MoveToCell(0, accommodationStartIndex, 0, 0);
|
|
//builder.MoveToCell(0, accommodationStartIndex, 0, 0);
|
|
//builder.Write(DeleClientList[i].LastName + DeleClientList[i].Name);
|
|
//builder.Write(DeleClientList[i].LastName + DeleClientList[i].Name);
|
|
builder.MoveToCell(0, accommodationStartIndex, 1, 0);
|
|
builder.MoveToCell(0, accommodationStartIndex, 1, 0);
|
|
- builder.Write(placeData.Find(it => it.Id == dac.NationalTravelFeeId)?.Country ?? "Unknown");//城市
|
|
|
|
|
|
+
|
|
|
|
+ builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));
|
|
builder.MoveToCell(0, accommodationStartIndex, 2, 0);
|
|
builder.MoveToCell(0, accommodationStartIndex, 2, 0);
|
|
|
|
|
|
string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknown";
|
|
string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknown";
|
|
@@ -4071,7 +4076,8 @@ namespace OASystem.API.Controllers
|
|
}
|
|
}
|
|
|
|
|
|
builder.MoveToCell(0, foodandotherStartIndex, 1, 0);
|
|
builder.MoveToCell(0, foodandotherStartIndex, 1, 0);
|
|
- builder.Write(placeData.Find(it => it.Id == dac.NationalTravelFeeId)?.Country ?? "Unknown");//城市
|
|
|
|
|
|
+
|
|
|
|
+ builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));
|
|
builder.MoveToCell(0, foodandotherStartIndex, 2, 0);
|
|
builder.MoveToCell(0, foodandotherStartIndex, 2, 0);
|
|
string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknown" ;
|
|
string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknown" ;
|
|
builder.Write(currency);//币种
|
|
builder.Write(currency);//币种
|
|
@@ -4226,14 +4232,14 @@ namespace OASystem.API.Controllers
|
|
decimal dac1totalPrice = 0.00M, dac2totalPrice = 0.00M;
|
|
decimal dac1totalPrice = 0.00M, dac2totalPrice = 0.00M;
|
|
foreach (var item in dac1)
|
|
foreach (var item in dac1)
|
|
{
|
|
{
|
|
- item.Place = placeData.Find(it => it.Id == item.NationalTravelFeeId)?.Country ?? "Unknown";
|
|
|
|
|
|
+ item.Place =GetEnterExitCostExportCity(placeData, item.NationalTravelFeeId);
|
|
if (place.Contains(item.Place))
|
|
if (place.Contains(item.Place))
|
|
{
|
|
{
|
|
continue;
|
|
continue;
|
|
}
|
|
}
|
|
DataRow row = dtdac1.NewRow();
|
|
DataRow row = dtdac1.NewRow();
|
|
|
|
|
|
- row["city"] = placeData.Find(it => it.Id == item.NationalTravelFeeId)?.Country ?? "Unknown";
|
|
|
|
|
|
+ row["city"] =item.Place;
|
|
|
|
|
|
string currency = _CurrDatas.Find(it => it.Id == item.Currency)?.Name ?? "Unknwon";
|
|
string currency = _CurrDatas.Find(it => it.Id == item.Currency)?.Name ?? "Unknwon";
|
|
decimal rate = rateDatas.Find(it => it.CurrencyCode == currency)?.Rate ?? 0.00M;
|
|
decimal rate = rateDatas.Find(it => it.CurrencyCode == currency)?.Rate ?? 0.00M;
|
|
@@ -4252,7 +4258,7 @@ namespace OASystem.API.Controllers
|
|
place = new List<string>();
|
|
place = new List<string>();
|
|
foreach (var item in dac2)
|
|
foreach (var item in dac2)
|
|
{
|
|
{
|
|
- item.Place = placeData.Find(it => it.Id == item.NationalTravelFeeId)?.Country ?? "Unknown";
|
|
|
|
|
|
+ item.Place = GetEnterExitCostExportCity(placeData, item.NationalTravelFeeId);
|
|
if (place.Contains(item.Place))
|
|
if (place.Contains(item.Place))
|
|
{
|
|
{
|
|
continue;
|
|
continue;
|
|
@@ -4431,7 +4437,7 @@ namespace OASystem.API.Controllers
|
|
//builder.MoveToCell(0, accommodationStartIndex, 0, 0);
|
|
//builder.MoveToCell(0, accommodationStartIndex, 0, 0);
|
|
//builder.Write(DeleClientList[i].LastName + DeleClientList[i].Name);
|
|
//builder.Write(DeleClientList[i].LastName + DeleClientList[i].Name);
|
|
builder.MoveToCell(0, accommodationStartIndex, 1, 0);
|
|
builder.MoveToCell(0, accommodationStartIndex, 1, 0);
|
|
- builder.Write(placeData.Find(it => it.Id == dac.NationalTravelFeeId)?.Country ?? "Unknown");//城市
|
|
|
|
|
|
+ builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));//城市
|
|
builder.MoveToCell(0, accommodationStartIndex, 2, 0);
|
|
builder.MoveToCell(0, accommodationStartIndex, 2, 0);
|
|
|
|
|
|
string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknwon";
|
|
string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknwon";
|
|
@@ -4476,7 +4482,7 @@ namespace OASystem.API.Controllers
|
|
}
|
|
}
|
|
|
|
|
|
builder.MoveToCell(0, foodandotherStartIndex, 1, 0);
|
|
builder.MoveToCell(0, foodandotherStartIndex, 1, 0);
|
|
- builder.Write(placeData.Find(it => it.Id == dac.NationalTravelFeeId)?.Country ?? "Unknown");//城市
|
|
|
|
|
|
+ builder.Write(GetEnterExitCostExportCity(placeData, dac.NationalTravelFeeId));//城市
|
|
builder.MoveToCell(0, foodandotherStartIndex, 2, 0);
|
|
builder.MoveToCell(0, foodandotherStartIndex, 2, 0);
|
|
|
|
|
|
string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknwon";
|
|
string currency = _CurrDatas.Find(it => it.Id == dac.Currency)?.Name ?? "Unknwon";
|
|
@@ -4586,6 +4592,27 @@ namespace OASystem.API.Controllers
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ /// <summary>
|
|
|
|
+ /// 获取三公费用标准city
|
|
|
|
+ /// </summary>
|
|
|
|
+ /// <param name="placeData"></param>
|
|
|
|
+ /// <param name="nationalTravelFeeId"></param>
|
|
|
|
+ /// <returns></returns>
|
|
|
|
+ private string GetEnterExitCostExportCity(List<Grp_NationalTravelFee> placeData,int nationalTravelFeeId)
|
|
|
|
+ {
|
|
|
|
+ string _city = string.Empty;
|
|
|
|
+
|
|
|
|
+ if (placeData.Count < 1) return _city;
|
|
|
|
+
|
|
|
|
+ var data = placeData.Find(it => it.Id == nationalTravelFeeId);
|
|
|
|
+ if (data == null) return _city;
|
|
|
|
+
|
|
|
|
+ string country = data.Country;
|
|
|
|
+ string city = data.City;
|
|
|
|
+ if (city.Contains("其他城市") || city.Contains("所有城市")) _city = $"{country}-{city}";
|
|
|
|
+ else _city = city;
|
|
|
|
+ return _city;
|
|
|
|
+ }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
/// <summary>
|