客户适当性有效期
This commit is contained in:
@@ -20,7 +20,16 @@ namespace YLErp.Modules.DataProviderModule
|
||||
|| db.eod_stock_price.Any(n => n.ValueDate == valueDate)
|
||||
|| db.china_bond_valuation.Any(n => n.valuation_date == valueDate && n.dirty_price_close > 0);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 校验FR007价格
|
||||
/// </summary>
|
||||
/// <param name="valueDate"></param>
|
||||
/// <returns></returns>
|
||||
public static bool CheckFR007Price(DateTime valueDate)
|
||||
{
|
||||
using var db = DbContextFactory.GetYLDbContext();
|
||||
return db.eod_commodity_future_price.Any(n => n.ValueDate == valueDate && n.UnderlyingCode == "FR007");
|
||||
}
|
||||
/// <summary>
|
||||
/// 检查是否存在收盘价
|
||||
/// </summary>
|
||||
@@ -123,7 +132,7 @@ namespace YLErp.Modules.DataProviderModule
|
||||
|
||||
valueDate = valueDate.Date;
|
||||
using var db = DbContextFactory.GetYLDbContext();
|
||||
var data = db.eod_commodity_future_price.Where(x => x.ValueDate <= valueDate && x.UnderlyingCode == underlyingCode).OrderByDescending(o => o.ValueDate).FirstOrDefault();
|
||||
var data = db.eod_commodity_future_price.Where(x => x.ValueDate == valueDate && x.UnderlyingCode == underlyingCode).OrderByDescending(o => o.ValueDate).FirstOrDefault();
|
||||
|
||||
if (data != null)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user