case 3827

This commit is contained in:
2020-10-14 19:11:22 +00:00
parent b335835a14
commit 2a6286bfdf

View File

@@ -662,6 +662,19 @@ namespace GZTW.AyaNova.BLL
/// </summary>
protected override void DataPortal_Update()
{
//--------------------------
//case 3827
//Remove any entries deliverafter older than 7 days
DBCommandWrapper cmTrim = DBUtil.GetCommandFromSQL(
"DELETE FROM aClientNotifyEvent " +
"WHERE (aDeliverAfter < @SEVENDAYSAGO)"
);
cmTrim.AddInParameter("@SEVENDAYSAGO", DbType.DateTime, DBUtil.ToUTC(DBUtil.CurrentWorkingDateTime.AddDays(-7)));
DBUtil.DB.ExecuteNonQuery(cmTrim);
//------------------------
// If not a new record, check if record was modified
//by another user since original retrieval:
if (!IsNew)