public static void UpdateAdRecord(AdRecordInfo adRecord) { AdRecordInfo info = ReadAdRecord(adRecord.ID, 0); dal.UpdateAdRecord(adRecord); if (adRecord.AdID != info.AdID) { AdBLL.ChangeAdCount(info.AdID, ChangeAction.Minus); AdBLL.ChangeAdCount(adRecord.AdID, ChangeAction.Plus); } }
public static void DeleteAdRecord(string strID, int userID) { AdBLL.ChangeAdCountByGeneral(strID, ChangeAction.Minus); dal.DeleteAdRecord(strID, userID); }
public static int AddAdRecord(AdRecordInfo adRecord) { adRecord.ID = dal.AddAdRecord(adRecord); AdBLL.ChangeAdCount(adRecord.AdID, ChangeAction.Plus); return(adRecord.ID); }