public as_userCheckItems GetUserCheckItem(int id) { var res = new as_userCheckItems(); //var key = "as_userCheckItems_" + id.ToString(); //if (CacheManager.EnableCaching && CacheManager.Cache[key] != null) //{ // res = (as_userCheckItems)CacheManager.Cache[key]; //} //else //{ try { res = db.GetUserCheckItem(id); //CacheManager.CacheData(key, res); } catch (Exception ex) { Debug.LogError(ex); } //} return(res); }
public void SaveUserCheckItem(as_userCheckItems item) { try { RDL.CacheManager.PurgeCacheItems("as_userCheckItems_" + item.id); db.SaveUserCheckItem(item); } catch (Exception ex) { RDL.Debug.LogError(ex); } }
public as_userCheckItems AddUserCheckItem(string name, string description, string emailText, string emailSubject, int setID) { var res = new as_userCheckItems(); var date = DateTime.Now; try { res = new as_userCheckItems { id = 0, name = name, description = description, emailText = emailText, emailSubject = emailSubject, setID = setID, created = date }; db.SaveUserCheckItem(res); } catch (Exception ex) { } return(res); }