|
@@ -29,6 +29,11 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
/// 已用金额
|
|
/// 已用金额
|
|
|
/// </summary>
|
|
/// </summary>
|
|
|
public decimal UsedAmount { get; set; }
|
|
public decimal UsedAmount { get; set; }
|
|
|
|
|
+
|
|
|
|
|
+ /// <summary>
|
|
|
|
|
+ /// 金额币种名称
|
|
|
|
|
+ /// </summary>
|
|
|
|
|
+ public string RemainingCurrencyName { get; set; }
|
|
|
}
|
|
}
|
|
|
/// <summary>
|
|
/// <summary>
|
|
|
/// 财务 - 团组超支费用
|
|
/// 财务 - 团组超支费用
|
|
@@ -59,8 +64,9 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
.ToListAsync();
|
|
.ToListAsync();
|
|
|
|
|
|
|
|
var upperLimit = _sqlSugar.Queryable<Grp_DelegationInfo>()
|
|
var upperLimit = _sqlSugar.Queryable<Grp_DelegationInfo>()
|
|
|
- .Where(x => x.Id == diId && x.IsDel == 0)
|
|
|
|
|
- .Select(x => new { x.ExtOverLimit, x.ExtOverCurrency })
|
|
|
|
|
|
|
+ .LeftJoin<Sys_SetData>((x, y) => x.ExtOverCurrency == y.Id && y.IsDel == 0)
|
|
|
|
|
+ .Where((x, y) => x.Id == diId && x.IsDel == 0)
|
|
|
|
|
+ .Select((x, y) => new { x.ExtOverLimit, x.ExtOverCurrency, CurrencyName = y.Name })
|
|
|
.First();
|
|
.First();
|
|
|
|
|
|
|
|
if (upperLimit == null)
|
|
if (upperLimit == null)
|
|
@@ -71,7 +77,8 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
RemainingAmount = 0,
|
|
RemainingAmount = 0,
|
|
|
RemainingCurrency = 836, //RMB
|
|
RemainingCurrency = 836, //RMB
|
|
|
RemainingPercentage = 1,
|
|
RemainingPercentage = 1,
|
|
|
- UsedAmount = 0
|
|
|
|
|
|
|
+ UsedAmount = 0,
|
|
|
|
|
+ RemainingCurrencyName = "人民币"
|
|
|
};
|
|
};
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -83,7 +90,8 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
RemainingAmount = upperLimit.ExtOverLimit,
|
|
RemainingAmount = upperLimit.ExtOverLimit,
|
|
|
RemainingCurrency = upperLimit.ExtOverCurrency,
|
|
RemainingCurrency = upperLimit.ExtOverCurrency,
|
|
|
RemainingPercentage = 1,
|
|
RemainingPercentage = 1,
|
|
|
- UsedAmount = 0
|
|
|
|
|
|
|
+ UsedAmount = 0,
|
|
|
|
|
+ RemainingCurrencyName = upperLimit.CurrencyName
|
|
|
};
|
|
};
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -95,6 +103,8 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
decimal remainingPercentage = 0;
|
|
decimal remainingPercentage = 0;
|
|
|
//已用额度
|
|
//已用额度
|
|
|
decimal usedAmount = 0;
|
|
decimal usedAmount = 0;
|
|
|
|
|
+ //币种名称
|
|
|
|
|
+ string remainingCurrencyName = string.Empty;
|
|
|
|
|
|
|
|
//获取超支部分的汇率
|
|
//获取超支部分的汇率
|
|
|
var currRate = await _setDataRepository.PostCurrencyByDiid(diId, 1015, upperLimit.ExtOverCurrency);
|
|
var currRate = await _setDataRepository.PostCurrencyByDiid(diId, 1015, upperLimit.ExtOverCurrency);
|
|
@@ -128,6 +138,7 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
usedAmount = rmbPrice;
|
|
usedAmount = rmbPrice;
|
|
|
|
|
+ remainingCurrencyName = "人民币";
|
|
|
}
|
|
}
|
|
|
else
|
|
else
|
|
|
{
|
|
{
|
|
@@ -144,6 +155,7 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
remainingPercentage = 1;
|
|
remainingPercentage = 1;
|
|
|
}
|
|
}
|
|
|
usedAmount = sumPriceList.Sum(x => x.PriceSum);
|
|
usedAmount = sumPriceList.Sum(x => x.PriceSum);
|
|
|
|
|
+ remainingCurrencyName = upperLimit.CurrencyName;
|
|
|
}
|
|
}
|
|
|
else
|
|
else
|
|
|
{
|
|
{
|
|
@@ -161,6 +173,7 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
remainingPercentage = 1;
|
|
remainingPercentage = 1;
|
|
|
}
|
|
}
|
|
|
usedAmount = rmbPrice;
|
|
usedAmount = rmbPrice;
|
|
|
|
|
+ remainingCurrencyName = "人民币";
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -173,7 +186,8 @@ namespace OASystem.Infrastructure.Repositories.Financial
|
|
|
RemainingAmount = remainingAmount,
|
|
RemainingAmount = remainingAmount,
|
|
|
RemainingCurrency = remainingCurrency,
|
|
RemainingCurrency = remainingCurrency,
|
|
|
RemainingPercentage = remainingPercentage,
|
|
RemainingPercentage = remainingPercentage,
|
|
|
- UsedAmount = usedAmount
|
|
|
|
|
|
|
+ UsedAmount = usedAmount,
|
|
|
|
|
+ RemainingCurrencyName = remainingCurrencyName
|
|
|
};
|
|
};
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|