本文整理汇总了C#中IDalSession.InsertOrUpdate方法的典型用法代码示例。如果您正苦于以下问题:C# IDalSession.InsertOrUpdate方法的具体用法?C# IDalSession.InsertOrUpdate怎么用?C# IDalSession.InsertOrUpdate使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IDalSession
的用法示例。
在下文中一共展示了IDalSession.InsertOrUpdate方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Update
public static bool Update(IDalSession session, IMoneyTransferOrder obj)
{
bool blnSuccess = session.InsertOrUpdate(obj);
if (blnSuccess && obj.Reference == null)
{
obj.setReference();
blnSuccess = session.InsertOrUpdate(obj);
}
return blnSuccess;
}
示例2: CreateExternalSideSettlement
public static bool CreateExternalSideSettlement(IDalSession session, IList<ITradingJournalEntry> tradeStatements, IList<IJournalEntryLine> bankStatements)
{
if (((tradeStatements != null) && (tradeStatements.Count > 0)) && ((bankStatements != null) && (bankStatements.Count > 0)))
{
DateTime settlementDate = (bankStatements[0].BookDate > tradeStatements[0].TransactionDate) ? bankStatements[0].BookDate : tradeStatements[0].TransactionDate;
ICurrency currency = (ICurrency)bankStatements[0].Balance.Underlying;
ITradeableInstrument instrument = (ITradeableInstrument)tradeStatements[0].TradeSize.Underlying;
IGLAccount settleDiffGLAccount = GLAccountMapper.GetSettlementDifferenceGLAccount(session, currency, instrument);
IJournal journal = JournalMapper.GetSettlementDifferenceJournal(session);
string nextJournalEntryNumber = JournalEntryMapper.GetNextJournalEntryNumber(session, journal);
IExternalSettlement settlement = new ExternalSettlement(bankStatements, tradeStatements, settlementDate);
if (settlement.Settle(journal, nextJournalEntryNumber, settleDiffGLAccount))
session.InsertOrUpdate(settlement);
}
return true;
}
示例3: Update
public static bool Update(IDalSession session, IGeneralOperationsBooking obj)
{
return session.InsertOrUpdate(obj);
}
示例4: Update
public static bool Update(IDalSession session, IList list)
{
return session.InsertOrUpdate(list);
}
示例5: InsertOrUpdate
/// <summary>
/// Creates/Updates a new object in the database
/// </summary>
/// <param name="session">An instance of the Data Access Library <see cref="T:B4F.TotalGiro.DAL.NHSession">NHSession</see> class</param>
/// <param name="obj">Object of type ExtPosition</param>
public static void InsertOrUpdate(IDalSession session, ExtPosition obj)
{
session.InsertOrUpdate(obj);
}
示例6: Update
/// <summary>
/// Updates a <b>FeeRule</b> object to the database.
/// </summary>
/// <param name="session">An instance of the Data Access Library (see class <see cref="B4F.TotalGiro.DAL.NHSession">NHSession</see>).</param>
/// <param name="obj">The <b>FeeRule</b> object to update into the database.</param>
public static bool Update(IDalSession session, IFeeRule obj)
{
InternalEmployeeLogin emp = LoginMapper.GetCurrentLogin(session) as InternalEmployeeLogin;
obj.AssetManager = (IAssetManager)emp.Employer;
return session.InsertOrUpdate(obj);
}
示例7: Update
public static bool Update(IDalSession session, ILifecycle obj)
{
return session.InsertOrUpdate(obj);
}
示例8: InsertOrUpdate
/// <summary>
/// Either creates or edits a JobHistory object in the database
/// </summary>
/// <param name="session">An instance of the Data Access Library <see cref="T:B4F.TotalGiro.DAL.NHSession">NHSession</see> class</param>
/// <param name="obj">Object of type JobHistory</param>
public static void InsertOrUpdate(IDalSession session, JobHistory obj)
{
session.InsertOrUpdate(obj);
}
示例9: Update
public static void Update(IDalSession session, IWithdrawalRule obj)
{
session.InsertOrUpdate(obj);
}
示例10: Update
public static bool Update(IDalSession session, ILedgerEntry obj)
{
return session.InsertOrUpdate(obj);
}
示例11: Update
public static bool Update(IDalSession session, IModelBase obj)
{
return session.InsertOrUpdate(obj);
}
示例12: Update
public static bool Update(IDalSession session, IDocument obj)
{
return session.InsertOrUpdate(obj);
}
示例13: Update
public static bool Update(IDalSession session, IHistoricalExRate historicalExRate)
{
session.InsertOrUpdate(historicalExRate);
return true;
}
示例14: Update
public static bool Update(IDalSession session, IGLDSTDFile obj)
{
bool blnSuccess = session.InsertOrUpdate(obj);
return blnSuccess;
}
示例15: Update
public static bool Update(IDalSession session, IExportedLedgerFile obj)
{
return session.InsertOrUpdate(obj);
}